Skip to content

Commit

Permalink
iommu/amd: Do not set the D bit on AMD v2 table entries
Browse files Browse the repository at this point in the history
The manual says that bit 6 is IGN for all Page-Table Base Address
pointers, don't set it.

Fixes: aaac38f ("iommu/amd: Initial support for AMD IOMMU v2 page table")
Reviewed-by: Vasant Hegde <[email protected]>
Signed-off-by: Jason Gunthorpe <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Joerg Roedel <[email protected]>
  • Loading branch information
jgunthorpe authored and joergroedel committed Sep 4, 2024
1 parent 7e51586 commit 2910a7f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/iommu/amd/io_pgtable_v2.c
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ static inline u64 set_pgtable_attr(u64 *page)
u64 prot;

prot = IOMMU_PAGE_PRESENT | IOMMU_PAGE_RW | IOMMU_PAGE_USER;
prot |= IOMMU_PAGE_ACCESS | IOMMU_PAGE_DIRTY;
prot |= IOMMU_PAGE_ACCESS;

return (iommu_virt_to_phys(page) | prot);
}
Expand Down

0 comments on commit 2910a7f

Please sign in to comment.