iommu/vt-d: Convert IR set_affinity function to remap_ops
The function to set interrupt affinity with interrupt
remapping enabled is Intel specific too. So move it to the
irq_remap_ops too.
Signed-off-by: Joerg Roedel <[email protected]>
Acked-by: Yinghai Lu <[email protected]>
Cc: David Woodhouse <[email protected]>
Cc: Alex Williamson <[email protected]>
Signed-off-by: Suresh Siddha <[email protected]>
Signed-off-by: Joerg Roedel <[email protected]>
diff --git a/drivers/iommu/intr_remapping.c b/drivers/iommu/intr_remapping.c
index 739148a..2f4f27f 100644
--- a/drivers/iommu/intr_remapping.c
+++ b/drivers/iommu/intr_remapping.c
@@ -110,3 +110,12 @@
return remap_ops->setup_ioapic_entry(irq, entry, destination,
vector, attr);
}
+
+int intr_set_affinity(struct irq_data *data, const struct cpumask *mask,
+ bool force)
+{
+ if (!remap_ops || !remap_ops->set_affinity)
+ return 0;
+
+ return remap_ops->set_affinity(data, mask, force);
+}