diff options
| author | Joerg Roedel <jroedel@suse.de> | 2017-08-22 17:35:15 +0300 |
|---|---|---|
| committer | Joerg Roedel <jroedel@suse.de> | 2017-08-22 17:35:15 +0300 |
| commit | 894901b5c9433c6cdc2b997e4d35c1807572bd77 (patch) | |
| tree | 4ad07e426c473e5cd7553421d5a0beb0f551cf70 /include | |
| parent | 46cc815d6d8c3c9dd18ffae1e3e818eb3ce2c788 (diff) | |
| parent | 2926a2aa5c14fb2add75e6584845b1c03022235f (diff) | |
| download | linux-894901b5c9433c6cdc2b997e4d35c1807572bd77.tar.xz | |
Merge branch 'iommu/fixes' into arm/mediatek
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/iommu.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/include/linux/iommu.h b/include/linux/iommu.h index 2cb54adc4a33..176f7569d874 100644 --- a/include/linux/iommu.h +++ b/include/linux/iommu.h @@ -240,7 +240,7 @@ struct iommu_device { struct list_head list; const struct iommu_ops *ops; struct fwnode_handle *fwnode; - struct device dev; + struct device *dev; }; int iommu_device_register(struct iommu_device *iommu); @@ -265,6 +265,11 @@ static inline void iommu_device_set_fwnode(struct iommu_device *iommu, iommu->fwnode = fwnode; } +static inline struct iommu_device *dev_to_iommu_device(struct device *dev) +{ + return (struct iommu_device *)dev_get_drvdata(dev); +} + #define IOMMU_GROUP_NOTIFY_ADD_DEVICE 1 /* Device added */ #define IOMMU_GROUP_NOTIFY_DEL_DEVICE 2 /* Pre Device removed */ #define IOMMU_GROUP_NOTIFY_BIND_DRIVER 3 /* Pre Driver bind */ @@ -589,6 +594,11 @@ static inline void iommu_device_set_fwnode(struct iommu_device *iommu, { } +static inline struct iommu_device *dev_to_iommu_device(struct device *dev) +{ + return NULL; +} + static inline void iommu_device_unregister(struct iommu_device *iommu) { } |
