• Thierry Reding's avatar
    iommu/tegra-smmu: Fix page tables in > 4 GiB memory · 96d3ab80
    Thierry Reding authored
    Page tables that reside in physical memory beyond the 4 GiB boundary are
    currently not working properly. The reason is that when the physical
    address for page directory entries is read, it gets truncated at 32 bits
    and can cause crashes when passing that address to the DMA API.
    
    Fix this by first casting the PDE value to a dma_addr_t and then using
    the page frame number mask for the SMMU instance to mask out the invalid
    bits, which are typically used for mapping attributes, etc.
    Signed-off-by: default avatarThierry Reding <treding@nvidia.com>
    Signed-off-by: default avatarJoerg Roedel <jroedel@suse.de>
    96d3ab80
tegra-smmu.c 25 KB