summaryrefslogtreecommitdiffstats
path: root/arch/x86/include/asm/amd_iommu_types.h
diff options
context:
space:
mode:
authorJoerg Roedel2009-08-26 15:26:30 +0200
committerJoerg Roedel2009-09-03 16:15:42 +0200
commit0feae533ddebe02cda6ccce5cac7349b446776a8 (patch)
treed9c82d7ebec45d96194aeaf27acfbbd2015545ac /arch/x86/include/asm/amd_iommu_types.h
parentx86/amd-iommu: Add core functions for pd allocation/freeing (diff)
downloadkernel-qcow2-linux-0feae533ddebe02cda6ccce5cac7349b446776a8.tar.gz
kernel-qcow2-linux-0feae533ddebe02cda6ccce5cac7349b446776a8.tar.xz
kernel-qcow2-linux-0feae533ddebe02cda6ccce5cac7349b446776a8.zip
x86/amd-iommu: Add passthrough mode initialization functions
When iommu=pt is passed on kernel command line the devices should run untranslated. This requires the allocation of a special domain for that purpose. This patch implements the allocation and initialization path for iommu=pt. Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Diffstat (limited to 'arch/x86/include/asm/amd_iommu_types.h')
-rw-r--r--arch/x86/include/asm/amd_iommu_types.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/x86/include/asm/amd_iommu_types.h b/arch/x86/include/asm/amd_iommu_types.h
index 0c878caaa0a2..49f7453bff76 100644
--- a/arch/x86/include/asm/amd_iommu_types.h
+++ b/arch/x86/include/asm/amd_iommu_types.h
@@ -143,6 +143,7 @@
#define EVT_BUFFER_SIZE 8192 /* 512 entries */
#define EVT_LEN_MASK (0x9ULL << 56)
+#define PAGE_MODE_NONE 0x00
#define PAGE_MODE_1_LEVEL 0x01
#define PAGE_MODE_2_LEVEL 0x02
#define PAGE_MODE_3_LEVEL 0x03
@@ -194,6 +195,9 @@
#define PD_DMA_OPS_MASK (1UL << 0) /* domain used for dma_ops */
#define PD_DEFAULT_MASK (1UL << 1) /* domain is a default dma_ops
domain for an IOMMU */
+#define PD_PASSTHROUGH_MASK (1UL << 2) /* domain has no page
+ translation */
+
extern bool amd_iommu_dump;
#define DUMP_printk(format, arg...) \
do { \