From: FUJITA Tomonori Date: Tue, 23 Oct 2007 07:30:28 +0000 (+0200) Subject: parisc: fix sg_page() fallout X-Git-Tag: v2.6.24-rc1~34^2~11 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b61e8f4844fd0767b656bd1f983933cc3d0102f3;p=linux-2.6 parisc: fix sg_page() fallout arch/parisc/kernel/pci-dma.c: In function 'pa11_dma_map_sg': arch/parisc/kernel/pci-dma.c:487: error: 'struct scatterlist' has no member named 'page' arch/parisc/kernel/pci-dma.c: In function 'pa11_dma_unmap_sg': arch/parisc/kernel/pci-dma.c:508: error: 'struct scatterlist' has no member named 'page' arch/parisc/kernel/pci-dma.c:508: error: 'struct scatterlist' has no member named 'page' arch/parisc/kernel/pci-dma.c: In function 'pa11_dma_sync_sg_for_cpu': arch/parisc/kernel/pci-dma.c:535: error: 'struct scatterlist' has no member named 'page' arch/parisc/kernel/pci-dma.c:535: error: 'struct scatterlist' has no member named 'page' arch/parisc/kernel/pci-dma.c: In function 'pa11_dma_sync_sg_for_device': arch/parisc/kernel/pci-dma.c:545: error: 'struct scatterlist' has no member named 'page' arch/parisc/kernel/pci-dma.c:545: error: 'struct scatterlist' has no member named 'page' Signed-off-by: FUJITA Tomonori Signed-off-by: Jens Axboe --- diff --git a/arch/parisc/kernel/pci-dma.c b/arch/parisc/kernel/pci-dma.c index 41f8e321e3..9448d4e911 100644 --- a/arch/parisc/kernel/pci-dma.c +++ b/arch/parisc/kernel/pci-dma.c @@ -25,6 +25,7 @@ #include #include #include +#include #include #include /* for DMA_CHUNK_SIZE */ diff --git a/drivers/parisc/ccio-dma.c b/drivers/parisc/ccio-dma.c index b3c4dbff26..7c60cbd85d 100644 --- a/drivers/parisc/ccio-dma.c +++ b/drivers/parisc/ccio-dma.c @@ -42,6 +42,7 @@ #include #include #include +#include #include #include /* for L1_CACHE_BYTES */ diff --git a/drivers/parisc/sba_iommu.c b/drivers/parisc/sba_iommu.c index e5c323936e..e527a0e1d6 100644 --- a/drivers/parisc/sba_iommu.c +++ b/drivers/parisc/sba_iommu.c @@ -28,6 +28,7 @@ #include #include #include +#include #include #include diff --git a/include/asm-parisc/scatterlist.h b/include/asm-parisc/scatterlist.h index cd3cfdf822..62269b31eb 100644 --- a/include/asm-parisc/scatterlist.h +++ b/include/asm-parisc/scatterlist.h @@ -18,7 +18,7 @@ struct scatterlist { __u32 iova_length; /* bytes mapped */ }; -#define sg_virt_addr(sg) ((unsigned long)(page_address(sg->page) + sg->offset)) +#define sg_virt_addr(sg) ((unsigned long)sg_virt(sg)) #define sg_dma_address(sg) ((sg)->iova) #define sg_dma_len(sg) ((sg)->iova_length)