History

iommu/io-pgtable-arm: Prepare for TTBR1 usage

Now that we can correctly extract top-level indices without relying on the remaining upper bits being zero, the only remaining impediments to using a given table for TTBR1 are the address validation on map/unmap and the awkward TCR translation granule format. Add a quirk so that we can do the right thing at those points.

Robin Murphy committed 7 years ago

Commit db690301 parent ac4b80e2 files · +23 −6Browse files

Showing the changes to include/linux (1 of 2 files). Show all

Unified · Split

include/linux/io-pgtable.h+4−0
@@ -83,12 +83,16 @@ struct io_pgtable_cfg { · 82 unmodified lines
8383 * IO_PGTABLE_QUIRK_NON_STRICT: Skip issuing synchronous leaf TLBIs
8484 * on unmap, for DMA domains using the flush queue mechanism for
8585 * delayed invalidation.
86+ *
87+ * IO_PGTABLE_QUIRK_ARM_TTBR1: (ARM LPAE format) Configure the table
88+ * for use in the upper half of a split address space.
8689 */
8790 #define IO_PGTABLE_QUIRK_ARM_NS BIT(0)
8891 #define IO_PGTABLE_QUIRK_NO_PERMS BIT(1)
8992 #define IO_PGTABLE_QUIRK_TLBI_ON_MAP BIT(2)
9093 #define IO_PGTABLE_QUIRK_ARM_MTK_EXT BIT(3)
9194 #define IO_PGTABLE_QUIRK_NON_STRICT BIT(4)
95+ #define IO_PGTABLE_QUIRK_ARM_TTBR1 BIT(5)
9296 unsigned long quirks;
9397 unsigned long pgsize_bitmap;
9498 unsigned int ias;