]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/iommu/amd_iommu_types.h
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless
[karo-tx-linux.git] / drivers / iommu / amd_iommu_types.h
index 8e1a6460f68315b5a9787f9b92ac855924062fa6..2452f3b7173619c449c04f025e2e2ff73cc44f29 100644 (file)
 #define CONTROL_EVT_LOG_EN      0x02ULL
 #define CONTROL_EVT_INT_EN      0x03ULL
 #define CONTROL_COMWAIT_EN      0x04ULL
+#define CONTROL_INV_TIMEOUT    0x05ULL
 #define CONTROL_PASSPW_EN       0x08ULL
 #define CONTROL_RESPASSPW_EN    0x09ULL
 #define CONTROL_COHERENT_EN     0x0aULL
 #define CONTROL_PPR_EN          0x0fULL
 #define CONTROL_GT_EN           0x10ULL
 
+#define CTRL_INV_TO_MASK       (7 << CONTROL_INV_TIMEOUT)
+#define CTRL_INV_TO_NONE       0
+#define CTRL_INV_TO_1MS                1
+#define CTRL_INV_TO_10MS       2
+#define CTRL_INV_TO_100MS      3
+#define CTRL_INV_TO_1S         4
+#define CTRL_INV_TO_10S                5
+#define CTRL_INV_TO_100S       6
+
 /* command specific defines */
 #define CMD_COMPL_WAIT          0x01
 #define CMD_INV_DEV_ENTRY       0x02
@@ -360,6 +370,8 @@ struct amd_iommu_fault {
 #define PPR_FAULT_RSVD  (1 << 7)
 #define PPR_FAULT_GN    (1 << 8)
 
+struct iommu_domain;
+
 /*
  * This structure contains generic data for  IOMMU protection domains
  * independent of their use.
@@ -379,6 +391,8 @@ struct protection_domain {
        unsigned dev_cnt;       /* devices assigned to this domain */
        unsigned dev_iommu[MAX_IOMMUS]; /* per-IOMMU reference count */
        void *priv;             /* private data */
+       struct iommu_domain *iommu_domain; /* Pointer to generic
+                                             domain structure */
 
 };
 
@@ -400,6 +414,7 @@ struct iommu_dev_data {
        } ats;                            /* ATS state */
        bool pri_tlp;                     /* PASID TLB required for
                                             PPR completions */
+       u32 errata;                       /* Bitmap for errata to apply */
 };
 
 /*