Messages in this thread Patch in this message | | | Date | Wed, 28 Sep 2022 13:37:22 -0000 | From | "irqchip-bot for Huacai Chen" <> | Subject | [irqchip: irq/irqchip-next] irqchip: Make irqchip_init() usable on pure ACPI systems |
| |
The following commit has been merged into the irq/irqchip-next branch of irqchip:
Commit-ID: 612d5494aef9bd2ab68d585a8c0ac2b16d12d520 Gitweb: https://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms/612d5494aef9bd2ab68d585a8c0ac2b16d12d520 Author: Huacai Chen <chenhuacai@loongson.cn> AuthorDate: Tue, 27 Sep 2022 20:45:57 +08:00 Committer: Marc Zyngier <maz@kernel.org> CommitterDate: Wed, 28 Sep 2022 14:11:28 +01:00
irqchip: Make irqchip_init() usable on pure ACPI systems
Pure ACPI systems (e.g., LoongArch) do not need OF_IRQ, but still require irqchip_init() to perform the ACPI irqchip probing, even when OF_IRQ isn't selected.
Relax the dependency to enable the generic irqchip support when ACPI_GENERIC_GSI is configured.
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn> Tested-by: Tiezhu Yang <yangtiezhu@loongson.cn> [maz: revamped commit message] Signed-off-by: Marc Zyngier <maz@kernel.org> Link: https://lore.kernel.org/r/20220927124557.3246737-1-chenhuacai@loongson.cn --- drivers/irqchip/Kconfig | 2 +- include/linux/of_irq.h | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/irqchip/Kconfig b/drivers/irqchip/Kconfig index 66b9fa4..93ad04d 100644 --- a/drivers/irqchip/Kconfig +++ b/drivers/irqchip/Kconfig @@ -3,7 +3,7 @@ menu "IRQ chip support" config IRQCHIP def_bool y - depends on OF_IRQ + depends on (OF_IRQ || ACPI_GENERIC_GSI) config ARM_GIC bool diff --git a/include/linux/of_irq.h b/include/linux/of_irq.h index 83fccd0..d6d3eae 100644 --- a/include/linux/of_irq.h +++ b/include/linux/of_irq.h @@ -37,9 +37,8 @@ extern unsigned int irq_create_of_mapping(struct of_phandle_args *irq_data); extern int of_irq_to_resource(struct device_node *dev, int index, struct resource *r); -extern void of_irq_init(const struct of_device_id *matches); - #ifdef CONFIG_OF_IRQ +extern void of_irq_init(const struct of_device_id *matches); extern int of_irq_parse_one(struct device_node *device, int index, struct of_phandle_args *out_irq); extern int of_irq_count(struct device_node *dev); @@ -57,6 +56,9 @@ extern struct irq_domain *of_msi_map_get_device_domain(struct device *dev, extern void of_msi_configure(struct device *dev, struct device_node *np); u32 of_msi_map_id(struct device *dev, struct device_node *msi_np, u32 id_in); #else +static inline void of_irq_init(const struct of_device_id *matches) +{ +} static inline int of_irq_parse_one(struct device_node *device, int index, struct of_phandle_args *out_irq) {
| |