dma-mapping-fast: Fix iova address leak with non-zero scatterlist offset
The underlying arm-smmu hardware only supports mapping addresses
aligned to PAGE_SIZE. Thus the actual mapped region may be larger than
the range returned by iommu_map_sg():
[sg_dma_address(), sg_dma_address() + sg->length)
When unmapping, ensure the same alignment requirements are applied
in order to avoid leaking iova addresses.
Change-Id: I1f5d5185d003cfe104b4a67efc1fe88f105f015f
Signed-off-by:
Patrick Daly <pdaly@codeaurora.org>
Loading
Please register or sign in to comment