Skip to content

Commit 13e7acc

Browse files
committed
genirq: Get rid of GENERIC_MSI_IRQ_DOMAIN
Adjust to reality and remove another layer of pointless Kconfig indirection. CONFIG_GENERIC_MSI_IRQ is good enough to serve all purposes. Signed-off-by: Thomas Gleixner <[email protected]> Reviewed-by: Jason Gunthorpe <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent a474d3f commit 13e7acc

File tree

16 files changed

+24
-37
lines changed

16 files changed

+24
-37
lines changed

drivers/base/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ obj-$(CONFIG_REGMAP) += regmap/
2222
obj-$(CONFIG_SOC_BUS) += soc.o
2323
obj-$(CONFIG_PINCTRL) += pinctrl.o
2424
obj-$(CONFIG_DEV_COREDUMP) += devcoredump.o
25-
obj-$(CONFIG_GENERIC_MSI_IRQ_DOMAIN) += platform-msi.o
25+
obj-$(CONFIG_GENERIC_MSI_IRQ) += platform-msi.o
2626
obj-$(CONFIG_GENERIC_ARCH_TOPOLOGY) += arch_topology.o
2727
obj-$(CONFIG_GENERIC_ARCH_NUMA) += arch_numa.o
2828
obj-$(CONFIG_ACPI) += physical_location.o

drivers/bus/fsl-mc/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
config FSL_MC_BUS
99
bool "QorIQ DPAA2 fsl-mc bus driver"
1010
depends on OF && (ARCH_LAYERSCAPE || (COMPILE_TEST && (ARM || ARM64 || X86_LOCAL_APIC || PPC)))
11-
select GENERIC_MSI_IRQ_DOMAIN
11+
select GENERIC_MSI_IRQ
1212
help
1313
Driver to enable the bus infrastructure for the QorIQ DPAA2
1414
architecture. The fsl-mc bus driver handles discovery of

drivers/dma/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -462,7 +462,7 @@ config MV_XOR_V2
462462
select DMA_ENGINE
463463
select DMA_ENGINE_RAID
464464
select ASYNC_TX_ENABLE_CHANNEL_SWITCH
465-
select GENERIC_MSI_IRQ_DOMAIN
465+
select GENERIC_MSI_IRQ
466466
help
467467
Enable support for the Marvell version 2 XOR engine.
468468

drivers/dma/qcom/hidma.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -610,7 +610,7 @@ static irqreturn_t hidma_chirq_handler(int chirq, void *arg)
610610
return hidma_ll_inthandler(chirq, lldev);
611611
}
612612

613-
#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
613+
#ifdef CONFIG_GENERIC_MSI_IRQ
614614
static irqreturn_t hidma_chirq_handler_msi(int chirq, void *arg)
615615
{
616616
struct hidma_lldev **lldevp = arg;
@@ -671,7 +671,7 @@ static int hidma_sysfs_init(struct hidma_dev *dev)
671671
return device_create_file(dev->ddev.dev, dev->chid_attrs);
672672
}
673673

674-
#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
674+
#ifdef CONFIG_GENERIC_MSI_IRQ
675675
static void hidma_write_msi_msg(struct msi_desc *desc, struct msi_msg *msg)
676676
{
677677
struct device *dev = msi_desc_to_dev(desc);
@@ -687,7 +687,7 @@ static void hidma_write_msi_msg(struct msi_desc *desc, struct msi_msg *msg)
687687

688688
static void hidma_free_msis(struct hidma_dev *dmadev)
689689
{
690-
#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
690+
#ifdef CONFIG_GENERIC_MSI_IRQ
691691
struct device *dev = dmadev->ddev.dev;
692692
int i, virq;
693693

@@ -704,7 +704,7 @@ static void hidma_free_msis(struct hidma_dev *dmadev)
704704
static int hidma_request_msi(struct hidma_dev *dmadev,
705705
struct platform_device *pdev)
706706
{
707-
#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
707+
#ifdef CONFIG_GENERIC_MSI_IRQ
708708
int rc, i, virq;
709709

710710
rc = platform_msi_domain_alloc_irqs(&pdev->dev, HIDMA_MSI_INTS,

drivers/iommu/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -389,7 +389,7 @@ config ARM_SMMU_V3
389389
depends on ARM64
390390
select IOMMU_API
391391
select IOMMU_IO_PGTABLE_LPAE
392-
select GENERIC_MSI_IRQ_DOMAIN
392+
select GENERIC_MSI_IRQ
393393
help
394394
Support for implementations of the ARM System MMU architecture
395395
version 3 providing translation support to a PCIe root complex.

drivers/irqchip/Kconfig

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ config ARM_GIC_V3
3838

3939
config ARM_GIC_V3_ITS
4040
bool
41-
select GENERIC_MSI_IRQ_DOMAIN
41+
select GENERIC_MSI_IRQ
4242
default ARM_GIC_V3
4343

4444
config ARM_GIC_V3_ITS_PCI
@@ -375,7 +375,7 @@ config MVEBU_ICU
375375

376376
config MVEBU_ODMI
377377
bool
378-
select GENERIC_MSI_IRQ_DOMAIN
378+
select GENERIC_MSI_IRQ
379379

380380
config MVEBU_PIC
381381
bool
@@ -488,7 +488,7 @@ config IMX_MU_MSI
488488
default m if ARCH_MXC
489489
select IRQ_DOMAIN
490490
select IRQ_DOMAIN_HIERARCHY
491-
select GENERIC_MSI_IRQ_DOMAIN
491+
select GENERIC_MSI_IRQ
492492
help
493493
Provide a driver for the i.MX Messaging Unit block used as a
494494
CPU-to-CPU MSI controller. This requires a specially crafted DT

drivers/mailbox/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ config BCM_FLEXRM_MBOX
223223
tristate "Broadcom FlexRM Mailbox"
224224
depends on ARM64
225225
depends on ARCH_BCM_IPROC || COMPILE_TEST
226-
select GENERIC_MSI_IRQ_DOMAIN
226+
select GENERIC_MSI_IRQ
227227
default m if ARCH_BCM_IPROC
228228
help
229229
Mailbox implementation of the Broadcom FlexRM ring manager,

drivers/pci/Kconfig

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ source "drivers/pci/pcie/Kconfig"
3838

3939
config PCI_MSI
4040
bool "Message Signaled Interrupts (MSI and MSI-X)"
41-
select GENERIC_MSI_IRQ_DOMAIN
4241
select GENERIC_MSI_IRQ
4342
help
4443
This allows device drivers to enable MSI (Message Signaled

drivers/perf/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ config ARM_PMU_ACPI
9393
config ARM_SMMU_V3_PMU
9494
tristate "ARM SMMUv3 Performance Monitors Extension"
9595
depends on (ARM64 && ACPI) || (COMPILE_TEST && 64BIT)
96-
depends on GENERIC_MSI_IRQ_DOMAIN
96+
depends on GENERIC_MSI_IRQ
9797
help
9898
Provides support for the ARM SMMUv3 Performance Monitor Counter
9999
Groups (PMCG), which provide monitoring of transactions passing

drivers/soc/ti/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,6 @@ endif # SOC_TI
9898

9999
config TI_SCI_INTA_MSI_DOMAIN
100100
bool
101-
select GENERIC_MSI_IRQ_DOMAIN
101+
select GENERIC_MSI_IRQ
102102
help
103103
Driver to enable Interrupt Aggregator specific MSI Domain.

include/asm-generic/msi.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
#include <linux/types.h>
66

7-
#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
7+
#ifdef CONFIG_GENERIC_MSI_IRQ
88

99
#ifndef NUM_MSI_ALLOC_SCRATCHPAD_REGS
1010
# define NUM_MSI_ALLOC_SCRATCHPAD_REGS 2
@@ -36,6 +36,6 @@ typedef struct msi_alloc_info {
3636

3737
#define GENERIC_MSI_DOMAIN_OPS 1
3838

39-
#endif /* CONFIG_GENERIC_MSI_IRQ_DOMAIN */
39+
#endif /* CONFIG_GENERIC_MSI_IRQ */
4040

4141
#endif

include/linux/device.h

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -378,10 +378,8 @@ struct dev_links_info {
378378
* @data: Pointer to MSI device data
379379
*/
380380
struct dev_msi_info {
381-
#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
382-
struct irq_domain *domain;
383-
#endif
384381
#ifdef CONFIG_GENERIC_MSI_IRQ
382+
struct irq_domain *domain;
385383
struct msi_device_data *data;
386384
#endif
387385
};
@@ -742,7 +740,7 @@ static inline void set_dev_node(struct device *dev, int node)
742740

743741
static inline struct irq_domain *dev_get_msi_domain(const struct device *dev)
744742
{
745-
#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
743+
#ifdef CONFIG_GENERIC_MSI_IRQ
746744
return dev->msi.domain;
747745
#else
748746
return NULL;
@@ -751,7 +749,7 @@ static inline struct irq_domain *dev_get_msi_domain(const struct device *dev)
751749

752750
static inline void dev_set_msi_domain(struct device *dev, struct irq_domain *d)
753751
{
754-
#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
752+
#ifdef CONFIG_GENERIC_MSI_IRQ
755753
dev->msi.domain = d;
756754
#endif
757755
}

include/linux/gpio/driver.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ struct gpio_chip;
2727

2828
union gpio_irq_fwspec {
2929
struct irq_fwspec fwspec;
30-
#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
30+
#ifdef CONFIG_GENERIC_MSI_IRQ
3131
msi_alloc_info_t msiinfo;
3232
#endif
3333
};

include/linux/msi.h

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,7 @@ void __get_cached_msi_msg(struct msi_desc *entry, struct msi_msg *msg);
7979
#ifdef CONFIG_GENERIC_MSI_IRQ
8080
void get_cached_msi_msg(unsigned int irq, struct msi_msg *msg);
8181
#else
82-
static inline void get_cached_msi_msg(unsigned int irq, struct msi_msg *msg)
83-
{
84-
}
82+
static inline void get_cached_msi_msg(unsigned int irq, struct msi_msg *msg) { }
8583
#endif
8684

8785
typedef void (*irq_write_msi_msg_t)(struct msi_desc *desc,
@@ -278,7 +276,7 @@ static inline void msi_device_destroy_sysfs(struct device *dev) { }
278276
*/
279277
bool arch_restore_msi_irqs(struct pci_dev *dev);
280278

281-
#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
279+
#ifdef CONFIG_GENERIC_MSI_IRQ
282280

283281
#include <linux/irqhandler.h>
284282

@@ -451,7 +449,7 @@ int platform_msi_device_domain_alloc(struct irq_domain *domain, unsigned int vir
451449
void platform_msi_device_domain_free(struct irq_domain *domain, unsigned int virq,
452450
unsigned int nvec);
453451
void *platform_msi_get_host_data(struct irq_domain *domain);
454-
#endif /* CONFIG_GENERIC_MSI_IRQ_DOMAIN */
452+
#endif /* CONFIG_GENERIC_MSI_IRQ */
455453

456454
/* PCI specific interfaces */
457455
#ifdef CONFIG_PCI_MSI

kernel/irq/Kconfig

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -86,15 +86,10 @@ config GENERIC_IRQ_IPI
8686
depends on SMP
8787
select IRQ_DOMAIN_HIERARCHY
8888

89-
# Generic MSI interrupt support
90-
config GENERIC_MSI_IRQ
91-
bool
92-
9389
# Generic MSI hierarchical interrupt domain support
94-
config GENERIC_MSI_IRQ_DOMAIN
90+
config GENERIC_MSI_IRQ
9591
bool
9692
select IRQ_DOMAIN_HIERARCHY
97-
select GENERIC_MSI_IRQ
9893

9994
config IRQ_MSI_IOMMU
10095
bool

kernel/irq/msi.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -461,7 +461,6 @@ static inline int msi_sysfs_populate_desc(struct device *dev, struct msi_desc *d
461461
static inline void msi_sysfs_remove_desc(struct device *dev, struct msi_desc *desc) { }
462462
#endif /* !CONFIG_SYSFS */
463463

464-
#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
465464
static int __msi_domain_alloc_irqs(struct irq_domain *domain, struct device *dev, int nvec);
466465
static void __msi_domain_free_irqs(struct irq_domain *domain, struct device *dev);
467466

@@ -1058,5 +1057,3 @@ struct msi_domain_info *msi_get_domain_info(struct irq_domain *domain)
10581057
{
10591058
return (struct msi_domain_info *)domain->host_data;
10601059
}
1061-
1062-
#endif /* CONFIG_GENERIC_MSI_IRQ_DOMAIN */

0 commit comments

Comments
 (0)