fedora core 6 1.2949 + vserver 2.2.0
[linux-2.6.git] / lib / swiotlb.c
index 1062578..d6d57fb 100644 (file)
@@ -750,7 +750,7 @@ swiotlb_sync_sg(struct device *hwdev, struct scatterlist *sg,
 
        for (i = 0; i < nelems; i++, sg++)
                if (sg->dma_address != SG_ENT_PHYS_ADDRESS(sg))
-                       sync_single(hwdev, (void *) sg->dma_address,
+                       sync_single(hwdev, phys_to_virt(sg->dma_address),
                                    sg->dma_length, dir, target);
 }