diff options
Diffstat (limited to 'drivers/net/ethernet/natsemi/macsonic.c')
-rw-r--r-- | drivers/net/ethernet/natsemi/macsonic.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/net/ethernet/natsemi/macsonic.c b/drivers/net/ethernet/natsemi/macsonic.c index 0ffde69c8d01..346a4e025c34 100644 --- a/drivers/net/ethernet/natsemi/macsonic.c +++ b/drivers/net/ethernet/natsemi/macsonic.c | |||
@@ -202,13 +202,13 @@ static int macsonic_init(struct net_device *dev) | |||
202 | 202 | ||
203 | /* Allocate the entire chunk of memory for the descriptors. | 203 | /* Allocate the entire chunk of memory for the descriptors. |
204 | Note that this cannot cross a 64K boundary. */ | 204 | Note that this cannot cross a 64K boundary. */ |
205 | if ((lp->descriptors = dma_alloc_coherent(lp->device, | 205 | lp->descriptors = dma_alloc_coherent(lp->device, |
206 | SIZEOF_SONIC_DESC * SONIC_BUS_SCALE(lp->dma_bitmode), | 206 | SIZEOF_SONIC_DESC * |
207 | &lp->descriptors_laddr, GFP_KERNEL)) == NULL) { | 207 | SONIC_BUS_SCALE(lp->dma_bitmode), |
208 | printk(KERN_ERR "%s: couldn't alloc DMA memory for descriptors.\n", | 208 | &lp->descriptors_laddr, |
209 | dev_name(lp->device)); | 209 | GFP_KERNEL); |
210 | if (lp->descriptors == NULL) | ||
210 | return -ENOMEM; | 211 | return -ENOMEM; |
211 | } | ||
212 | 212 | ||
213 | /* Now set up the pointers to point to the appropriate places */ | 213 | /* Now set up the pointers to point to the appropriate places */ |
214 | lp->cda = lp->descriptors; | 214 | lp->cda = lp->descriptors; |