include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit...
[safe/jmp/linux-2.6] / drivers / dma / coh901318_lli.c
index 5f9af19..9f7e0e6 100644 (file)
@@ -11,6 +11,7 @@
 #include <linux/spinlock.h>
 #include <linux/dmapool.h>
 #include <linux/memory.h>
+#include <linux/gfp.h>
 #include <mach/coh901318.h>
 
 #include "coh901318_lli.h"
@@ -74,6 +75,8 @@ coh901318_lli_alloc(struct coh901318_pool *pool, unsigned int len)
 
        lli = head;
        lli->phy_this = phy;
+       lli->link_addr = 0x00000000;
+       lli->virt_link_addr = 0x00000000U;
 
        for (i = 1; i < len; i++) {
                lli_prev = lli;
@@ -85,13 +88,13 @@ coh901318_lli_alloc(struct coh901318_pool *pool, unsigned int len)
 
                DEBUGFS_POOL_COUNTER_ADD(pool, 1);
                lli->phy_this = phy;
+               lli->link_addr = 0x00000000;
+               lli->virt_link_addr = 0x00000000U;
 
                lli_prev->link_addr = phy;
                lli_prev->virt_link_addr = lli;
        }
 
-       lli->link_addr = 0x00000000U;
-
        spin_unlock(&pool->lock);
 
        return head;
@@ -268,10 +271,10 @@ coh901318_lli_fill_sg(struct coh901318_pool *pool,
 
                if (dir == DMA_TO_DEVICE)
                        /* increment source address */
-                       src = sg_dma_address(sg);
+                       src = sg_phys(sg);
                else
                        /* increment destination address */
-                       dst =  sg_dma_address(sg);
+                       dst =  sg_phys(sg);
 
                bytes_to_transfer = sg_dma_len(sg);