]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - drivers/net/ethernet/i825xx/lib82596.c
i825xx: switch to switch to dma_alloc_attrs
[linux.git] / drivers / net / ethernet / i825xx / lib82596.c
index 8449c58f01fd6571c101f6d76a360c77237565fe..f00a1dc2128cbcfcf590cb22bf88aa3796b6ab45 100644 (file)
@@ -1063,8 +1063,9 @@ static int i82596_probe(struct net_device *dev)
        if (!dev->base_addr || !dev->irq)
                return -ENODEV;
 
-       dma = (struct i596_dma *) DMA_ALLOC(dev->dev.parent,
-               sizeof(struct i596_dma), &lp->dma_addr, GFP_KERNEL);
+       dma = dma_alloc_attrs(dev->dev.parent, sizeof(struct i596_dma),
+                             &lp->dma_addr, GFP_KERNEL,
+                             DMA_ATTR_NON_CONSISTENT);
        if (!dma) {
                printk(KERN_ERR "%s: Couldn't get shared memory\n", __FILE__);
                return -ENOMEM;
@@ -1085,8 +1086,8 @@ static int i82596_probe(struct net_device *dev)
 
        i = register_netdev(dev);
        if (i) {
-               DMA_FREE(dev->dev.parent, sizeof(struct i596_dma),
-                                   (void *)dma, lp->dma_addr);
+               dma_free_attrs(dev->dev.parent, sizeof(struct i596_dma),
+                              dma, lp->dma_addr, DMA_ATTR_NON_CONSISTENT);
                return i;
        }