*                     domains are added using same fwnode
  * @ops:               Domain operation callbacks
  * @host_data:         Controller private data pointer
+ * @dev:               Device which creates the domain
  * @dgc_info:          Geneneric chip information structure pointer used to
  *                     create generic chips for the domain if not NULL.
  * @init:              Function called when the domain is created.
        const char                              *name_suffix;
        const struct irq_domain_ops             *ops;
        void                                    *host_data;
+       struct device                           *dev;
 #ifdef CONFIG_IRQ_DOMAIN_HIERARCHY
        /**
         * @parent: Pointer to the parent irq domain used in a hierarchy domain
 
  *                     gets initialized to the maximum software index limit
  *                     by the domain creation code.
  * @ops:               The callback data structure
+ * @dev:               Device which creates the domain
  * @chip:              Optional: associated interrupt chip
  * @chip_data:         Optional: associated interrupt chip data
  * @handler:           Optional: associated interrupt flow handler
        enum irq_domain_bus_token       bus_token;
        unsigned int                    hwsize;
        struct msi_domain_ops           *ops;
+       struct device                   *dev;
        struct irq_chip                 *chip;
        void                            *chip_data;
        irq_flow_handler_t              handler;
 
 
        domain->flags |= info->domain_flags;
        domain->exit = info->exit;
+       domain->dev = info->dev;
 
 #ifdef CONFIG_IRQ_DOMAIN_HIERARCHY
        if (info->parent) {
 
 
        if (domain) {
                irq_domain_update_bus_token(domain, info->bus_token);
+               domain->dev = info->dev;
                if (info->flags & MSI_FLAG_PARENT_PM_DEV)
                        domain->pm_dev = parent->pm_dev;
        }
        bundle->info.data = domain_data;
        bundle->info.chip_data = chip_data;
        bundle->info.alloc_data = &bundle->alloc_info;
+       bundle->info.dev = dev;
 
        pops = parent->msi_parent_ops;
        snprintf(bundle->name, sizeof(bundle->name), "%s%s-%s",
        if (!domain)
                return false;
 
-       domain->dev = dev;
        dev->msi.data->__domains[domid].domain = domain;
 
        if (msi_domain_prepare_irqs(domain, dev, hwsize, &bundle->alloc_info)) {