Commit 8cec63e5 authored by Lu Baolu's avatar Lu Baolu Committed by Joerg Roedel

iommu: Remove iommu_callback_data

The iommu_callback_data is not used anywhere, remove it to make
the code more concise.
Signed-off-by: default avatarLu Baolu <baolu.lu@linux.intel.com>
Signed-off-by: default avatarJoerg Roedel <jroedel@suse.de>
parent 8c2ffd91
...@@ -45,10 +45,6 @@ static unsigned int iommu_def_domain_type = IOMMU_DOMAIN_DMA; ...@@ -45,10 +45,6 @@ static unsigned int iommu_def_domain_type = IOMMU_DOMAIN_DMA;
#endif #endif
static bool iommu_dma_strict __read_mostly = true; static bool iommu_dma_strict __read_mostly = true;
struct iommu_callback_data {
const struct iommu_ops *ops;
};
struct iommu_group { struct iommu_group {
struct kobject kobj; struct kobject kobj;
struct kobject *devices_kobj; struct kobject *devices_kobj;
...@@ -1215,9 +1211,6 @@ static int iommu_bus_init(struct bus_type *bus, const struct iommu_ops *ops) ...@@ -1215,9 +1211,6 @@ static int iommu_bus_init(struct bus_type *bus, const struct iommu_ops *ops)
{ {
int err; int err;
struct notifier_block *nb; struct notifier_block *nb;
struct iommu_callback_data cb = {
.ops = ops,
};
nb = kzalloc(sizeof(struct notifier_block), GFP_KERNEL); nb = kzalloc(sizeof(struct notifier_block), GFP_KERNEL);
if (!nb) if (!nb)
...@@ -1229,7 +1222,7 @@ static int iommu_bus_init(struct bus_type *bus, const struct iommu_ops *ops) ...@@ -1229,7 +1222,7 @@ static int iommu_bus_init(struct bus_type *bus, const struct iommu_ops *ops)
if (err) if (err)
goto out_free; goto out_free;
err = bus_for_each_dev(bus, NULL, &cb, add_iommu_group); err = bus_for_each_dev(bus, NULL, NULL, add_iommu_group);
if (err) if (err)
goto out_err; goto out_err;
...@@ -1238,7 +1231,7 @@ static int iommu_bus_init(struct bus_type *bus, const struct iommu_ops *ops) ...@@ -1238,7 +1231,7 @@ static int iommu_bus_init(struct bus_type *bus, const struct iommu_ops *ops)
out_err: out_err:
/* Clean up */ /* Clean up */
bus_for_each_dev(bus, NULL, &cb, remove_iommu_group); bus_for_each_dev(bus, NULL, NULL, remove_iommu_group);
bus_unregister_notifier(bus, nb); bus_unregister_notifier(bus, nb);
out_free: out_free:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment