diff options
Diffstat (limited to 'arch/x86/kernel/pci-nommu_64.c')
-rw-r--r-- | arch/x86/kernel/pci-nommu_64.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/x86/kernel/pci-nommu_64.c b/arch/x86/kernel/pci-nommu_64.c index e85d4360360c..faf70bdca335 100644 --- a/arch/x86/kernel/pci-nommu_64.c +++ b/arch/x86/kernel/pci-nommu_64.c | |||
@@ -62,8 +62,8 @@ static int nommu_map_sg(struct device *hwdev, struct scatterlist *sg, | |||
62 | int i; | 62 | int i; |
63 | 63 | ||
64 | for_each_sg(sg, s, nents, i) { | 64 | for_each_sg(sg, s, nents, i) { |
65 | BUG_ON(!s->page); | 65 | BUG_ON(!sg_page(s)); |
66 | s->dma_address = virt_to_bus(page_address(s->page) +s->offset); | 66 | s->dma_address = virt_to_bus(sg_virt(s)); |
67 | if (!check_addr("map_sg", hwdev, s->dma_address, s->length)) | 67 | if (!check_addr("map_sg", hwdev, s->dma_address, s->length)) |
68 | return 0; | 68 | return 0; |
69 | s->dma_length = s->length; | 69 | s->dma_length = s->length; |