aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoerg Roedel <joerg.roedel@amd.com>2009-09-02 11:26:09 -0400
committerJoerg Roedel <joerg.roedel@amd.com>2009-09-03 10:03:49 -0400
commit674d798a80cb6ea1defa01899099f40d9124423c (patch)
treedbdf659ebe91c17228385cb1e65c62f6f914f4f2
parent8f7a017ce05ed4522809448e169daa44fe6edeb1 (diff)
x86/amd-iommu: Remove old page table handling macros
These macros are not longer required. So remove them. Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
-rw-r--r--arch/x86/include/asm/amd_iommu_types.h19
1 files changed, 0 insertions, 19 deletions
diff --git a/arch/x86/include/asm/amd_iommu_types.h b/arch/x86/include/asm/amd_iommu_types.h
index 1b4b3d6c9f04..d66430de5f7c 100644
--- a/arch/x86/include/asm/amd_iommu_types.h
+++ b/arch/x86/include/asm/amd_iommu_types.h
@@ -150,11 +150,6 @@
150#define PAGE_MODE_5_LEVEL 0x05 150#define PAGE_MODE_5_LEVEL 0x05
151#define PAGE_MODE_6_LEVEL 0x06 151#define PAGE_MODE_6_LEVEL 0x06
152 152
153#define IOMMU_PDE_NL_0 0x000ULL
154#define IOMMU_PDE_NL_1 0x200ULL
155#define IOMMU_PDE_NL_2 0x400ULL
156#define IOMMU_PDE_NL_3 0x600ULL
157
158#define PM_LEVEL_SHIFT(x) (12 + ((x) * 9)) 153#define PM_LEVEL_SHIFT(x) (12 + ((x) * 9))
159#define PM_LEVEL_SIZE(x) (((x) < 6) ? \ 154#define PM_LEVEL_SIZE(x) (((x) < 6) ? \
160 ((1ULL << PM_LEVEL_SHIFT((x))) - 1): \ 155 ((1ULL << PM_LEVEL_SHIFT((x))) - 1): \
@@ -164,15 +159,6 @@
164#define PM_LEVEL_PDE(x, a) ((a) | PM_LEVEL_ENC((x)) | \ 159#define PM_LEVEL_PDE(x, a) ((a) | PM_LEVEL_ENC((x)) | \
165 IOMMU_PTE_P | IOMMU_PTE_IR | IOMMU_PTE_IW) 160 IOMMU_PTE_P | IOMMU_PTE_IR | IOMMU_PTE_IW)
166 161
167
168#define IOMMU_PTE_L2_INDEX(address) (((address) >> 30) & 0x1ffULL)
169#define IOMMU_PTE_L1_INDEX(address) (((address) >> 21) & 0x1ffULL)
170#define IOMMU_PTE_L0_INDEX(address) (((address) >> 12) & 0x1ffULL)
171
172#define IOMMU_MAP_SIZE_L1 (1ULL << 21)
173#define IOMMU_MAP_SIZE_L2 (1ULL << 30)
174#define IOMMU_MAP_SIZE_L3 (1ULL << 39)
175
176#define IOMMU_PTE_P (1ULL << 0) 162#define IOMMU_PTE_P (1ULL << 0)
177#define IOMMU_PTE_TV (1ULL << 1) 163#define IOMMU_PTE_TV (1ULL << 1)
178#define IOMMU_PTE_U (1ULL << 59) 164#define IOMMU_PTE_U (1ULL << 59)
@@ -180,11 +166,6 @@
180#define IOMMU_PTE_IR (1ULL << 61) 166#define IOMMU_PTE_IR (1ULL << 61)
181#define IOMMU_PTE_IW (1ULL << 62) 167#define IOMMU_PTE_IW (1ULL << 62)
182 168
183#define IOMMU_L1_PDE(address) \
184 ((address) | IOMMU_PDE_NL_1 | IOMMU_PTE_P | IOMMU_PTE_IR | IOMMU_PTE_IW)
185#define IOMMU_L2_PDE(address) \
186 ((address) | IOMMU_PDE_NL_2 | IOMMU_PTE_P | IOMMU_PTE_IR | IOMMU_PTE_IW)
187
188#define IOMMU_PAGE_MASK (((1ULL << 52) - 1) & ~0xfffULL) 169#define IOMMU_PAGE_MASK (((1ULL << 52) - 1) & ~0xfffULL)
189#define IOMMU_PTE_PRESENT(pte) ((pte) & IOMMU_PTE_P) 170#define IOMMU_PTE_PRESENT(pte) ((pte) & IOMMU_PTE_P)
190#define IOMMU_PTE_PAGE(pte) (phys_to_virt((pte) & IOMMU_PAGE_MASK)) 171#define IOMMU_PTE_PAGE(pte) (phys_to_virt((pte) & IOMMU_PAGE_MASK))