[tip:,irq/core] genirq/irqdomain: Add irq_domain:: Dev for per device MSI domains

Message ID 167026471595.4906.7972815409340483633.tip-bot2@tip-bot2
State New
Headers
Series [tip:,irq/core] genirq/irqdomain: Add irq_domain:: Dev for per device MSI domains |

Commit Message

tip-bot2 for Thomas Gleixner Dec. 5, 2022, 6:25 p.m. UTC
  The following commit has been merged into the irq/core branch of tip:

Commit-ID:     4443664f298d1a2cba25a2e48d53b78f4138209b
Gitweb:        https://git.kernel.org/tip/4443664f298d1a2cba25a2e48d53b78f4138209b
Author:        Thomas Gleixner <tglx@linutronix.de>
AuthorDate:    Fri, 25 Nov 2022 00:25:54 +01:00
Committer:     Thomas Gleixner <tglx@linutronix.de>
CommitterDate: Mon, 05 Dec 2022 19:21:01 +01:00

genirq/irqdomain: Add irq_domain:: Dev for per device MSI domains

Per device domains require the device pointer of the device which
instantiated the domain for some purposes. Add the pointer to struct
irq_domain. It will be used in the next step which provides the
infrastructure to create per device MSI domains.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Kevin Tian <kevin.tian@intel.com>
Acked-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20221124232325.618807601@linutronix.de

---
 include/linux/irqdomain.h | 4 ++++
 1 file changed, 4 insertions(+)
  

Patch

diff --git a/include/linux/irqdomain.h b/include/linux/irqdomain.h
index a668cc0..a372086 100644
--- a/include/linux/irqdomain.h
+++ b/include/linux/irqdomain.h
@@ -132,6 +132,9 @@  struct irq_domain_chip_generic;
  * @gc:		Pointer to a list of generic chips. There is a helper function for
  *		setting up one or more generic chips for interrupt controllers
  *		drivers using the generic chip library which uses this pointer.
+ * @dev:	Pointer to the device which instantiated the irqdomain
+ *		With per device irq domains this is not necessarily the same
+ *		as @pm_dev.
  * @pm_dev:	Pointer to a device that can be utilized for power management
  *		purposes related to the irq domain.
  * @parent:	Pointer to parent irq_domain to support hierarchy irq_domains
@@ -155,6 +158,7 @@  struct irq_domain {
 	struct fwnode_handle		*fwnode;
 	enum irq_domain_bus_token	bus_token;
 	struct irq_domain_chip_generic	*gc;
+	struct device			*dev;
 	struct device			*pm_dev;
 #ifdef	CONFIG_IRQ_DOMAIN_HIERARCHY
 	struct irq_domain		*parent;