Merge tag 'stable/for-linus-3.6-rc3-tag' of git://git.kernel.org/pub/scm/linux/kernel...
[firefly-linux-kernel-4.4.55.git] / include / linux / device.h
index 6de94151ff6f7e8646ab16d7f093cea3c079f1fa..52a5f15a2223ecb916391138ca9cb44f5d5d108a 100644 (file)
@@ -36,6 +36,7 @@ struct subsys_private;
 struct bus_type;
 struct device_node;
 struct iommu_ops;
+struct iommu_group;
 
 struct bus_attribute {
        struct attribute        attr;
@@ -687,8 +688,14 @@ struct device {
        const struct attribute_group **groups;  /* optional groups */
 
        void    (*release)(struct device *dev);
+       struct iommu_group      *iommu_group;
 };
 
+static inline struct device *kobj_to_dev(struct kobject *kobj)
+{
+       return container_of(kobj, struct device, kobj);
+}
+
 /* Get the wakeup routines, which depend on struct device */
 #include <linux/pm_wakeup.h>