1 // SPDX-License-Identifier: GPL-2.0-only
2 // Copyright (C) 2022 Linutronix GmbH
3 // Copyright (C) 2022 Intel
5 #ifndef _DRIVERS_IRQCHIP_IRQ_MSI_LIB_H
6 #define _DRIVERS_IRQCHIP_IRQ_MSI_LIB_H
8 #include <linux/bits.h>
9 #include <linux/irqdomain.h>
10 #include <linux/msi.h>
13 #define MATCH_PCI_MSI BIT(DOMAIN_BUS_PCI_MSI)
15 #define MATCH_PCI_MSI (0)
18 #define MATCH_PLATFORM_MSI BIT(DOMAIN_BUS_PLATFORM_MSI)
20 int msi_lib_irq_domain_select(struct irq_domain
*d
, struct irq_fwspec
*fwspec
,
21 enum irq_domain_bus_token bus_token
);
23 bool msi_lib_init_dev_msi_info(struct device
*dev
, struct irq_domain
*domain
,
24 struct irq_domain
*real_parent
,
25 struct msi_domain_info
*info
);
27 #endif /* _DRIVERS_IRQCHIP_IRQ_MSI_LIB_H */