aboutsummaryrefslogtreecommitdiff
path: root/fs/xfs/libxfs/xfs_rmap_btree.c
diff options
context:
space:
mode:
authorStefano Stabellini <[email protected]>2020-07-10 15:34:25 -0700
committerJuergen Gross <[email protected]>2020-08-04 07:52:10 +0200
commit91ffe4ad534ab2262cbcfb339c5ae190c7ac0e7c (patch)
tree6e7e95da5dfd68878404419ef7a777f9df039fa8 /fs/xfs/libxfs/xfs_rmap_btree.c
parente9aab7e4ffbbf6eba8eaa66e351557c0c7562cff (diff)
swiotlb-xen: introduce phys_to_dma/dma_to_phys translations
With some devices physical addresses are different than dma addresses. To be able to deal with these cases, we need to call phys_to_dma on physical addresses (including machine addresses in Xen terminology) before returning them from xen_swiotlb_alloc_coherent and xen_swiotlb_map_page. We also need to convert dma addresses back to physical addresses using dma_to_phys in xen_swiotlb_free_coherent and xen_swiotlb_unmap_page if we want to do any operations on them. Call dma_to_phys in is_xen_swiotlb_buffer. Introduce xen_phys_to_dma and call phys_to_dma in its implementation. Introduce xen_dma_to_phys and call dma_to_phys in its implementation. Call xen_phys_to_dma/xen_dma_to_phys instead of xen_phys_to_bus/xen_bus_to_phys through swiotlb-xen.c. Everything is taken care of by these changes except for xen_swiotlb_alloc_coherent and xen_swiotlb_free_coherent, which need a few explicit phys_to_dma/dma_to_phys calls. Signed-off-by: Stefano Stabellini <[email protected]> Tested-by: Corey Minyard <[email protected]> Tested-by: Roman Shaposhnik <[email protected]> Reviewed-by: Juergen Gross <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Juergen Gross <[email protected]>
Diffstat (limited to 'fs/xfs/libxfs/xfs_rmap_btree.c')
0 files changed, 0 insertions, 0 deletions