diff options
author | Joerg Roedel <joerg.roedel@amd.com> | 2011-11-28 15:11:02 +0100 |
---|---|---|
committer | Hiroshi DOYU <hdoyu@nvidia.com> | 2012-01-23 11:11:39 +0200 |
commit | f3c7fe5aa2b9ddcfbac4a64335a6139558645fc9 (patch) | |
tree | ce6cddafa55b1e1e05451b2c6cc1870c8c70470e /drivers/iommu/amd_iommu_types.h | |
parent | 6ff803185644748146d45b9dbaade53cec7e6f24 (diff) |
iommu/amd: Add iommuv2 flag to struct amd_iommu
In mixed IOMMU setups this flag inidicates whether an IOMMU
supports the v2 features or not. This patch also adds a
global flag together with a function to query that flag from
other code. The flag shows if at least one IOMMUv2 is in the
system.
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Diffstat (limited to 'drivers/iommu/amd_iommu_types.h')
-rw-r--r-- | drivers/iommu/amd_iommu_types.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/iommu/amd_iommu_types.h b/drivers/iommu/amd_iommu_types.h index a6e1dc616afe..7e81094ab73b 100644 --- a/drivers/iommu/amd_iommu_types.h +++ b/drivers/iommu/amd_iommu_types.h @@ -414,6 +414,9 @@ struct amd_iommu { /* Extended features */ u64 features; + /* IOMMUv2 */ + bool is_iommu_v2; + /* * Capability pointer. There could be more than one IOMMU per PCI * device function if there are more than one AMD IOMMU capability @@ -570,6 +573,8 @@ extern bool amd_iommu_unmap_flush; /* Smallest number of PASIDs supported by any IOMMU in the system */ extern u32 amd_iommu_max_pasids; +extern bool amd_iommu_v2_present; + /* takes bus and device/function and returns the device id * FIXME: should that be in generic PCI code? */ static inline u16 calc_devid(u8 bus, u8 devfn) |