irqdomain: couple cleanups and documentation
Subsystems (171)
cover irqdomain: couple cleanups and documentation
Hi,
while I was reading through the irqdomain code and headers, I found some naming and documentation hard to follow or incomplete. Especially the naming of _add/_create/_instantiate functions.
I tried to come up with a better state with this patchset. Despite I believe the state is much better when the patchset is applied, I totally do not insist on anything from the suggested. Especially for new-comers like I was some months ago. But of course, I might have missed something behind the scenes, so comments welcome (and I am sure they come).
Finally, all the irqdomain stuff is now plugged (and generated) into Documentation. So that everyone can walk through it at
https://www.kernel.org/doc/ (once applied, of course).
Jiri Slaby (SUSE) (18):
irqdomain.h: Remove extern from function declarations
irqdomain: Rename irq_set_default_host() to irq_set_default_domain()
irqdomain: Rename irq_get_default_host() to irq_get_default_domain() irqdomain.h: Stop using 'host' for domain
irqdomain: Drop of_node_to_fwnode()
irqdomain: Make a couple of functions an inline
irqdomain: Make irq_domain_instantiate() returned domains an
initializer
irqdomain: Make struct irq_domain_info variables const
irqdomain: Rename _add functions to _add_*_of_node
irqdomain: Rename _create functions to _add_*_fwnode
irqdomain: Rename _instantiate functions to _add
irqdomain: Switch away from irq_linear_revmap() and drop it irqdomain.h: Improve kernel-docs of functions
docs: irq/concepts: Add commas and reflow
docs: irq/concepts: Minor improvements
docs: irq-domain.rst: Simple improvements
docs: irqdomain: Update
irqdomain.c: Fix kernel-doc and add it to Documentation
Documentation/core-api/genericirq.rst | 2 - Documentation/core-api/irq/concepts.rst | 27 +- Documentation/core-api/irq/irq-domain.rst | 227 ++++++----- .../driver-api/driver-model/devres.rst | 2 +- .../zh_CN/core-api/irq/irq-domain.rst | 38 +- arch/arc/kernel/intc-arcv2.c | 4 +- arch/arc/kernel/intc-compact.c | 4 +- arch/arc/kernel/mcip.c | 2 +- arch/arm/common/sa1111.c | 2 +- arch/arm/mach-exynos/suspend.c | 2 +- arch/arm/mach-imx/avic.c | 2 +- arch/arm/mach-imx/gpc.c | 2 +- arch/arm/mach-imx/tzic.c | 2 +- arch/arm/mach-omap1/irq.c | 2 +- arch/arm/mach-omap2/omap-wakeupgen.c | 2 +- arch/arm/mach-pxa/irq.c | 4 +- arch/arm/plat-orion/gpio.c | 2 +- arch/arm64/kvm/arch_timer.c | 2 +- arch/mips/ath25/ar2315.c | 2 +- arch/mips/ath25/ar5312.c | 2 +- arch/mips/cavium-octeon/octeon-irq.c | 18 +- arch/mips/lantiq/irq.c | 2 +- arch/mips/pci/pci-ar2315.c | 2 +- arch/mips/pci/pci-rt3883.c | 2 +- arch/mips/pci/pci-xtalk-bridge.c | 4 +- arch/mips/ralink/irq.c | 2 +- arch/mips/sgi-ip27/ip27-irq.c | 4 +- arch/mips/sgi-ip30/ip30-irq.c | 4 +- arch/nios2/kernel/irq.c | 4 +- arch/powerpc/kvm/book3s_hv.c | 2 +- arch/powerpc/kvm/book3s_xive.c | 2 +- arch/powerpc/platforms/44x/uic.c | 6 +- .../powerpc/platforms/512x/mpc5121_ads_cpld.c | 2 +- arch/powerpc/platforms/52xx/media5200.c | 2 +- arch/powerpc/platforms/52xx/mpc52xx_gpt.c | 6 +- arch/powerpc/platforms/52xx/mpc52xx_pic.c | 6 +- .../platforms/85xx/socrates_fpga_pic.c | 4 +- arch/powerpc/platforms/8xx/cpm1-ic.c | 4 +- arch/powerpc/platforms/8xx/pic.c | 4 +- arch/powerpc/platforms/amigaone/setup.c | 2 +- arch/powerpc/platforms/cell/axon_msi.c | 2 +- arch/powerpc/platforms/cell/interrupt.c | 6 +- arch/powerpc/platforms/cell/spider-pic.c | 2 +- arch/powerpc/platforms/chrp/setup.c | 2 +- .../platforms/embedded6xx/flipper-pic.c | 6 +- arch/powerpc/platforms/embedded6xx/hlwd-pic.c | 4 +- arch/powerpc/platforms/pasemi/setup.c | 2 +- arch/powerpc/platforms/powermac/pic.c | 6 +- arch/powerpc/platforms/powermac/smp.c | 2 +- arch/powerpc/platforms/powernv/opal-irqchip.c | 2 +- arch/powerpc/platforms/powernv/pci-ioda.c | 6 +- arch/powerpc/platforms/ps3/interrupt.c | 4 +- arch/powerpc/platforms/pseries/msi.c | 6 +- arch/powerpc/sysdev/cpm2_pic.c | 4 +- arch/powerpc/sysdev/ehv_pic.c | 6 +- arch/powerpc/sysdev/fsl_msi.c | 2 +- arch/powerpc/sysdev/ge/ge_pic.c | 4 +- arch/powerpc/sysdev/i8259.c | 2 +- arch/powerpc/sysdev/ipic.c | 6 +- arch/powerpc/sysdev/mpic.c | 8 +- arch/powerpc/sysdev/tsi108_pci.c | 2 +- arch/powerpc/sysdev/xics/xics-common.c | 4 +- arch/powerpc/sysdev/xive/common.c | 6 +- arch/sh/boards/mach-se/7343/irq.c | 4 +- arch/sh/boards/mach-se/7722/irq.c | 4 +- arch/sh/boards/mach-x3proto/gpio.c | 2 +- arch/um/drivers/virt-pci.c | 2 +- arch/x86/kernel/apic/io_apic.c | 4 +- arch/x86/kernel/apic/vector.c | 4 +- arch/x86/platform/uv/uv_irq.c | 2 +- drivers/acpi/irq.c | 2 +- drivers/base/regmap/regmap-irq.c | 2 +- drivers/bus/moxtet.c | 2 +- drivers/cdx/cdx_msi.c | 4 +- drivers/edac/altera_edac.c | 2 +- drivers/gpio/gpio-bcm-kona.c | 2 +- drivers/gpio/gpio-brcmstb.c | 2 +- drivers/gpio/gpio-davinci.c | 2 +- drivers/gpio/gpio-em.c | 2 +- drivers/gpio/gpio-grgpio.c | 2 +- drivers/gpio/gpio-idt3243x.c | 2 +- drivers/gpio/gpio-lpc18xx.c | 2 +- drivers/gpio/gpio-mockup.c | 2 +- drivers/gpio/gpio-mpc8xxx.c | 2 +- drivers/gpio/gpio-mvebu.c | 2 +- drivers/gpio/gpio-mxc.c | 2 +- drivers/gpio/gpio-mxs.c | 2 +- drivers/gpio/gpio-pxa.c | 2 +- drivers/gpio/gpio-rockchip.c | 2 +- drivers/gpio/gpio-sa1100.c | 2 +- drivers/gpio/gpio-sim.c | 2 +- drivers/gpio/gpio-sodaville.c | 2 +- drivers/gpio/gpio-tb10x.c | 2 +- drivers/gpio/gpio-twl4030.c | 2 +- drivers/gpio/gpio-uniphier.c | 2 +- drivers/gpio/gpio-xgene-sb.c | 2 +- drivers/gpio/gpiolib.c | 4 +- drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c | 2 +- drivers/gpu/drm/msm/msm_mdss.c | 2 +- drivers/gpu/ipu-v3/ipu-common.c | 6 +- drivers/hid/hid-rmi.c | 2 +- drivers/i2c/busses/i2c-cht-wc.c | 2 +- drivers/i2c/i2c-core-base.c | 2 +- drivers/i2c/muxes/i2c-mux-pca954x.c | 4 +- drivers/iio/adc/stm32-adc-core.c | 2 +- drivers/iio/dummy/iio_dummy_evgen.c | 2 +- drivers/input/rmi4/rmi_driver.c | 2 +- drivers/iommu/amd/init.c | 2 +- drivers/iommu/amd/iommu.c | 2 +- drivers/iommu/hyperv-iommu.c | 2 +- drivers/iommu/intel/irq_remapping.c | 2 +- drivers/irqchip/exynos-combiner.c | 2 +- drivers/irqchip/irq-al-fic.c | 2 +- drivers/irqchip/irq-alpine-msi.c | 4 +- drivers/irqchip/irq-apple-aic.c | 4 +- drivers/irqchip/irq-armada-370-xp.c | 18 +- drivers/irqchip/irq-aspeed-i2c-ic.c | 2 +- drivers/irqchip/irq-aspeed-intc.c | 2 +- drivers/irqchip/irq-aspeed-scu-ic.c | 2 +- drivers/irqchip/irq-aspeed-vic.c | 2 +- drivers/irqchip/irq-ath79-misc.c | 4 +- drivers/irqchip/irq-atmel-aic-common.c | 2 +- drivers/irqchip/irq-bcm2835.c | 2 +- drivers/irqchip/irq-bcm2836.c | 4 +- drivers/irqchip/irq-bcm6345-l1.c | 2 +- drivers/irqchip/irq-bcm7038-l1.c | 2 +- drivers/irqchip/irq-bcm7120-l2.c | 2 +- drivers/irqchip/irq-brcmstb-l2.c | 2 +- drivers/irqchip/irq-clps711x.c | 4 +- drivers/irqchip/irq-crossbar.c | 2 +- drivers/irqchip/irq-csky-apb-intc.c | 2 +- drivers/irqchip/irq-csky-mpintc.c | 2 +- drivers/irqchip/irq-davinci-cp-intc.c | 2 +- drivers/irqchip/irq-digicolor.c | 2 +- drivers/irqchip/irq-dw-apb-ictl.c | 2 +- drivers/irqchip/irq-ftintc010.c | 2 +- drivers/irqchip/irq-gic-v2m.c | 2 +- drivers/irqchip/irq-gic-v3-its-fsl-mc-msi.c | 2 +- drivers/irqchip/irq-gic-v3-its.c | 2 +- drivers/irqchip/irq-gic-v3-mbi.c | 2 +- drivers/irqchip/irq-gic-v3.c | 6 +- drivers/irqchip/irq-gic-v4.c | 4 +- drivers/irqchip/irq-gic.c | 2 +- drivers/irqchip/irq-goldfish-pic.c | 2 +- drivers/irqchip/irq-hip04.c | 2 +- drivers/irqchip/irq-i8259.c | 2 +- drivers/irqchip/irq-idt3243x.c | 2 +- drivers/irqchip/irq-imgpdc.c | 2 +- drivers/irqchip/irq-imx-gpcv2.c | 4 +- drivers/irqchip/irq-imx-intmux.c | 2 +- drivers/irqchip/irq-imx-irqsteer.c | 2 +- drivers/irqchip/irq-imx-mu-msi.c | 2 +- drivers/irqchip/irq-ingenic-tcu.c | 2 +- drivers/irqchip/irq-ingenic.c | 2 +- drivers/irqchip/irq-ixp4xx.c | 4 +- drivers/irqchip/irq-jcore-aic.c | 2 +- drivers/irqchip/irq-keystone.c | 2 +- drivers/irqchip/irq-lan966x-oic.c | 4 +- drivers/irqchip/irq-loongarch-avec.c | 2 +- drivers/irqchip/irq-loongarch-cpu.c | 6 +- drivers/irqchip/irq-loongson-eiointc.c | 4 +- drivers/irqchip/irq-loongson-htvec.c | 4 +- drivers/irqchip/irq-loongson-liointc.c | 6 +- drivers/irqchip/irq-loongson-pch-lpc.c | 2 +- drivers/irqchip/irq-loongson-pch-msi.c | 4 +- drivers/irqchip/irq-loongson-pch-pic.c | 4 +- drivers/irqchip/irq-lpc32xx.c | 2 +- drivers/irqchip/irq-ls-extirq.c | 2 +- drivers/irqchip/irq-ls-scfg-msi.c | 4 +- drivers/irqchip/irq-ls1x.c | 2 +- drivers/irqchip/irq-mchp-eic.c | 2 +- drivers/irqchip/irq-meson-gpio.c | 4 +- drivers/irqchip/irq-mips-cpu.c | 4 +- drivers/irqchip/irq-mips-gic.c | 4 +- drivers/irqchip/irq-mmp.c | 4 +- drivers/irqchip/irq-mscc-ocelot.c | 2 +- drivers/irqchip/irq-mst-intc.c | 2 +- drivers/irqchip/irq-mtk-cirq.c | 2 +- drivers/irqchip/irq-mtk-sysirq.c | 2 +- drivers/irqchip/irq-mvebu-gicp.c | 4 +- drivers/irqchip/irq-mvebu-odmi.c | 4 +- drivers/irqchip/irq-mvebu-pic.c | 2 +- drivers/irqchip/irq-mvebu-sei.c | 10 +- drivers/irqchip/irq-mxs.c | 2 +- drivers/irqchip/irq-nvic.c | 2 +- drivers/irqchip/irq-omap-intc.c | 4 +- drivers/irqchip/irq-or1k-pic.c | 2 +- drivers/irqchip/irq-orion.c | 4 +- drivers/irqchip/irq-owl-sirq.c | 2 +- drivers/irqchip/irq-partition-percpu.c | 2 +- drivers/irqchip/irq-pic32-evic.c | 4 +- drivers/irqchip/irq-pruss-intc.c | 2 +- drivers/irqchip/irq-qcom-mpm.c | 4 +- drivers/irqchip/irq-rda-intc.c | 2 +- drivers/irqchip/irq-realtek-rtl.c | 2 +- drivers/irqchip/irq-renesas-intc-irqpin.c | 2 +- drivers/irqchip/irq-renesas-irqc.c | 2 +- drivers/irqchip/irq-renesas-rza1.c | 2 +- drivers/irqchip/irq-renesas-rzg2l.c | 2 +- drivers/irqchip/irq-renesas-rzv2h.c | 2 +- drivers/irqchip/irq-riscv-aplic-direct.c | 2 +- drivers/irqchip/irq-riscv-imsic-platform.c | 2 +- drivers/irqchip/irq-riscv-intc.c | 4 +- drivers/irqchip/irq-sa11x0.c | 2 +- drivers/irqchip/irq-sifive-plic.c | 2 +- drivers/irqchip/irq-sni-exiu.c | 4 +- drivers/irqchip/irq-sp7021-intc.c | 2 +- drivers/irqchip/irq-starfive-jh8100-intc.c | 2 +- drivers/irqchip/irq-stm32-exti.c | 2 +- drivers/irqchip/irq-stm32mp-exti.c | 4 +- drivers/irqchip/irq-sun4i.c | 2 +- drivers/irqchip/irq-sun6i-r.c | 2 +- drivers/irqchip/irq-sunxi-nmi.c | 2 +- drivers/irqchip/irq-tb10x.c | 2 +- drivers/irqchip/irq-tegra.c | 2 +- drivers/irqchip/irq-ti-sci-inta.c | 6 +- drivers/irqchip/irq-ti-sci-intr.c | 4 +- drivers/irqchip/irq-ts4800.c | 2 +- drivers/irqchip/irq-uniphier-aidet.c | 4 +- drivers/irqchip/irq-versatile-fpga.c | 2 +- drivers/irqchip/irq-vf610-mscm-ir.c | 2 +- drivers/irqchip/irq-vic.c | 2 +- drivers/irqchip/irq-vt8500.c | 2 +- drivers/irqchip/irq-wpcm450-aic.c | 2 +- drivers/irqchip/irq-xilinx-intc.c | 4 +- drivers/irqchip/irq-xtensa-mx.c | 6 +- drivers/irqchip/irq-xtensa-pic.c | 8 +- drivers/irqchip/irq-zevio.c | 2 +- drivers/irqchip/qcom-irq-combiner.c | 4 +- drivers/irqchip/qcom-pdc.c | 2 +- drivers/irqchip/spear-shirq.c | 2 +- drivers/mailbox/qcom-ipcc.c | 2 +- drivers/memory/omap-gpmc.c | 2 +- drivers/mfd/88pm860x-core.c | 2 +- drivers/mfd/ab8500-core.c | 2 +- drivers/mfd/arizona-irq.c | 2 +- drivers/mfd/db8500-prcmu.c | 2 +- drivers/mfd/fsl-imx25-tsadc.c | 2 +- drivers/mfd/ioc3.c | 2 +- drivers/mfd/lp8788-irq.c | 2 +- drivers/mfd/max8925-core.c | 2 +- drivers/mfd/max8997-irq.c | 2 +- drivers/mfd/max8998-irq.c | 2 +- drivers/mfd/mt6358-irq.c | 2 +- drivers/mfd/mt6397-irq.c | 2 +- drivers/mfd/qcom-pm8xxx.c | 2 +- drivers/mfd/stmfx.c | 2 +- drivers/mfd/stmpe.c | 2 +- drivers/mfd/tc3589x.c | 2 +- drivers/mfd/tps65217.c | 2 +- drivers/mfd/tps6586x.c | 2 +- drivers/mfd/twl4030-irq.c | 2 +- drivers/mfd/twl6030-irq.c | 2 +- drivers/mfd/wm831x-irq.c | 4 +- drivers/mfd/wm8994-irq.c | 2 +- drivers/misc/hi6421v600-irq.c | 2 +- drivers/misc/lan966x_pci.c | 2 +- drivers/net/dsa/microchip/ksz_common.c | 2 +- drivers/net/dsa/microchip/ksz_ptp.c | 2 +- drivers/net/dsa/mt7530.c | 4 +- drivers/net/dsa/mv88e6xxx/chip.c | 2 +- drivers/net/dsa/mv88e6xxx/global2.c | 2 +- drivers/net/dsa/qca/ar9331.c | 2 +- drivers/net/dsa/realtek/rtl8365mb.c | 2 +- drivers/net/dsa/realtek/rtl8366rb.c | 2 +- .../net/ethernet/wangxun/txgbe/txgbe_irq.c | 2 +- drivers/net/usb/lan78xx.c | 2 +- drivers/net/usb/smsc95xx.c | 2 +- drivers/pci/controller/dwc/pci-dra7xx.c | 2 +- drivers/pci/controller/dwc/pci-keystone.c | 2 +- .../pci/controller/dwc/pcie-designware-host.c | 4 +- drivers/pci/controller/dwc/pcie-dw-rockchip.c | 2 +- drivers/pci/controller/dwc/pcie-uniphier.c | 2 +- .../controller/mobiveil/pcie-mobiveil-host.c | 6 +- drivers/pci/controller/pci-aardvark.c | 6 +- drivers/pci/controller/pci-ftpci100.c | 2 +- drivers/pci/controller/pci-mvebu.c | 2 +- drivers/pci/controller/pci-tegra.c | 2 +- drivers/pci/controller/pci-xgene-msi.c | 4 +- drivers/pci/controller/pcie-altera-msi.c | 4 +- drivers/pci/controller/pcie-altera.c | 2 +- drivers/pci/controller/pcie-apple.c | 4 +- drivers/pci/controller/pcie-brcmstb.c | 4 +- drivers/pci/controller/pcie-iproc-msi.c | 4 +- drivers/pci/controller/pcie-mediatek-gen3.c | 4 +- drivers/pci/controller/pcie-mediatek.c | 6 +- drivers/pci/controller/pcie-rcar-host.c | 2 +- drivers/pci/controller/pcie-rockchip-host.c | 2 +- drivers/pci/controller/pcie-xilinx-cpm.c | 4 +- drivers/pci/controller/pcie-xilinx-dma-pl.c | 8 +- drivers/pci/controller/pcie-xilinx-nwl.c | 6 +- drivers/pci/controller/pcie-xilinx.c | 4 +- drivers/pci/controller/plda/pcie-plda-host.c | 8 +- drivers/pinctrl/mediatek/mtk-eint.c | 2 +- drivers/pinctrl/pinctrl-at91-pio4.c | 2 +- drivers/pinctrl/pinctrl-keembay.c | 2 +- drivers/pinctrl/pinctrl-single.c | 4 +- drivers/pinctrl/samsung/pinctrl-exynos.c | 4 +- drivers/pinctrl/samsung/pinctrl-s3c64xx.c | 4 +- drivers/pinctrl/stm32/pinctrl-stm32.c | 2 +- drivers/pinctrl/sunxi/pinctrl-sunxi.c | 2 +- drivers/platform/x86/asus-tf103c-dock.c | 2 +- .../platform/x86/intel/crystal_cove_charger.c | 2 +- drivers/remoteproc/pru_rproc.c | 2 +- drivers/sh/intc/irqdomain.c | 4 +- drivers/soc/dove/pmu.c | 2 +- drivers/soc/fsl/qe/qe_ic.c | 6 +- drivers/soc/qcom/smp2p.c | 2 +- drivers/soc/qcom/smsm.c | 2 +- drivers/soc/tegra/pmc.c | 2 +- drivers/soundwire/irq.c | 2 +- drivers/spmi/spmi-pmic-arb.c | 2 +- drivers/ssb/driver_gpio.c | 4 +- drivers/thermal/qcom/lmh.c | 2 +- drivers/thermal/tegra/soctherm.c | 2 +- include/linux/gpio/driver.h | 2 +- include/linux/irq_sim.h | 8 +- include/linux/irqdomain.h | 362 +++++++++++------- kernel/irq/devres.c | 8 +- kernel/irq/ipi-mux.c | 2 +- kernel/irq/irq_sim.c | 28 +- kernel/irq/irqdomain.c | 114 ++---- kernel/irq/msi.c | 2 +- sound/soc/codecs/rt5677.c | 2 +- sound/soc/codecs/wcd937x.c | 2 +- sound/soc/codecs/wcd938x.c | 2 +- sound/soc/codecs/wcd939x.c | 2 +- 327 files changed, 896 insertions(+), 844 deletions(-)
Signature · 1 line
2.48.0
PATCH 1/18 irqdomain.h: Remove extern from function declarations
'extern' is not needed for function declarations. So remove it from irqdomain.h. Note that the declarations are now unified as some had 'extern' (all these) and some did not (like msi_device_domain_alloc_wired()).
An upside of this change is that parameters are shifted a bit to the left, so the whole code is now more readable.
--- include/linux/irqdomain.h | 140 +++++++++++++++++++------------------- 1 file changed, 71 insertions(+), 69 deletions(-)
include/linux/irqdomain.h +71 -69
@@ -350,13 +350,13 @@ struct irq_domain *irq_domain_create_legacy(struct fwnode_handle *fwnode,irq_hw_number_t first_hwirq, const struct irq_domain_ops *ops, void *host_data); -extern struct irq_domain *irq_find_matching_fwspec (struct irq_fwspec *fwspec, -enum irq_domain_bus_token bus_token); -extern void irq_set_default_host (struct irq_domain *host); -extern struct irq_domain *irq_get_default_host (void ); -extern int irq_domain_alloc_descs (int virq,unsigned int nr_irqs, -irq_hw_number_t hwirq,int node, -const struct irq_affinity_desc *affinity); +struct irq_domain *irq_find_matching_fwspec (struct irq_fwspec *fwspec, +enum irq_domain_bus_token bus_token); +void irq_set_default_host (struct irq_domain *host); +struct irq_domain *irq_get_default_host (void ); +int irq_domain_alloc_descs (int virq,unsigned int nr_irqs, +irq_hw_number_t hwirq,int node, +const struct irq_affinity_desc *affinity);static inline struct fwnode_handle *of_node_to_fwnode (struct device_node *node) {
@@ -370,8 +370,8 @@ static inline bool is_fwnode_irqchip(const struct fwnode_handle *fwnode)return fwnode && fwnode->ops == &irqchip_fwnode_ops; } -extern void irq_domain_update_bus_token (struct irq_domain *domain, -enum irq_domain_bus_token bus_token); +void irq_domain_update_bus_token (struct irq_domain *domain, +enum irq_domain_bus_token bus_token);static inline struct irq_domain *irq_find_matching_fwnode(struct fwnode_handle *fwnode,
@@ -454,7 +454,7 @@ static inline struct irq_domain *irq_domain_add_nomap(struct device_node *of_nodreturn IS_ERR (d) ?NULL : d; } -extern unsigned int irq_create_direct_mapping (struct irq_domain *host); +unsigned int irq_create_direct_mapping (struct irq_domain *host);#endif static inline struct irq_domain *irq_domain_add_tree(struct device_node *of_node,
@@ -507,19 +507,19 @@ static inline struct irq_domain *irq_domain_create_tree(struct fwnode_handle *fwreturn IS_ERR (d) ?NULL : d; } -extern void irq_domain_remove (struct irq_domain *host); +void irq_domain_remove (struct irq_domain *host); -extern int irq_domain_associate (struct irq_domain *domain,unsigned int irq, -irq_hw_number_t hwirq); -extern void irq_domain_associate_many (struct irq_domain *domain, -unsigned int irq_base, -irq_hw_number_t hwirq_base,int count); +int irq_domain_associate (struct irq_domain *domain,unsigned int irq, +irq_hw_number_t hwirq); +void irq_domain_associate_many (struct irq_domain *domain, +unsigned int irq_base, +irq_hw_number_t hwirq_base,int count); -extern unsigned int irq_create_mapping_affinity (struct irq_domain *host, -irq_hw_number_t hwirq, -const struct irq_affinity_desc *affinity); -extern unsigned int irq_create_fwspec_mapping (struct irq_fwspec *fwspec); -extern void irq_dispose_mapping (unsigned int virq); +unsigned int irq_create_mapping_affinity (struct irq_domain *host, +irq_hw_number_t hwirq, +const struct irq_affinity_desc *affinity); +unsigned int irq_create_fwspec_mapping (struct irq_fwspec *fwspec); +void irq_dispose_mapping (unsigned int virq);static inline unsigned int irq_create_mapping (struct irq_domain *host,irq_hw_number_t hwirq)
@@ -527,9 +527,9 @@ static inline unsigned int irq_create_mapping(struct irq_domain *host,return irq_create_mapping_affinity (host, hwirq,NULL ); } -extern struct irq_desc *__irq_resolve_mapping (struct irq_domain *domain, -irq_hw_number_t hwirq, -unsigned int *irq); +struct irq_desc *__irq_resolve_mapping (struct irq_domain *domain, +irq_hw_number_t hwirq, +unsigned int *irq);static inline struct irq_desc *irq_resolve_mapping (struct irq_domain *domain,irq_hw_number_t hwirq)
@@ -587,19 +587,21 @@ int irq_reserve_ipi(struct irq_domain *domain, const struct cpumask *dest);int irq_destroy_ipi (unsigned int irq,const struct cpumask *dest);/* V2 interfaces to support hierarchy IRQ domains. */ -extern struct irq_data *irq_domain_get_irq_data (struct irq_domain *domain, -unsigned int virq); -extern void irq_domain_set_info (struct irq_domain *domain,unsigned int virq, -irq_hw_number_t hwirq, -const struct irq_chip *chip, -void *chip_data,irq_flow_handler_t handler, -void *handler_data,const char *handler_name); -extern void irq_domain_reset_irq_data (struct irq_data *irq_data); +struct irq_data *irq_domain_get_irq_data (struct irq_domain *domain, +unsigned int virq); +void irq_domain_set_info (struct irq_domain *domain,unsigned int virq, +irq_hw_number_t hwirq, +const struct irq_chip *chip, +void *chip_data,irq_flow_handler_t handler, +void *handler_data,const char *handler_name); +void irq_domain_reset_irq_data (struct irq_data *irq_data);#ifdef CONFIG_IRQ_DOMAIN_HIERARCHY -extern struct irq_domain *irq_domain_create_hierarchy (struct irq_domain *parent, -unsigned int flags,unsigned int size, -struct fwnode_handle *fwnode, -const struct irq_domain_ops *ops,void *host_data); +struct irq_domain *irq_domain_create_hierarchy (struct irq_domain *parent, +unsigned int flags, +unsigned int size, +struct fwnode_handle *fwnode, +const struct irq_domain_ops *ops, +void *host_data); static inline struct irq_domain *irq_domain_add_hierarchy(struct irq_domain *parent, unsigned int flags,
@@ -613,13 +615,13 @@ static inline struct irq_domain *irq_domain_add_hierarchy(struct irq_domain *par ops, host_data); } -extern int __irq_domain_alloc_irqs (struct irq_domain *domain,int irq_base, -unsigned int nr_irqs,int node,void *arg, -bool realloc, -const struct irq_affinity_desc *affinity); -extern void irq_domain_free_irqs (unsigned int virq,unsigned int nr_irqs); -extern int irq_domain_activate_irq (struct irq_data *irq_data,bool early); -extern void irq_domain_deactivate_irq (struct irq_data *irq_data); +int __irq_domain_alloc_irqs (struct irq_domain *domain,int irq_base, +unsigned int nr_irqs,int node,void *arg, +bool realloc, +const struct irq_affinity_desc *affinity); +void irq_domain_free_irqs (unsigned int virq,unsigned int nr_irqs); +int irq_domain_activate_irq (struct irq_data *irq_data,bool early); +void irq_domain_deactivate_irq (struct irq_data *irq_data);static inline int irq_domain_alloc_irqs (struct irq_domain *domain,unsigned int nr_irqs,int node,void *arg)
@@ -628,32 +630,32 @@ static inline int irq_domain_alloc_irqs(struct irq_domain *domain, NULL); } -extern int irq_domain_alloc_irqs_hierarchy (struct irq_domain *domain, -unsigned int irq_base, -unsigned int nr_irqs,void *arg); -extern int irq_domain_set_hwirq_and_chip (struct irq_domain *domain, -unsigned int virq, -irq_hw_number_t hwirq, -const struct irq_chip *chip, -void *chip_data); -extern void irq_domain_free_irqs_common (struct irq_domain *domain, -unsigned int virq, -unsigned int nr_irqs); -extern void irq_domain_free_irqs_top (struct irq_domain *domain, -unsigned int virq,unsigned int nr_irqs); - -extern int irq_domain_push_irq (struct irq_domain *domain,int virq,void *arg); -extern int irq_domain_pop_irq (struct irq_domain *domain,int virq); - -extern int irq_domain_alloc_irqs_parent (struct irq_domain *domain, -unsigned int irq_base, -unsigned int nr_irqs,void *arg); - -extern void irq_domain_free_irqs_parent (struct irq_domain *domain, -unsigned int irq_base, -unsigned int nr_irqs); - -extern int irq_domain_disconnect_hierarchy (struct irq_domain *domain, +int irq_domain_alloc_irqs_hierarchy (struct irq_domain *domain, +unsigned int irq_base, +unsigned int nr_irqs,void *arg); +int irq_domain_set_hwirq_and_chip (struct irq_domain *domain, +unsigned int virq, +irq_hw_number_t hwirq, +const struct irq_chip *chip, +void *chip_data); +void irq_domain_free_irqs_common (struct irq_domain *domain, +unsigned int virq, +unsigned int nr_irqs); +void irq_domain_free_irqs_top (struct irq_domain *domain, +unsigned int virq,unsigned int nr_irqs); + +int irq_domain_push_irq (struct irq_domain *domain,int virq,void *arg); +int irq_domain_pop_irq (struct irq_domain *domain,int virq); + +int irq_domain_alloc_irqs_parent (struct irq_domain *domain, +unsigned int irq_base, +unsigned int nr_irqs,void *arg); + +void irq_domain_free_irqs_parent (struct irq_domain *domain, +unsigned int irq_base, +unsigned int nr_irqs); + +int irq_domain_disconnect_hierarchy (struct irq_domain *domain,unsigned int virq);static inline bool irq_domain_is_hierarchy (struct irq_domain *domain)
Signature · 1 line
2.48.0
PATCH 2/18 irqdomain: Rename irq_set_default_host() to irq_set_default_domain()
In reply to Jiri Slaby (SUSE)Call the irq_domain consistently a domain, not host. Here, rename irq_set_default_host() to irq_set_default_domain().
--- arch/arc/kernel/intc-arcv2.c | 2 +- arch/arc/kernel/intc-compact.c | 2 +- arch/arm/mach-pxa/irq.c | 2 +- arch/mips/cavium-octeon/octeon-irq.c | 6 +++--- arch/mips/sgi-ip27/ip27-irq.c | 2 +- arch/mips/sgi-ip30/ip30-irq.c | 2 +- arch/nios2/kernel/irq.c | 2 +- arch/powerpc/platforms/44x/uic.c | 2 +- arch/powerpc/platforms/52xx/mpc52xx_pic.c | 2 +- arch/powerpc/platforms/amigaone/setup.c | 2 +- arch/powerpc/platforms/cell/interrupt.c | 2 +- arch/powerpc/platforms/chrp/setup.c | 2 +- arch/powerpc/platforms/embedded6xx/flipper-pic.c | 2 +- arch/powerpc/platforms/pasemi/setup.c | 2 +- arch/powerpc/platforms/powermac/pic.c | 2 +- arch/powerpc/platforms/ps3/interrupt.c | 2 +- arch/powerpc/sysdev/ehv_pic.c | 2 +- arch/powerpc/sysdev/ipic.c | 2 +- arch/powerpc/sysdev/mpic.c | 2 +- arch/powerpc/sysdev/xics/xics-common.c | 2 +- arch/powerpc/sysdev/xive/common.c | 2 +- arch/x86/kernel/apic/vector.c | 2 +- drivers/irqchip/irq-armada-370-xp.c | 2 +- drivers/irqchip/irq-clps711x.c | 2 +- drivers/irqchip/irq-imx-gpcv2.c | 2 +- drivers/irqchip/irq-pic32-evic.c | 2 +- drivers/irqchip/irq-xilinx-intc.c | 2 +- drivers/irqchip/irq-xtensa-mx.c | 2 +- drivers/irqchip/irq-xtensa-pic.c | 4 ++-- include/linux/irqdomain.h | 2 +- kernel/irq/irqdomain.c | 8 ++++---- 31 files changed, 37 insertions(+), 37 deletions(-)
arch/arc/kernel/intc-arcv2.c +1 -1
@@ -178,7 +178,7 @@ init_onchip_IRQ(struct device_node *intc, struct device_node *parent)* Needed for primary domain lookup to succeed * This is a primary irqchip, and can never have a parent */ -irq_set_default_host (root_domain); +irq_set_default_domain (root_domain);#ifdef CONFIG_SMP irq_create_mapping (root_domain,IPI_IRQ );
arch/arc/kernel/intc-compact.c +1 -1
@@ -121,7 +121,7 @@ init_onchip_IRQ(struct device_node *intc, struct device_node *parent)* Needed for primary domain lookup to succeed * This is a primary irqchip, and can never have a parent */ -irq_set_default_host (root_domain); +irq_set_default_domain (root_domain);return 0 ; }
arch/arm/mach-pxa/irq.c +1 -1
@@ -152,7 +152,7 @@ pxa_init_irq_common(struct device_node *node, int irq_nr, &pxa_irq_ops, NULL);if (!pxa_irq_domain)panic ("Unable to add PXA IRQ domain\n" ); -irq_set_default_host (pxa_irq_domain); +irq_set_default_domain (pxa_irq_domain);for (n =0 ; n < irq_nr; n +=32 ) {void __iomem *base =irq_base (n >>5 );
arch/mips/cavium-octeon/octeon-irq.c +3 -3
@@ -1505,7 +1505,7 @@ static int __init octeon_irq_init_ciu( ciu_domain =irq_domain_add_tree ( ciu_node, &octeon_irq_domain_ciu_ops, dd); -irq_set_default_host (ciu_domain); +irq_set_default_domain (ciu_domain);/* CIU_0 */ for (i =0 ; i <16 ; i++) {
@@ -2076,7 +2076,7 @@ static int __init octeon_irq_init_ciu2( ciu_domain =irq_domain_add_tree ( ciu_node, &octeon_irq_domain_ciu2_ops,NULL ); -irq_set_default_host (ciu_domain); +irq_set_default_domain (ciu_domain);/* CUI2 */ for (i =0 ; i <64 ; i++) {
@@ -2929,7 +2929,7 @@ static int __init octeon_irq_init_ciu3(struct device_node *ciu_node,/* Only do per CPU things if it is the CIU of the boot node. */ octeon_irq_ciu3_alloc_resources (ciu3_info);if (node ==0 ) -irq_set_default_host (domain); +irq_set_default_domain (domain); octeon_irq_use_ip4 = false;/* Enable the CIU lines */
arch/mips/sgi-ip27/ip27-irq.c +1 -1
@@ -297,7 +297,7 @@ void __init arch_init_irq(void)if (WARN_ON (domain ==NULL ))return ; -irq_set_default_host (domain); +irq_set_default_domain (domain);irq_set_percpu_devid (IP27_HUB_PEND0_IRQ ); irq_set_chained_handler_and_data(IP27_HUB_PEND0_IRQ, ip27_do_irq_mask0,
arch/mips/sgi-ip30/ip30-irq.c +1 -1
@@ -313,7 +313,7 @@ void __init arch_init_irq(void)if (!domain)return ; -irq_set_default_host (domain); +irq_set_default_domain (domain);irq_set_percpu_devid (IP30_HEART_L0_IRQ ); irq_set_chained_handler_and_data(IP30_HEART_L0_IRQ, ip30_normal_irq,
arch/nios2/kernel/irq.c +1 -1
@@ -72,7 +72,7 @@ void __init init_IRQ(void) domain =irq_domain_add_linear (node,NIOS2_CPU_NR_IRQS , &irq_ops,NULL );BUG_ON (!domain); -irq_set_default_host (domain); +irq_set_default_domain (domain);of_node_put (node);/* Load the initial ienable value */ ienable =RDCTL (CTL_IENABLE );
arch/powerpc/platforms/44x/uic.c +1 -1
@@ -291,7 +291,7 @@ void __init uic_init_tree(void)if (!primary_uic)panic ("Unable to initialize primary UIC %pOF\n" , np); -irq_set_default_host (primary_uic->irqhost); +irq_set_default_domain (primary_uic->irqhost);of_node_put (np);/* The scan again for cascaded UICs */
arch/powerpc/platforms/52xx/mpc52xx_pic.c +1 -1
@@ -453,7 +453,7 @@ void __init mpc52xx_init_irq(void)if (!mpc52xx_irqhost)panic (__FILE__": Cannot allocate the IRQ host\n" ); -irq_set_default_host (mpc52xx_irqhost); +irq_set_default_domain (mpc52xx_irqhost);pr_info ("MPC52xx PIC is up and running!\n" ); }
arch/powerpc/platforms/amigaone/setup.c +1 -1
@@ -109,7 +109,7 @@ static void __init amigaone_init_IRQ(void)i8259_init (pic, int_ack); ppc_md.get_irq = i8259_irq; -irq_set_default_host (i8259_get_host ()); +irq_set_default_domain (i8259_get_host ()); }static int __init request_isa_regions (void )
arch/powerpc/platforms/cell/interrupt.c +1 -1
@@ -360,7 +360,7 @@ void __init iic_init_IRQ(void) iic_host =irq_domain_add_linear (NULL ,IIC_SOURCE_COUNT , &iic_host_ops,NULL );BUG_ON (iic_host ==NULL ); -irq_set_default_host (iic_host); +irq_set_default_domain (iic_host);/* Discover and initialize iics */ if (setup_iic () <0 )
arch/powerpc/platforms/chrp/setup.c +1 -1
@@ -486,7 +486,7 @@ static void __init chrp_find_8259(void)i8259_init (pic, chrp_int_ack);if (ppc_md.get_irq ==NULL ) { ppc_md.get_irq = i8259_irq; -irq_set_default_host (i8259_get_host ()); +irq_set_default_domain (i8259_get_host ()); }if (chrp_mpic !=NULL ) { cascade_irq =irq_of_parse_and_map (pic,0 );
arch/powerpc/platforms/embedded6xx/flipper-pic.c +1 -1
@@ -190,7 +190,7 @@ void __init flipper_pic_probe(void) flipper_irq_host =flipper_pic_init (np);BUG_ON (!flipper_irq_host); -irq_set_default_host (flipper_irq_host); +irq_set_default_domain (flipper_irq_host);of_node_put (np); }
arch/powerpc/platforms/pasemi/setup.c +1 -1
@@ -228,7 +228,7 @@ static void __init nemo_init_IRQ(struct mpic *mpic)irq_set_chained_handler (gpio_virq, sb600_8259_cascade);mpic_unmask_irq (irq_get_irq_data (gpio_virq)); - irq_set_default_host(mpic->irqhost); + irq_set_default_domain(mpic->irqhost); }#else
arch/powerpc/platforms/powermac/pic.c +1 -1
@@ -330,7 +330,7 @@ static void __init pmac_pic_probe_oldstyle(void) pmac_pic_host =irq_domain_add_linear (master, max_irqs, &pmac_pic_host_ops,NULL );BUG_ON (pmac_pic_host ==NULL ); -irq_set_default_host (pmac_pic_host); +irq_set_default_domain (pmac_pic_host);/* Get addresses of first controller if we have a node for it */ BUG_ON (of_address_to_resource (master,0 , &r));
arch/powerpc/platforms/ps3/interrupt.c +1 -1
@@ -744,7 +744,7 @@ void __init ps3_init_IRQ(void)struct irq_domain *host; host =irq_domain_add_nomap (NULL ,PS3_PLUG_MAX +1 , &ps3_host_ops,NULL ); -irq_set_default_host (host); +irq_set_default_domain (host);for_each_possible_cpu (cpu) {struct ps3_private *pd = &per_cpu (ps3_private, cpu);
arch/powerpc/sysdev/ehv_pic.c +1 -1
@@ -291,5 +291,5 @@ void __init ehv_pic_init(void) ehv_pic->coreint_flag =of_property_read_bool (np,"has-external-proxy" ); global_ehv_pic = ehv_pic; -irq_set_default_host (global_ehv_pic->irqhost); +irq_set_default_domain (global_ehv_pic->irqhost); }
arch/powerpc/sysdev/ipic.c +1 -1
@@ -757,7 +757,7 @@ struct ipic * __init ipic_init(struct device_node *node, unsigned int flags)ipic_write (ipic->regs,IPIC_SEMSR , temp); primary_ipic = ipic; -irq_set_default_host (primary_ipic->irqhost); +irq_set_default_domain (primary_ipic->irqhost);ipic_write (ipic->regs,IPIC_SIMSR_H ,0 );ipic_write (ipic->regs,IPIC_SIMSR_L ,0 );
arch/powerpc/sysdev/mpic.c +1 -1
@@ -1520,7 +1520,7 @@ struct mpic * __init mpic_alloc(struct device_node *node,if (!(mpic->flags &MPIC_SECONDARY )) { mpic_primary = mpic; -irq_set_default_host (mpic->irqhost); +irq_set_default_domain (mpic->irqhost); }return mpic;
arch/powerpc/sysdev/xics/xics-common.c +1 -1
@@ -472,7 +472,7 @@ static int __init xics_allocate_domain(void)return -ENOMEM ; } -irq_set_default_host (xics_host); +irq_set_default_domain (xics_host);return 0 ; }
arch/powerpc/sysdev/xive/common.c +1 -1
@@ -1467,7 +1467,7 @@ static void __init xive_init_host(struct device_node *np) xive_irq_domain =irq_domain_add_tree (np, &xive_irq_domain_ops,NULL );if (WARN_ON (xive_irq_domain ==NULL ))return ; -irq_set_default_host (xive_irq_domain); +irq_set_default_domain (xive_irq_domain); }static void xive_cleanup_cpu_queues (unsigned int cpu,struct xive_cpu *xc)
arch/x86/kernel/apic/vector.c +1 -1
@@ -799,7 +799,7 @@ int __init arch_early_irq_init(void) x86_vector_domain =irq_domain_create_tree (fn, &x86_vector_domain_ops,NULL );BUG_ON (x86_vector_domain ==NULL ); -irq_set_default_host (x86_vector_domain); +irq_set_default_domain (x86_vector_domain);BUG_ON (!alloc_cpumask_var (&vector_searchmask,GFP_KERNEL ));
drivers/irqchip/irq-armada-370-xp.c +1 -1
@@ -880,7 +880,7 @@ static int __init mpic_of_init(struct device_node *node, struct device_node *par }if (mpic_is_ipi_available (mpic)) { -irq_set_default_host (mpic->domain); +irq_set_default_domain (mpic->domain);set_handle_irq (mpic_handle_irq);#ifdef CONFIG_SMP err =mpic_ipi_init (mpic, node);
drivers/irqchip/irq-clps711x.c +1 -1
@@ -191,7 +191,7 @@ static int __init _clps711x_intc_init(struct device_node *np, goto out_irqfree; } -irq_set_default_host (clps711x_intc->domain); +irq_set_default_domain (clps711x_intc->domain);set_handle_irq (clps711x_irqh);#ifdef CONFIG_FIQ
drivers/irqchip/irq-imx-gpcv2.c +1 -1
@@ -247,7 +247,7 @@ static int __init imx_gpcv2_irqchip_init(struct device_node *node,kfree (cd);return -ENOMEM ; } -irq_set_default_host (domain); +irq_set_default_domain (domain);/* Initially mask all interrupts */ for (i =0 ; i <IMR_NUM ; i++) {
drivers/irqchip/irq-pic32-evic.c +1 -1
@@ -291,7 +291,7 @@ static int __init pic32_of_init(struct device_node *node, gc->private = &priv[i]; } -irq_set_default_host (evic_irq_domain); +irq_set_default_domain (evic_irq_domain);/* * External interrupts have software configurable edge polarity. These
drivers/irqchip/irq-xilinx-intc.c +1 -1
@@ -233,7 +233,7 @@ static int __init xilinx_intc_of_init(struct device_node *intc, } }else { primary_intc = irqc; -irq_set_default_host (primary_intc->root_domain); +irq_set_default_domain (primary_intc->root_domain);set_handle_irq (xil_intc_handle_irq); }
drivers/irqchip/irq-xtensa-mx.c +1 -1
@@ -156,7 +156,7 @@ static void __init xtensa_mx_init_common(struct irq_domain *root_domain) {unsigned int i; -irq_set_default_host (root_domain); +irq_set_default_domain (root_domain);secondary_init_irq ();/* Initialize default IRQ routing to CPU 0 */
drivers/irqchip/irq-xtensa-pic.c +2 -2
@@ -87,7 +87,7 @@ int __init xtensa_pic_init_legacy(struct device_node *interrupt_parent)struct irq_domain *root_domain =irq_domain_add_legacy (NULL ,NR_IRQS -1 ,1 ,0 , &xtensa_irq_domain_ops, &xtensa_irq_chip); -irq_set_default_host (root_domain); +irq_set_default_domain (root_domain);return 0 ; }
@@ -97,7 +97,7 @@ static int __init xtensa_pic_init(struct device_node *np,struct irq_domain *root_domain =irq_domain_add_linear (np,NR_IRQS , &xtensa_irq_domain_ops, &xtensa_irq_chip); -irq_set_default_host (root_domain); +irq_set_default_domain (root_domain);return 0 ; }IRQCHIP_DECLARE (xtensa_irq_chip,"cdns,xtensa-pic" , xtensa_pic_init);
include/linux/irqdomain.h +1 -1
@@ -352,7 +352,7 @@ struct irq_domain *irq_domain_create_legacy(struct fwnode_handle *fwnode, void *host_data);struct irq_domain *irq_find_matching_fwspec (struct irq_fwspec *fwspec,enum irq_domain_bus_token bus_token); -void irq_set_default_host (struct irq_domain *host); +void irq_set_default_domain (struct irq_domain *domain);struct irq_domain *irq_get_default_host (void ); int irq_domain_alloc_descs(int virq, unsigned int nr_irqs, irq_hw_number_t hwirq, int node,
kernel/irq/irqdomain.c +4 -4
@@ -398,7 +398,7 @@ void irq_domain_remove(struct irq_domain *domain)* If the going away domain is the default one, reset it. */ if (unlikely (irq_default_domain == domain)) -irq_set_default_host (NULL ); +irq_set_default_domain (NULL );mutex_unlock (&irq_domain_mutex);
@@ -573,7 +573,7 @@ struct irq_domain *irq_find_matching_fwspec(struct irq_fwspec *fwspec,EXPORT_SYMBOL_GPL (irq_find_matching_fwspec);/** -* irq_set_default_host() - Set a "default" irq domain +* irq_set_default_domain() - Set a "default" irq domain * @domain: default domain pointer * * For convenience, it's possible to set a "default" domain that will be used
@@ -581,13 +581,13 @@ EXPORT_SYMBOL_GPL(irq_find_matching_fwspec);* platforms that want to manipulate a few hard coded interrupt numbers that * aren't properly represented in the device-tree. */ -void irq_set_default_host (struct irq_domain *domain) +void irq_set_default_domain (struct irq_domain *domain) {pr_debug ("Default domain set to @0x%p\n" , domain); irq_default_domain = domain; } -EXPORT_SYMBOL_GPL (irq_set_default_host); +EXPORT_SYMBOL_GPL (irq_set_default_domain);/** * irq_get_default_host() - Retrieve the "default" irq domain
Signature · 1 line
2.48.0
PATCH 3/18 irqdomain: Rename irq_get_default_host() to irq_get_default_domain()
In reply to Jiri Slaby (SUSE)Call the irq_domain consistently a domain, not host. Here, rename irq_get_default_host() to irq_get_default_domain().
--- arch/mips/pci/pci-xtalk-bridge.c | 2 +- arch/powerpc/kvm/book3s_hv.c | 2 +- arch/powerpc/kvm/book3s_xive.c | 2 +- arch/powerpc/platforms/powernv/pci-ioda.c | 2 +- arch/powerpc/platforms/pseries/msi.c | 2 +- drivers/irqchip/irq-armada-370-xp.c | 4 ++-- include/linux/irqdomain.h | 2 +- kernel/irq/irqdomain.c | 6 +++--- 8 files changed, 11 insertions(+), 11 deletions(-)
arch/mips/pci/pci-xtalk-bridge.c +1 -1
@@ -620,7 +620,7 @@ static int bridge_probe(struct platform_device *pdev)if (bridge_get_partnum (virt_to_phys ((void *)bd->bridge_addr), partnum))return -EPROBE_DEFER ;/* not available yet */ - parent =irq_get_default_host (); + parent =irq_get_default_domain ();if (!parent)return -ENODEV ; fn =irq_domain_alloc_named_fwnode ("BRIDGE" );
arch/powerpc/kvm/book3s_hv.c +1 -1
@@ -6041,7 +6041,7 @@ static int kvmppc_set_passthru_irq(struct kvm *kvm, int host_irq, int guest_gsi)* the underlying calls, which will EOI the interrupt in real * mode, need an HW IRQ number mapped in the XICS IRQ domain. */ - host_data =irq_domain_get_irq_data (irq_get_default_host (), host_irq); + host_data =irq_domain_get_irq_data (irq_get_default_domain (), host_irq); irq_map->r_hwirq = (unsigned int )irqd_to_hwirq (host_data);if (i == pimap->n_mapped)
arch/powerpc/kvm/book3s_xive.c +1 -1
@@ -1555,7 +1555,7 @@ int kvmppc_xive_set_mapped(struct kvm *kvm, unsigned long guest_irq,struct kvmppc_xive_src_block *sb;struct kvmppc_xive_irq_state *state;struct irq_data *host_data = -irq_domain_get_irq_data (irq_get_default_host (), host_irq); +irq_domain_get_irq_data (irq_get_default_domain (), host_irq);unsigned int hw_irq = (unsigned int )irqd_to_hwirq (host_data);u16 idx;u8 prio;
arch/powerpc/platforms/powernv/pci-ioda.c +1 -1
@@ -1924,7 +1924,7 @@ static const struct irq_domain_ops pnv_irq_domain_ops = {static int __init pnv_msi_allocate_domains (struct pci_controller *hose,unsigned int count) {struct pnv_phb *phb = hose->private_data; -struct irq_domain *parent =irq_get_default_host (); +struct irq_domain *parent =irq_get_default_domain (); hose->fwnode =irq_domain_alloc_named_id_fwnode ("PNV-MSI" , phb->opal_id);if (!hose->fwnode)
arch/powerpc/platforms/pseries/msi.c +1 -1
@@ -611,7 +611,7 @@ static const struct irq_domain_ops pseries_irq_domain_ops = {static int __pseries_msi_allocate_domains (struct pci_controller *phb,unsigned int count) { -struct irq_domain *parent =irq_get_default_host (); +struct irq_domain *parent =irq_get_default_domain (); phb->fwnode =irq_domain_alloc_named_id_fwnode ("pSeries-MSI" , phb->global_number);
drivers/irqchip/irq-armada-370-xp.c +2 -2
@@ -564,7 +564,7 @@ static void mpic_reenable_percpu(struct mpic *mpic)static int mpic_starting_cpu (unsigned int cpu) { -struct mpic *mpic =irq_get_default_host ()->host_data; +struct mpic *mpic =irq_get_default_domain ()->host_data;mpic_perf_init (mpic);mpic_smp_cpu_init (mpic);
@@ -700,7 +700,7 @@ static void mpic_handle_cascade_irq(struct irq_desc *desc) static void __exception_irq_entry mpic_handle_irq(struct pt_regs *regs) { -struct mpic *mpic =irq_get_default_host ()->host_data; +struct mpic *mpic =irq_get_default_domain ()->host_data;irq_hw_number_t i;u32 irqstat;
include/linux/irqdomain.h +1 -1
@@ -353,7 +353,7 @@ struct irq_domain *irq_domain_create_legacy(struct fwnode_handle *fwnode,struct irq_domain *irq_find_matching_fwspec (struct irq_fwspec *fwspec,enum irq_domain_bus_token bus_token);void irq_set_default_domain (struct irq_domain *domain); -struct irq_domain *irq_get_default_host (void ); +struct irq_domain *irq_get_default_domain (void );int irq_domain_alloc_descs (int virq,unsigned int nr_irqs,irq_hw_number_t hwirq,int node,const struct irq_affinity_desc *affinity);
kernel/irq/irqdomain.c +3 -3
@@ -590,7 +590,7 @@ void irq_set_default_domain(struct irq_domain *domain)EXPORT_SYMBOL_GPL (irq_set_default_domain);/** -* irq_get_default_host() - Retrieve the "default" irq domain +* irq_get_default_domain() - Retrieve the "default" irq domain * * Returns: the default domain, if any. *
@@ -598,11 +598,11 @@ EXPORT_SYMBOL_GPL(irq_set_default_domain);* systems that cannot implement a firmware->fwnode mapping (which * both DT and ACPI provide). */ -struct irq_domain *irq_get_default_host (void ) +struct irq_domain *irq_get_default_domain (void ) {return irq_default_domain; } -EXPORT_SYMBOL_GPL (irq_get_default_host); +EXPORT_SYMBOL_GPL (irq_get_default_domain);static bool irq_domain_is_nomap (struct irq_domain *domain) {
Signature · 1 line
2.48.0
PATCH 4/18 irqdomain.h: Stop using 'host' for domain
In reply to Jiri Slaby (SUSE)It is confusing to see 'host' and 'domain' to be used as 'domain'. Given this header is all about domains, switch the remaining 'host' uses to 'domain'.
--- include/linux/irqdomain.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
include/linux/irqdomain.h +6 -6
@@ -72,7 +72,7 @@ void of_phandle_args_to_fwspec(struct device_node *np, const u32 *args,/** * struct irq_domain_ops - Methods for irq_domain objects -* @match: Match an interrupt controller device node to a host, returns +* @match: Match an interrupt controller device node to a domain, returns * 1 on a match * @select: Match an interrupt controller fw specification. It is more generic * than @match as it receives a complete struct irq_fwspec. Therefore,
@@ -454,7 +454,7 @@ static inline struct irq_domain *irq_domain_add_nomap(struct device_node *of_nodreturn IS_ERR (d) ?NULL : d; } -unsigned int irq_create_direct_mapping (struct irq_domain *host); +unsigned int irq_create_direct_mapping (struct irq_domain *domain);#endif static inline struct irq_domain *irq_domain_add_tree(struct device_node *of_node,
@@ -507,7 +507,7 @@ static inline struct irq_domain *irq_domain_create_tree(struct fwnode_handle *fwreturn IS_ERR (d) ?NULL : d; } -void irq_domain_remove (struct irq_domain *host); +void irq_domain_remove (struct irq_domain *domain);int irq_domain_associate (struct irq_domain *domain,unsigned int irq,irq_hw_number_t hwirq);
@@ -515,16 +515,16 @@ void irq_domain_associate_many(struct irq_domain *domain,unsigned int irq_base, irq_hw_number_t hwirq_base, int count); -unsigned int irq_create_mapping_affinity (struct irq_domain *host, +unsigned int irq_create_mapping_affinity (struct irq_domain *domain,irq_hw_number_t hwirq,const struct irq_affinity_desc *affinity);unsigned int irq_create_fwspec_mapping (struct irq_fwspec *fwspec);void irq_dispose_mapping (unsigned int virq); -static inline unsigned int irq_create_mapping (struct irq_domain *host, +static inline unsigned int irq_create_mapping (struct irq_domain *domain,irq_hw_number_t hwirq) { -return irq_create_mapping_affinity (host, hwirq,NULL ); +return irq_create_mapping_affinity (domain, hwirq,NULL ); } struct irq_desc *__irq_resolve_mapping(struct irq_domain *domain,
Signature · 1 line
2.48.0
PATCH 5/18 irqdomain: Drop of_node_to_fwnode()
In reply to Jiri Slaby (SUSE)This is the same as "officially" defined of_fwnode_handle() in (already included) of.h. So use the latter instead of the former and drop the former.
--- arch/powerpc/platforms/powernv/pci-ioda.c | 2 +- arch/powerpc/platforms/pseries/msi.c | 2 +- arch/x86/kernel/apic/io_apic.c | 2 +- drivers/cdx/cdx_msi.c | 4 ++-- drivers/irqchip/irq-alpine-msi.c | 2 +- drivers/irqchip/irq-apple-aic.c | 4 ++-- drivers/irqchip/irq-armada-370-xp.c | 4 ++-- drivers/irqchip/irq-gic-v3-its-fsl-mc-msi.c | 2 +- drivers/irqchip/irq-gic-v3.c | 4 ++-- drivers/irqchip/irq-ixp4xx.c | 2 +- drivers/irqchip/irq-lan966x-oic.c | 2 +- drivers/irqchip/irq-loongarch-cpu.c | 2 +- drivers/irqchip/irq-loongson-eiointc.c | 2 +- drivers/irqchip/irq-loongson-htvec.c | 2 +- drivers/irqchip/irq-loongson-liointc.c | 2 +- drivers/irqchip/irq-loongson-pch-msi.c | 2 +- drivers/irqchip/irq-loongson-pch-pic.c | 2 +- drivers/irqchip/irq-ls-scfg-msi.c | 2 +- drivers/irqchip/irq-meson-gpio.c | 2 +- drivers/irqchip/irq-mvebu-gicp.c | 2 +- drivers/irqchip/irq-mvebu-odmi.c | 2 +- drivers/irqchip/irq-mvebu-sei.c | 6 +++--- drivers/irqchip/irq-qcom-mpm.c | 2 +- drivers/irqchip/irq-riscv-intc.c | 2 +- drivers/irqchip/irq-sni-exiu.c | 2 +- drivers/irqchip/irq-stm32mp-exti.c | 2 +- drivers/irqchip/irq-ti-sci-inta.c | 4 ++-- drivers/irqchip/irq-ti-sci-intr.c | 2 +- drivers/irqchip/irq-uniphier-aidet.c | 2 +- .../pci/controller/dwc/pcie-designware-host.c | 2 +- .../controller/mobiveil/pcie-mobiveil-host.c | 2 +- drivers/pci/controller/pci-xgene-msi.c | 2 +- drivers/pci/controller/pcie-altera-msi.c | 2 +- drivers/pci/controller/pcie-brcmstb.c | 2 +- drivers/pci/controller/pcie-iproc-msi.c | 2 +- drivers/pci/controller/pcie-mediatek.c | 2 +- drivers/pci/controller/pcie-xilinx-dma-pl.c | 2 +- drivers/pci/controller/pcie-xilinx-nwl.c | 2 +- drivers/pci/controller/plda/pcie-plda-host.c | 2 +- drivers/remoteproc/pru_rproc.c | 2 +- include/linux/irqdomain.h | 17 ++++++----------- kernel/irq/irqdomain.c | 4 ++-- 42 files changed, 55 insertions(+), 60 deletions(-)
arch/powerpc/platforms/powernv/pci-ioda.c +1 -1
@@ -1940,7 +1940,7 @@ static int __init pnv_msi_allocate_domains(struct pci_controller *hose, unsignedreturn -ENOMEM ; } - hose->msi_domain =pci_msi_create_irq_domain (of_node_to_fwnode (hose->dn), + hose->msi_domain =pci_msi_create_irq_domain (of_fwnode_handle (hose->dn), &pnv_msi_domain_info, hose->dev_domain);if (!hose->msi_domain) {
arch/powerpc/platforms/pseries/msi.c +1 -1
@@ -628,7 +628,7 @@ static int __pseries_msi_allocate_domains(struct pci_controller *phb,return -ENOMEM ; } - phb->msi_domain =pci_msi_create_irq_domain (of_node_to_fwnode (phb->dn), + phb->msi_domain =pci_msi_create_irq_domain (of_fwnode_handle (phb->dn), &pseries_msi_domain_info, phb->dev_domain);if (!phb->msi_domain) {
arch/x86/kernel/apic/io_apic.c +1 -1
@@ -2225,7 +2225,7 @@ static int mp_irqdomain_create(int ioapic)/* Handle device tree enumerated APICs proper */ if (cfg->dev) { - fn =of_node_to_fwnode (cfg->dev); + fn =of_fwnode_handle (cfg->dev); }else { fn =irq_domain_alloc_named_id_fwnode ("IO-APIC" ,mpc_ioapic_id (ioapic));if (!fn)
drivers/cdx/cdx_msi.c +2 -2
@@ -165,7 +165,7 @@ struct irq_domain *cdx_msi_domain_init(struct device *dev)struct device_node *parent_node;struct irq_domain *parent; - fwnode_handle =of_node_to_fwnode (np); + fwnode_handle =of_fwnode_handle (np); parent_node =of_parse_phandle (np,"msi-map" ,1 );if (!parent_node) {
@@ -173,7 +173,7 @@ struct irq_domain *cdx_msi_domain_init(struct device *dev)return NULL ; } - parent =irq_find_matching_fwnode (of_node_to_fwnode (parent_node),DOMAIN_BUS_NEXUS ); + parent =irq_find_matching_fwnode (of_fwnode_handle (parent_node),DOMAIN_BUS_NEXUS );if (!parent || !msi_get_domain_info (parent)) {dev_err (dev,"unable to locate ITS domain\n" );return NULL ;
drivers/irqchip/irq-alpine-msi.c +1 -1
@@ -213,7 +213,7 @@ static int alpine_msix_init_domains(struct alpine_msix_data *priv,return -ENOMEM ; } - msi_domain =pci_msi_create_irq_domain (of_node_to_fwnode (node), + msi_domain =pci_msi_create_irq_domain (of_fwnode_handle (node), &alpine_msix_domain_info, middle_domain);if (!msi_domain) {
drivers/irqchip/irq-apple-aic.c +2 -2
@@ -1013,7 +1013,7 @@ static int __init aic_of_ic_init(struct device_node *node, struct device_node *p irqc->info.die_stride = off - start_off; - irqc->hw_domain =irq_domain_create_tree (of_node_to_fwnode (node), + irqc->hw_domain =irq_domain_create_tree (of_fwnode_handle (node), &aic_irq_domain_ops, irqc);if (WARN_ON (!irqc->hw_domain)) goto err_unmap;
@@ -1066,7 +1066,7 @@ static int __init aic_of_ic_init(struct device_node *node, struct device_node *pif (is_kernel_in_hyp_mode ()) {struct irq_fwspec mi = { - .fwnode =of_node_to_fwnode (node), + .fwnode =of_fwnode_handle (node), .param_count =3 , .param = { [0 ] =AIC_FIQ ,/* This is a lie */
drivers/irqchip/irq-armada-370-xp.c +2 -2
@@ -353,7 +353,7 @@ static int __init mpic_msi_init(struct mpic *mpic, struct device_node *node,if (!mpic->msi_inner_domain)return -ENOMEM ; - mpic->msi_domain =pci_msi_create_irq_domain (of_node_to_fwnode (node), &mpic_msi_domain_info, + mpic->msi_domain =pci_msi_create_irq_domain (of_fwnode_handle (node), &mpic_msi_domain_info, mpic->msi_inner_domain);if (!mpic->msi_domain) {irq_domain_remove (mpic->msi_inner_domain);
@@ -492,7 +492,7 @@ static int __init mpic_ipi_init(struct mpic *mpic, struct device_node *node) {int base_ipi; - mpic->ipi_domain =irq_domain_create_linear (of_node_to_fwnode (node),IPI_DOORBELL_NR , + mpic->ipi_domain =irq_domain_create_linear (of_fwnode_handle (node),IPI_DOORBELL_NR , &mpic_ipi_domain_ops, mpic);if (WARN_ON (!mpic->ipi_domain))return -ENOMEM ;
drivers/irqchip/irq-gic-v3-its-fsl-mc-msi.c +1 -1
@@ -152,7 +152,7 @@ static void __init its_fsl_mc_of_msi_init(void)if (!of_property_read_bool (np,"msi-controller" ))continue ; -its_fsl_mc_msi_init_one (of_node_to_fwnode (np), +its_fsl_mc_msi_init_one (of_fwnode_handle (np), np->full_name); } }
drivers/irqchip/irq-gic-v3.c +2 -2
@@ -1817,7 +1817,7 @@ static int partition_domain_translate(struct irq_domain *d, ppi_idx =__gic_get_ppi_index (ppi_intid); ret =partition_translate_id (gic_data.ppi_descs[ppi_idx], -of_node_to_fwnode (np)); +of_fwnode_handle (np));if (ret <0 )return ret;
@@ -2165,7 +2165,7 @@ static void __init gic_populate_ppi_partitions(struct device_node *gic_node) part = &parts[part_idx]; - part->partition_id =of_node_to_fwnode (child_part); + part->partition_id =of_fwnode_handle (child_part);pr_info ("GIC: PPI partition %pOFn[%d] { " , child_part, part_idx);
drivers/irqchip/irq-ixp4xx.c +1 -1
@@ -261,7 +261,7 @@ static int __init ixp4xx_of_init_irq(struct device_node *np,pr_crit ("IXP4XX: could not ioremap interrupt controller\n" );return -ENODEV ; } - fwnode =of_node_to_fwnode (np); + fwnode =of_fwnode_handle (np);/* These chip variants have 64 interrupts */ is_356 = of_device_is_compatible(np, "intel,ixp43x-interrupt") ||
drivers/irqchip/irq-lan966x-oic.c +1 -1
@@ -224,7 +224,7 @@ static int lan966x_oic_probe(struct platform_device *pdev) .exit = lan966x_oic_chip_exit, };struct irq_domain_info d_info = { - .fwnode =of_node_to_fwnode (pdev->dev.of_node), + .fwnode =of_fwnode_handle (pdev->dev.of_node), .domain_flags =IRQ_DOMAIN_FLAG_DESTROY_GC , .size =LAN966X_OIC_NR_IRQ , .hwirq_max =LAN966X_OIC_NR_IRQ ,
drivers/irqchip/irq-loongarch-cpu.c +1 -1
@@ -100,7 +100,7 @@ static const struct irq_domain_ops loongarch_cpu_intc_irq_domain_ops = {static int __init cpuintc_of_init (struct device_node *of_node,struct device_node *parent) { - cpuintc_handle =of_node_to_fwnode (of_node); + cpuintc_handle =of_fwnode_handle (of_node); irq_domain =irq_domain_create_linear (cpuintc_handle,EXCCODE_INT_NUM , &loongarch_cpu_intc_irq_domain_ops,NULL );
drivers/irqchip/irq-loongson-eiointc.c +1 -1
@@ -554,7 +554,7 @@ static int __init eiointc_of_init(struct device_node *of_node, priv->vec_count =VEC_COUNT ; priv->node =0 ; - priv->domain_handle =of_node_to_fwnode (of_node); + priv->domain_handle =of_fwnode_handle (of_node); ret =eiointc_init (priv, parent_irq,0 );if (ret <0 )
drivers/irqchip/irq-loongson-htvec.c +1 -1
@@ -248,7 +248,7 @@ static int htvec_of_init(struct device_node *node, } err =htvec_init (res.start,resource_size (&res), - num_parents, parent_irq,of_node_to_fwnode (node)); + num_parents, parent_irq,of_fwnode_handle (node));if (err <0 )return err;
drivers/irqchip/irq-loongson-liointc.c +1 -1
@@ -363,7 +363,7 @@ static int __init liointc_of_init(struct device_node *node, } err =liointc_init (res.start,resource_size (&res), - revision,of_node_to_fwnode (node), node); + revision,of_fwnode_handle (node), node);if (err <0 )return err;
drivers/irqchip/irq-loongson-pch-msi.c +1 -1
@@ -242,7 +242,7 @@ static int pch_msi_of_init(struct device_node *node, struct device_node *parent)return -EINVAL ; } - err =pch_msi_init (res.start, irq_base, irq_count, parent_domain,of_node_to_fwnode (node)); + err =pch_msi_init (res.start, irq_base, irq_count, parent_domain,of_fwnode_handle (node));if (err <0 )return err;
drivers/irqchip/irq-loongson-pch-pic.c +1 -1
@@ -392,7 +392,7 @@ static int pch_pic_of_init(struct device_node *node, } err =pch_pic_init (res.start,resource_size (&res), vec_base, - parent_domain,of_node_to_fwnode (node),0 ); + parent_domain,of_fwnode_handle (node),0 );if (err <0 )return err;
drivers/irqchip/irq-ls-scfg-msi.c +1 -1
@@ -226,7 +226,7 @@ static int ls_scfg_msi_domains_init(struct ls_scfg_msi *msi_data) } msi_data->msi_domain =pci_msi_create_irq_domain ( -of_node_to_fwnode (msi_data->pdev->dev.of_node), +of_fwnode_handle (msi_data->pdev->dev.of_node), &ls_scfg_msi_domain_info, msi_data->parent);if (!msi_data->msi_domain) {
drivers/irqchip/irq-meson-gpio.c +1 -1
@@ -581,7 +581,7 @@ static int meson_gpio_irq_of_init(struct device_node *node, struct device_node * domain =irq_domain_create_hierarchy (parent_domain,0 , ctl->params->nr_hwirq, -of_node_to_fwnode (node), +of_fwnode_handle (node), &meson_gpio_irq_domain_ops, ctl);if (!domain) {
drivers/irqchip/irq-mvebu-gicp.c +1 -1
@@ -231,7 +231,7 @@ static int mvebu_gicp_probe(struct platform_device *pdev) inner_domain =irq_domain_create_hierarchy (parent_domain,0 , gicp->spi_cnt, -of_node_to_fwnode (node), +of_fwnode_handle (node), &gicp_domain_ops, gicp);if (!inner_domain)return -ENOMEM ;
drivers/irqchip/irq-mvebu-odmi.c +1 -1
@@ -206,7 +206,7 @@ static int __init mvebu_odmi_init(struct device_node *node, inner_domain =irq_domain_create_hierarchy (parent_domain,0 , odmis_count *NODMIS_PER_FRAME , -of_node_to_fwnode (node), +of_fwnode_handle (node), &odmi_domain_ops,NULL );if (!inner_domain) { ret = -ENOMEM ;
drivers/irqchip/irq-mvebu-sei.c +3 -3
@@ -401,7 +401,7 @@ static int mvebu_sei_probe(struct platform_device *pdev) }/* Create the root SEI domain */ - sei->sei_domain = irq_domain_create_linear(of_node_to_fwnode(node), + sei->sei_domain = irq_domain_create_linear(of_fwnode_handle(node), (sei->caps->ap_range.size + sei->caps->cp_range.size), &mvebu_sei_domain_ops,
@@ -417,7 +417,7 @@ static int mvebu_sei_probe(struct platform_device *pdev)/* Create the 'wired' domain */ sei->ap_domain =irq_domain_create_hierarchy (sei->sei_domain,0 , sei->caps->ap_range.size, -of_node_to_fwnode (node), +of_fwnode_handle (node), &mvebu_sei_ap_domain_ops, sei);if (!sei->ap_domain) {
@@ -431,7 +431,7 @@ static int mvebu_sei_probe(struct platform_device *pdev)/* Create the 'MSI' domain */ sei->cp_domain =irq_domain_create_hierarchy (sei->sei_domain,0 , sei->caps->cp_range.size, -of_node_to_fwnode (node), +of_fwnode_handle (node), &mvebu_sei_cp_domain_ops, sei);if (!sei->cp_domain) {
drivers/irqchip/irq-qcom-mpm.c +1 -1
@@ -447,7 +447,7 @@ static int qcom_mpm_init(struct device_node *np, struct device_node *parent) priv->domain =irq_domain_create_hierarchy (parent_domain,IRQ_DOMAIN_FLAG_QCOM_MPM_WAKEUP , pin_cnt, -of_node_to_fwnode (np), &qcom_mpm_ops, priv); +of_fwnode_handle (np), &qcom_mpm_ops, priv);if (!priv->domain) {dev_err (dev,"failed to create MPM domain\n" ); ret = -ENOMEM ;
drivers/irqchip/irq-riscv-intc.c +1 -1
@@ -242,7 +242,7 @@ static int __init riscv_intc_init(struct device_node *node, chip = &andes_intc_chip; } -return riscv_intc_init_common (of_node_to_fwnode (node), chip); +return riscv_intc_init_common (of_fwnode_handle (node), chip); }IRQCHIP_DECLARE (riscv,"riscv,cpu-intc" , riscv_intc_init);
drivers/irqchip/irq-sni-exiu.c +1 -1
@@ -249,7 +249,7 @@ static int __init exiu_dt_init(struct device_node *node,return -ENXIO ; } - data =exiu_init (of_node_to_fwnode (node), &res); + data =exiu_init (of_fwnode_handle (node), &res);if (IS_ERR (data))return PTR_ERR (data);
drivers/irqchip/irq-stm32mp-exti.c +1 -1
@@ -531,7 +531,7 @@ static int stm32mp_exti_domain_alloc(struct irq_domain *dm,if (ret)return ret;/* we only support one parent, so far */ -if (of_node_to_fwnode (out_irq.np) != dm->parent->fwnode) +if (of_fwnode_handle (out_irq.np) != dm->parent->fwnode)return -EINVAL ; of_phandle_args_to_fwspec(out_irq.np, out_irq.args,
drivers/irqchip/irq-ti-sci-inta.c +2 -2
@@ -233,7 +233,7 @@ static struct ti_sci_inta_vint_desc *ti_sci_inta_alloc_parent_irq(struct irq_domINIT_LIST_HEAD (&vint_desc->list); parent_node =of_irq_find_parent (dev_of_node (&inta->pdev->dev)); - parent_fwspec.fwnode =of_node_to_fwnode (parent_node); + parent_fwspec.fwnode =of_fwnode_handle (parent_node);if (of_device_is_compatible (parent_node,"arm,gic-v3" )) {/* Parent is GIC */
@@ -709,7 +709,7 @@ static int ti_sci_inta_irq_domain_probe(struct platform_device *pdev)return -ENOMEM ; } - msi_domain =ti_sci_inta_msi_create_irq_domain (of_node_to_fwnode (node), + msi_domain =ti_sci_inta_msi_create_irq_domain (of_fwnode_handle (node), &ti_sci_inta_msi_domain_info, domain);if (!msi_domain) {
drivers/irqchip/irq-ti-sci-intr.c +1 -1
@@ -149,7 +149,7 @@ static int ti_sci_intr_alloc_parent_irq(struct irq_domain *domain, goto err_irqs; parent_node =of_irq_find_parent (dev_of_node (intr->dev)); - fwspec.fwnode =of_node_to_fwnode (parent_node); + fwspec.fwnode =of_fwnode_handle (parent_node);if (of_device_is_compatible (parent_node,"arm,gic-v3" )) {/* Parent is GIC */
drivers/irqchip/irq-uniphier-aidet.c +1 -1
@@ -188,7 +188,7 @@ static int uniphier_aidet_probe(struct platform_device *pdev) priv->domain =irq_domain_create_hierarchy ( parent_domain,0 ,UNIPHIER_AIDET_NR_IRQS , -of_node_to_fwnode (dev->of_node), +of_fwnode_handle (dev->of_node), &uniphier_aidet_domain_ops, priv);if (!priv->domain)return -ENOMEM ;
drivers/pci/controller/dwc/pcie-designware-host.c +1 -1
@@ -227,7 +227,7 @@ static const struct irq_domain_ops dw_pcie_msi_domain_ops = {int dw_pcie_allocate_domains (struct dw_pcie_rp *pp) {struct dw_pcie *pci =to_dw_pcie_from_pp (pp); -struct fwnode_handle *fwnode =of_node_to_fwnode (pci->dev->of_node); +struct fwnode_handle *fwnode =of_fwnode_handle (pci->dev->of_node); pp->irq_domain =irq_domain_create_linear (fwnode, pp->num_vectors, &dw_pcie_msi_domain_ops, pp);
drivers/pci/controller/mobiveil/pcie-mobiveil-host.c +1 -1
@@ -435,7 +435,7 @@ static const struct irq_domain_ops msi_domain_ops = {static int mobiveil_allocate_msi_domains (struct mobiveil_pcie *pcie) {struct device *dev = &pcie->pdev->dev; -struct fwnode_handle *fwnode =of_node_to_fwnode (dev->of_node); +struct fwnode_handle *fwnode =of_fwnode_handle (dev->of_node);struct mobiveil_msi *msi = &pcie->rp.msi;mutex_init (&msi->lock);
drivers/pci/controller/pci-xgene-msi.c +1 -1
@@ -247,7 +247,7 @@ static int xgene_allocate_domains(struct xgene_msi *msi)if (!msi->inner_domain)return -ENOMEM ; - msi->msi_domain =pci_msi_create_irq_domain (of_node_to_fwnode (msi->node), + msi->msi_domain =pci_msi_create_irq_domain (of_fwnode_handle (msi->node), &xgene_msi_domain_info, msi->inner_domain);
drivers/pci/controller/pcie-altera-msi.c +1 -1
@@ -164,7 +164,7 @@ static const struct irq_domain_ops msi_domain_ops = {static int altera_allocate_domains (struct altera_msi *msi) { -struct fwnode_handle *fwnode =of_node_to_fwnode (msi->pdev->dev.of_node); +struct fwnode_handle *fwnode =of_fwnode_handle (msi->pdev->dev.of_node); msi->inner_domain =irq_domain_add_linear (NULL , msi->num_of_vectors, &msi_domain_ops, msi);
drivers/pci/controller/pcie-brcmstb.c +1 -1
@@ -572,7 +572,7 @@ static const struct irq_domain_ops msi_domain_ops = {static int brcm_allocate_domains (struct brcm_msi *msi) { -struct fwnode_handle *fwnode =of_node_to_fwnode (msi->np); +struct fwnode_handle *fwnode =of_fwnode_handle (msi->np);struct device *dev = msi->dev; msi->inner_domain =irq_domain_add_linear (NULL , msi->nr, &msi_domain_ops, msi);
drivers/pci/controller/pcie-iproc-msi.c +1 -1
@@ -451,7 +451,7 @@ static int iproc_msi_alloc_domains(struct device_node *node,if (!msi->inner_domain)return -ENOMEM ; - msi->msi_domain =pci_msi_create_irq_domain (of_node_to_fwnode (node), + msi->msi_domain =pci_msi_create_irq_domain (of_fwnode_handle (node), &iproc_msi_domain_info, msi->inner_domain);if (!msi->msi_domain) {
drivers/pci/controller/pcie-mediatek.c +1 -1
@@ -485,7 +485,7 @@ static struct msi_domain_info mtk_msi_domain_info = {static int mtk_pcie_allocate_msi_domains (struct mtk_pcie_port *port) { -struct fwnode_handle *fwnode =of_node_to_fwnode (port->pcie->dev->of_node); +struct fwnode_handle *fwnode =of_fwnode_handle (port->pcie->dev->of_node);mutex_init (&port->lock);
drivers/pci/controller/pcie-xilinx-dma-pl.c +1 -1
@@ -470,7 +470,7 @@ static int xilinx_pl_dma_pcie_init_msi_irq_domain(struct pl_dma_pcie *port)struct device *dev = port->dev;struct xilinx_msi *msi = &port->msi;int size =BITS_TO_LONGS (XILINX_NUM_MSI_IRQS ) *sizeof (long ); -struct fwnode_handle *fwnode =of_node_to_fwnode (port->dev->of_node); +struct fwnode_handle *fwnode =of_fwnode_handle (port->dev->of_node); msi->dev_domain =irq_domain_add_linear (NULL ,XILINX_NUM_MSI_IRQS , &dev_msi_domain_ops, port);
drivers/pci/controller/pcie-xilinx-nwl.c +1 -1
@@ -495,7 +495,7 @@ static int nwl_pcie_init_msi_irq_domain(struct nwl_pcie *pcie) {#ifdef CONFIG_PCI_MSI struct device *dev = pcie->dev; -struct fwnode_handle *fwnode =of_node_to_fwnode (dev->of_node); +struct fwnode_handle *fwnode =of_fwnode_handle (dev->of_node);struct nwl_msi *msi = &pcie->msi; msi->dev_domain = irq_domain_add_linear(NULL, INT_PCI_MSI_NR,
drivers/pci/controller/plda/pcie-plda-host.c +1 -1
@@ -147,7 +147,7 @@ static struct msi_domain_info plda_msi_domain_info = {static int plda_allocate_msi_domains (struct plda_pcie_rp *port) {struct device *dev = port->dev; -struct fwnode_handle *fwnode =of_node_to_fwnode (dev->of_node); +struct fwnode_handle *fwnode =of_fwnode_handle (dev->of_node);struct plda_msi *msi = &port->msi;mutex_init (&port->msi.lock);
drivers/remoteproc/pru_rproc.c +1 -1
@@ -563,7 +563,7 @@ static int pru_handle_intrmap(struct rproc *rproc)return -ENODEV ; } - fwspec.fwnode =of_node_to_fwnode (irq_parent); + fwspec.fwnode =of_fwnode_handle (irq_parent); fwspec.param_count =3 ;for (i =0 ; i < pru->evt_count; i++) { fwspec.param[0 ] = rsc->pru_intc_map[i].event;
include/linux/irqdomain.h +6 -11
@@ -358,11 +358,6 @@ int irq_domain_alloc_descs(int virq, unsigned int nr_irqs, irq_hw_number_t hwirq, int node, const struct irq_affinity_desc *affinity); -static inline struct fwnode_handle *of_node_to_fwnode (struct device_node *node) -{ -return node ? &node->fwnode :NULL ; -} -extern const struct fwnode_operations irqchip_fwnode_ops;static inline bool is_fwnode_irqchip (const struct fwnode_handle *fwnode)
@@ -387,7 +382,7 @@ struct irq_domain *irq_find_matching_fwnode(struct fwnode_handle *fwnode,static inline struct irq_domain *irq_find_matching_host (struct device_node *node,enum irq_domain_bus_token bus_token) { -return irq_find_matching_fwnode (of_node_to_fwnode (node), bus_token); +return irq_find_matching_fwnode (of_fwnode_handle (node), bus_token); }static inline struct irq_domain *irq_find_host (struct device_node *node)
@@ -407,7 +402,7 @@ static inline struct irq_domain *irq_domain_add_simple(struct device_node *of_noconst struct irq_domain_ops *ops, void *host_data) { - return irq_domain_create_simple(of_node_to_fwnode(of_node), size, first_irq, ops, host_data); + return irq_domain_create_simple(of_fwnode_handle(of_node), size, first_irq, ops, host_data); }/**
@@ -423,7 +418,7 @@ static inline struct irq_domain *irq_domain_add_linear(struct device_node *of_no void *host_data) {struct irq_domain_info info = { - .fwnode =of_node_to_fwnode (of_node), + .fwnode =of_fwnode_handle (of_node), .size = size, .hwirq_max = size, .ops = ops,
@@ -442,7 +437,7 @@ static inline struct irq_domain *irq_domain_add_nomap(struct device_node *of_nod void *host_data) {struct irq_domain_info info = { - .fwnode =of_node_to_fwnode (of_node), + .fwnode =of_fwnode_handle (of_node), .hwirq_max = max_irq, .direct_max = max_irq, .ops = ops,
@@ -462,7 +457,7 @@ static inline struct irq_domain *irq_domain_add_tree(struct device_node *of_node void *host_data) {struct irq_domain_info info = { - .fwnode =of_node_to_fwnode (of_node), + .fwnode =of_fwnode_handle (of_node), .hwirq_max = ~0U , .ops = ops, .host_data = host_data,
@@ -611,7 +606,7 @@ static inline struct irq_domain *irq_domain_add_hierarchy(struct irq_domain *par void *host_data) {return irq_domain_create_hierarchy (parent, flags, size, -of_node_to_fwnode (node), +of_fwnode_handle (node), ops, host_data); }
kernel/irq/irqdomain.c +2 -2
@@ -502,7 +502,7 @@ struct irq_domain *irq_domain_add_legacy(struct device_node *of_node,const struct irq_domain_ops *ops, void *host_data) { - return irq_domain_create_legacy(of_node_to_fwnode(of_node), size, + return irq_domain_create_legacy(of_fwnode_handle(of_node), size,first_irq ,first_hwirq ,ops ,host_data ); }EXPORT_SYMBOL_GPL (irq_domain_add_legacy);
@@ -885,7 +885,7 @@ void of_phandle_args_to_fwspec(struct device_node *np, const u32 *args, {int i; - fwspec->fwnode =of_node_to_fwnode (np); + fwspec->fwnode =of_fwnode_handle (np); fwspec->param_count = count;for (i =0 ; i < count; i++)
Signature · 1 line
2.48.0
PATCH 6/18 irqdomain: Make a couple of functions an inline
In reply to Jiri Slaby (SUSE)There is no reason to export these functions as extra symbols. They are simple enough and are just wrappers to already exported functions.
So switch the exported functions to inlines.
--- include/linux/irqdomain.h | 78 +++++++++++++++++++++++++++++++++------ kernel/irq/irqdomain.c | 68 ---------------------------------- 2 files changed, 66 insertions(+), 80 deletions(-)
include/linux/irqdomain.h +66 -12
@@ -338,18 +338,39 @@ struct irq_domain *irq_domain_create_simple(struct fwnode_handle *fwnode,unsigned int first_irq, const struct irq_domain_ops *ops, void *host_data); -struct irq_domain *irq_domain_add_legacy (struct device_node *of_node, -unsigned int size, -unsigned int first_irq, -irq_hw_number_t first_hwirq, -const struct irq_domain_ops *ops, -void *host_data);struct irq_domain *irq_domain_create_legacy (struct fwnode_handle *fwnode,unsigned int size,unsigned int first_irq,irq_hw_number_t first_hwirq,const struct irq_domain_ops *ops,void *host_data); + +/** +* irq_domain_add_legacy() - Allocate and register a legacy revmap irq_domain. +* @of_node: pointer to interrupt controller's device tree node. +* @size: total number of irqs in legacy mapping +* @first_irq: first number of irq block assigned to the domain +* @first_hwirq: first hwirq number to use for the translation. Should normally +* be '0', but a positive integer can be used if the effective +* hwirqs numbering does not begin at zero. +* @ops: map/unmap domain callbacks +* @host_data: Controller private data pointer +* +* Note: the map() callback will be called before this function returns +* for all legacy interrupts except 0 (which is always the invalid irq for +* a legacy controller). +*/ +static inline struct irq_domain *irq_domain_add_legacy (struct device_node *of_node, +unsigned int size, +unsigned int first_irq, +irq_hw_number_t first_hwirq, +const struct irq_domain_ops *ops, +void *host_data) +{ +return irq_domain_create_legacy (of_fwnode_handle (of_node), size, + first_irq, first_hwirq, ops, host_data); +} +struct irq_domain *irq_find_matching_fwspec (struct irq_fwspec *fwspec,enum irq_domain_bus_token bus_token);void irq_set_default_domain (struct irq_domain *domain);
@@ -591,12 +612,45 @@ void irq_domain_set_info(struct irq_domain *domain, unsigned int virq, void *handler_data, const char *handler_name);void irq_domain_reset_irq_data (struct irq_data *irq_data);#ifdef CONFIG_IRQ_DOMAIN_HIERARCHY -struct irq_domain *irq_domain_create_hierarchy (struct irq_domain *parent, -unsigned int flags, -unsigned int size, -struct fwnode_handle *fwnode, -const struct irq_domain_ops *ops, -void *host_data); +/** +* irq_domain_create_hierarchy - Add a irqdomain into the hierarchy +* @parent: Parent irq domain to associate with the new domain +* @flags: Irq domain flags associated to the domain +* @size: Size of the domain. See below +* @fwnode: Optional fwnode of the interrupt controller +* @ops: Pointer to the interrupt domain callbacks +* @host_data: Controller private data pointer +* +* If @size is 0 a tree domain is created, otherwise a linear domain. +* +* If successful the parent is associated to the new domain and the +* domain flags are set. +* Returns pointer to IRQ domain, or NULL on failure. +*/ +static inline struct irq_domain *irq_domain_create_hierarchy (struct irq_domain *parent, +unsigned int flags, +unsigned int size, +struct fwnode_handle *fwnode, +const struct irq_domain_ops *ops, +void *host_data) +{ +struct irq_domain_info info = { + .fwnode = fwnode, + .size = size, + .hwirq_max = size, + .ops = ops, + .host_data = host_data, + .domain_flags = flags, + .parent = parent, + }; +struct irq_domain *d; + +if (!info.size) + info.hwirq_max = ~0U ; + + d =irq_domain_instantiate (&info); +return IS_ERR (d) ?NULL : d; +} static inline struct irq_domain *irq_domain_add_hierarchy(struct irq_domain *parent, unsigned int flags,
kernel/irq/irqdomain.c +0 -68
80 lines not on this page · raw message
Signature · 1 line
2.48.0
PATCH 7/18 irqdomain: Make irq_domain_instantiate() returned domains an initializer
In reply to Jiri Slaby (SUSE)I was thinking whether add a \n before the 'return' or this. And this looks both more compact and more readable.
Note irq_domain_create_hierarchy()'s handling of size is now part of info's initializer (using the ternary operator). That makes more sense while reading it.
--- include/linux/irqdomain.h | 23 +++++++---------------- 1 file changed, 7 insertions(+), 16 deletions(-)
include/linux/irqdomain.h +7 -16
@@ -445,9 +445,8 @@ static inline struct irq_domain *irq_domain_add_linear(struct device_node *of_no .ops = ops, .host_data = host_data, }; -struct irq_domain *d; +struct irq_domain *d =irq_domain_instantiate (&info); - d =irq_domain_instantiate (&info);return IS_ERR (d) ?NULL : d; }
@@ -464,9 +463,8 @@ static inline struct irq_domain *irq_domain_add_nomap(struct device_node *of_nod .ops = ops, .host_data = host_data, }; -struct irq_domain *d; +struct irq_domain *d =irq_domain_instantiate (&info); - d =irq_domain_instantiate (&info);return IS_ERR (d) ?NULL : d; }
@@ -483,9 +481,8 @@ static inline struct irq_domain *irq_domain_add_tree(struct device_node *of_node .ops = ops, .host_data = host_data, }; -struct irq_domain *d; +struct irq_domain *d =irq_domain_instantiate (&info); - d =irq_domain_instantiate (&info);return IS_ERR (d) ?NULL : d; }
@@ -501,9 +498,8 @@ static inline struct irq_domain *irq_domain_create_linear(struct fwnode_handle * .ops = ops, .host_data = host_data, }; -struct irq_domain *d; +struct irq_domain *d =irq_domain_instantiate (&info); - d =irq_domain_instantiate (&info);return IS_ERR (d) ?NULL : d; }
@@ -517,9 +513,8 @@ static inline struct irq_domain *irq_domain_create_tree(struct fwnode_handle *fw .ops = ops, .host_data = host_data, }; -struct irq_domain *d; +struct irq_domain *d =irq_domain_instantiate (&info); - d =irq_domain_instantiate (&info);return IS_ERR (d) ?NULL : d; }
@@ -637,18 +632,14 @@ static inline struct irq_domain *irq_domain_create_hierarchy(struct irq_domain *struct irq_domain_info info = { .fwnode = fwnode, .size = size, - .hwirq_max = size, + .hwirq_max = size ? : ~0U , .ops = ops, .host_data = host_data, .domain_flags = flags, .parent = parent, }; -struct irq_domain *d; - -if (!info.size) - info.hwirq_max = ~0U ; +struct irq_domain *d =irq_domain_instantiate (&info); - d =irq_domain_instantiate (&info);return IS_ERR (d) ?NULL : d; }
Signature · 1 line
2.48.0
PATCH 8/18 irqdomain: Make struct irq_domain_info variables const
In reply to Jiri Slaby (SUSE)This is just expressing it explicitly as irq_domain_instantiate() takes const already. No functional change.
--- include/linux/irqdomain.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
include/linux/irqdomain.h +6 -6
@@ -438,7 +438,7 @@ static inline struct irq_domain *irq_domain_add_linear(struct device_node *of_no const struct irq_domain_ops *ops, void *host_data) { - struct irq_domain_info info = { + const struct irq_domain_info info = { .fwnode = of_fwnode_handle(of_node), .size = size, .hwirq_max = size,
@@ -456,7 +456,7 @@ static inline struct irq_domain *irq_domain_add_nomap(struct device_node *of_nod const struct irq_domain_ops *ops, void *host_data) { - struct irq_domain_info info = { + const struct irq_domain_info info = { .fwnode = of_fwnode_handle(of_node), .hwirq_max = max_irq, .direct_max = max_irq,
@@ -475,7 +475,7 @@ static inline struct irq_domain *irq_domain_add_tree(struct device_node *of_node const struct irq_domain_ops *ops, void *host_data) { - struct irq_domain_info info = { + const struct irq_domain_info info = { .fwnode = of_fwnode_handle(of_node), .hwirq_max = ~0U, .ops = ops,
@@ -491,7 +491,7 @@ static inline struct irq_domain *irq_domain_create_linear(struct fwnode_handle * const struct irq_domain_ops *ops, void *host_data) { - struct irq_domain_info info = { + const struct irq_domain_info info = { .fwnode = fwnode, .size = size, .hwirq_max = size,
@@ -507,7 +507,7 @@ static inline struct irq_domain *irq_domain_create_tree(struct fwnode_handle *fw const struct irq_domain_ops *ops, void *host_data) { - struct irq_domain_info info = { + const struct irq_domain_info info = { .fwnode = fwnode, .hwirq_max = ~0, .ops = ops,
@@ -629,7 +629,7 @@ static inline struct irq_domain *irq_domain_create_hierarchy(struct irq_domain * const struct irq_domain_ops *ops, void *host_data) { - struct irq_domain_info info = { + const struct irq_domain_info info = { .fwnode = fwnode, .size = size, .hwirq_max = size ? : ~0U,
Signature · 1 line
2.48.0
PATCH 9/18 irqdomain: Rename _add functions to _add_*_of_node
In reply to Jiri Slaby (SUSE)For readers, it is very confusing that:
* irq_domain_add_*() functions are dedicated to of_nodes,
* irq_domain_create_*() ones to fwnodes, and
* irq_domain_instantiate() to the universal struct irq_domain_info.
Neither _create, nor _add designate any of those nodes. Despite the naming, the functionality of them is the same: add an irq domain (by generic irq_domain_instantiate()). So the source of the confusion is the naming proper -- making the distinction based on _create, _add, and _instantiate.
Therefore, here an "_of_node" suffix is added to all "_add" functions (of_node ones). In the next patch, "_create" (fwnode ones) are switched to "_add_fwnode". And finally, "_instantiate" is renamed to "_add".
So when all are applied, the interface is much easier to follow:
* dom = irq_domain_add_linear_of_node(of_node, ...)
* dom = irq_domain_add_linear_fwnode(fwnode, ...)
* dom = irq_domain_add(info)
* irq_domain_remove(dom)
---
Note 1: I completely do not insist on these patches, but when I came as the first time reader, these occured to me as big misnomers.
Note 2: irq_domain_add() might have been irq_domain_add_info() as well. That would make it consistent among the others. Opinions?
--- Documentation/core-api/irq/irq-domain.rst | 62 ++++++++++--------- .../zh_CN/core-api/irq/irq-domain.rst | 24 +++---- arch/arc/kernel/intc-arcv2.c | 2 +- arch/arc/kernel/intc-compact.c | 2 +- arch/arc/kernel/mcip.c | 2 +- arch/arm/common/sa1111.c | 2 +- arch/arm/mach-exynos/suspend.c | 2 +- arch/arm/mach-imx/avic.c | 2 +- arch/arm/mach-imx/gpc.c | 2 +- arch/arm/mach-imx/tzic.c | 2 +- arch/arm/mach-omap1/irq.c | 2 +- arch/arm/mach-omap2/omap-wakeupgen.c | 2 +- arch/arm/mach-pxa/irq.c | 2 +- arch/arm/plat-orion/gpio.c | 2 +- arch/mips/ath25/ar2315.c | 2 +- arch/mips/ath25/ar5312.c | 2 +- arch/mips/cavium-octeon/octeon-irq.c | 12 ++-- arch/mips/lantiq/irq.c | 2 +- arch/mips/pci/pci-ar2315.c | 2 +- arch/mips/pci/pci-rt3883.c | 2 +- arch/mips/ralink/irq.c | 2 +- arch/nios2/kernel/irq.c | 2 +- arch/powerpc/platforms/44x/uic.c | 2 +- .../powerpc/platforms/512x/mpc5121_ads_cpld.c | 2 +- arch/powerpc/platforms/52xx/media5200.c | 2 +- arch/powerpc/platforms/52xx/mpc52xx_gpt.c | 4 +- arch/powerpc/platforms/52xx/mpc52xx_pic.c | 2 +- .../platforms/85xx/socrates_fpga_pic.c | 2 +- arch/powerpc/platforms/8xx/cpm1-ic.c | 2 +- arch/powerpc/platforms/8xx/pic.c | 2 +- arch/powerpc/platforms/cell/axon_msi.c | 2 +- arch/powerpc/platforms/cell/interrupt.c | 2 +- arch/powerpc/platforms/cell/spider-pic.c | 2 +- .../platforms/embedded6xx/flipper-pic.c | 2 +- arch/powerpc/platforms/embedded6xx/hlwd-pic.c | 2 +- arch/powerpc/platforms/powermac/pic.c | 2 +- arch/powerpc/platforms/powermac/smp.c | 2 +- arch/powerpc/platforms/powernv/opal-irqchip.c | 2 +- arch/powerpc/platforms/ps3/interrupt.c | 2 +- arch/powerpc/sysdev/cpm2_pic.c | 2 +- arch/powerpc/sysdev/ehv_pic.c | 2 +- arch/powerpc/sysdev/fsl_msi.c | 2 +- arch/powerpc/sysdev/ge/ge_pic.c | 2 +- arch/powerpc/sysdev/i8259.c | 2 +- arch/powerpc/sysdev/ipic.c | 2 +- arch/powerpc/sysdev/mpic.c | 2 +- arch/powerpc/sysdev/tsi108_pci.c | 2 +- arch/powerpc/sysdev/xive/common.c | 2 +- arch/sh/boards/mach-se/7343/irq.c | 2 +- arch/sh/boards/mach-se/7722/irq.c | 2 +- arch/sh/boards/mach-x3proto/gpio.c | 2 +- drivers/bus/moxtet.c | 2 +- drivers/edac/altera_edac.c | 2 +- drivers/gpio/gpio-brcmstb.c | 2 +- drivers/gpio/gpio-davinci.c | 2 +- drivers/gpio/gpio-em.c | 2 +- drivers/gpio/gpio-grgpio.c | 2 +- drivers/gpio/gpio-lpc18xx.c | 2 +- drivers/gpio/gpio-mvebu.c | 2 +- drivers/gpio/gpio-mxc.c | 2 +- drivers/gpio/gpio-mxs.c | 2 +- drivers/gpio/gpio-pxa.c | 2 +- drivers/gpio/gpio-rockchip.c | 2 +- drivers/gpio/gpio-sa1100.c | 2 +- drivers/gpio/gpio-sodaville.c | 2 +- drivers/gpio/gpio-tb10x.c | 2 +- drivers/gpio/gpio-twl4030.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c | 2 +- drivers/gpu/drm/msm/msm_mdss.c | 2 +- drivers/gpu/ipu-v3/ipu-common.c | 2 +- drivers/i2c/busses/i2c-cht-wc.c | 2 +- drivers/i2c/muxes/i2c-mux-pca954x.c | 2 +- drivers/iio/adc/stm32-adc-core.c | 2 +- drivers/irqchip/exynos-combiner.c | 2 +- drivers/irqchip/irq-al-fic.c | 2 +- drivers/irqchip/irq-alpine-msi.c | 2 +- drivers/irqchip/irq-armada-370-xp.c | 4 +- drivers/irqchip/irq-aspeed-i2c-ic.c | 2 +- drivers/irqchip/irq-aspeed-intc.c | 2 +- drivers/irqchip/irq-aspeed-scu-ic.c | 2 +- drivers/irqchip/irq-aspeed-vic.c | 2 +- drivers/irqchip/irq-ath79-misc.c | 4 +- drivers/irqchip/irq-atmel-aic-common.c | 2 +- drivers/irqchip/irq-bcm2835.c | 2 +- drivers/irqchip/irq-bcm2836.c | 2 +- drivers/irqchip/irq-bcm6345-l1.c | 2 +- drivers/irqchip/irq-bcm7038-l1.c | 2 +- drivers/irqchip/irq-bcm7120-l2.c | 2 +- drivers/irqchip/irq-brcmstb-l2.c | 2 +- drivers/irqchip/irq-clps711x.c | 2 +- drivers/irqchip/irq-crossbar.c | 2 +- drivers/irqchip/irq-csky-apb-intc.c | 2 +- drivers/irqchip/irq-csky-mpintc.c | 2 +- drivers/irqchip/irq-davinci-cp-intc.c | 2 +- drivers/irqchip/irq-digicolor.c | 2 +- drivers/irqchip/irq-dw-apb-ictl.c | 2 +- drivers/irqchip/irq-ftintc010.c | 2 +- drivers/irqchip/irq-goldfish-pic.c | 2 +- drivers/irqchip/irq-hip04.c | 2 +- drivers/irqchip/irq-i8259.c | 2 +- drivers/irqchip/irq-idt3243x.c | 2 +- drivers/irqchip/irq-imgpdc.c | 2 +- drivers/irqchip/irq-imx-gpcv2.c | 2 +- drivers/irqchip/irq-imx-intmux.c | 2 +- drivers/irqchip/irq-imx-irqsteer.c | 2 +- drivers/irqchip/irq-ingenic-tcu.c | 2 +- drivers/irqchip/irq-ingenic.c | 2 +- drivers/irqchip/irq-jcore-aic.c | 2 +- drivers/irqchip/irq-keystone.c | 2 +- drivers/irqchip/irq-lpc32xx.c | 2 +- drivers/irqchip/irq-ls-extirq.c | 2 +- drivers/irqchip/irq-ls-scfg-msi.c | 2 +- drivers/irqchip/irq-ls1x.c | 2 +- drivers/irqchip/irq-mchp-eic.c | 2 +- drivers/irqchip/irq-mips-cpu.c | 4 +- drivers/irqchip/irq-mips-gic.c | 4 +- drivers/irqchip/irq-mmp.c | 4 +- drivers/irqchip/irq-mscc-ocelot.c | 2 +- drivers/irqchip/irq-mst-intc.c | 2 +- drivers/irqchip/irq-mtk-cirq.c | 2 +- drivers/irqchip/irq-mtk-sysirq.c | 2 +- drivers/irqchip/irq-mvebu-pic.c | 2 +- drivers/irqchip/irq-mxs.c | 2 +- drivers/irqchip/irq-nvic.c | 2 +- drivers/irqchip/irq-omap-intc.c | 4 +- drivers/irqchip/irq-or1k-pic.c | 2 +- drivers/irqchip/irq-orion.c | 4 +- drivers/irqchip/irq-owl-sirq.c | 2 +- drivers/irqchip/irq-pic32-evic.c | 2 +- drivers/irqchip/irq-pruss-intc.c | 2 +- drivers/irqchip/irq-realtek-rtl.c | 2 +- drivers/irqchip/irq-renesas-intc-irqpin.c | 2 +- drivers/irqchip/irq-renesas-irqc.c | 2 +- drivers/irqchip/irq-renesas-rza1.c | 2 +- drivers/irqchip/irq-renesas-rzg2l.c | 2 +- drivers/irqchip/irq-renesas-rzv2h.c | 2 +- drivers/irqchip/irq-sa11x0.c | 2 +- drivers/irqchip/irq-sni-exiu.c | 2 +- drivers/irqchip/irq-sp7021-intc.c | 2 +- drivers/irqchip/irq-starfive-jh8100-intc.c | 2 +- drivers/irqchip/irq-stm32-exti.c | 2 +- drivers/irqchip/irq-stm32mp-exti.c | 2 +- drivers/irqchip/irq-sun4i.c | 2 +- drivers/irqchip/irq-sun6i-r.c | 2 +- drivers/irqchip/irq-sunxi-nmi.c | 2 +- drivers/irqchip/irq-tb10x.c | 2 +- drivers/irqchip/irq-tegra.c | 2 +- drivers/irqchip/irq-ti-sci-inta.c | 2 +- drivers/irqchip/irq-ti-sci-intr.c | 2 +- drivers/irqchip/irq-ts4800.c | 2 +- drivers/irqchip/irq-versatile-fpga.c | 2 +- drivers/irqchip/irq-vf610-mscm-ir.c | 2 +- drivers/irqchip/irq-vic.c | 2 +- drivers/irqchip/irq-vt8500.c | 2 +- drivers/irqchip/irq-wpcm450-aic.c | 2 +- drivers/irqchip/irq-xilinx-intc.c | 2 +- drivers/irqchip/irq-xtensa-mx.c | 4 +- drivers/irqchip/irq-xtensa-pic.c | 4 +- drivers/irqchip/irq-zevio.c | 2 +- drivers/irqchip/spear-shirq.c | 2 +- drivers/mailbox/qcom-ipcc.c | 2 +- drivers/memory/omap-gpmc.c | 2 +- drivers/mfd/88pm860x-core.c | 2 +- drivers/mfd/ab8500-core.c | 2 +- drivers/mfd/arizona-irq.c | 2 +- drivers/mfd/db8500-prcmu.c | 2 +- drivers/mfd/fsl-imx25-tsadc.c | 2 +- drivers/mfd/lp8788-irq.c | 2 +- drivers/mfd/max8925-core.c | 2 +- drivers/mfd/max8997-irq.c | 2 +- drivers/mfd/max8998-irq.c | 2 +- drivers/mfd/mt6358-irq.c | 2 +- drivers/mfd/mt6397-irq.c | 2 +- drivers/mfd/qcom-pm8xxx.c | 2 +- drivers/mfd/stmfx.c | 2 +- drivers/mfd/stmpe.c | 2 +- drivers/mfd/tc3589x.c | 2 +- drivers/mfd/tps65217.c | 2 +- drivers/mfd/tps6586x.c | 2 +- drivers/mfd/twl4030-irq.c | 2 +- drivers/mfd/twl6030-irq.c | 2 +- drivers/mfd/wm831x-irq.c | 4 +- drivers/mfd/wm8994-irq.c | 2 +- drivers/misc/hi6421v600-irq.c | 2 +- drivers/net/dsa/microchip/ksz_common.c | 2 +- drivers/net/dsa/microchip/ksz_ptp.c | 2 +- drivers/net/dsa/mt7530.c | 4 +- drivers/net/dsa/mv88e6xxx/chip.c | 2 +- drivers/net/dsa/mv88e6xxx/global2.c | 2 +- drivers/net/dsa/qca/ar9331.c | 2 +- drivers/net/dsa/realtek/rtl8365mb.c | 2 +- drivers/net/dsa/realtek/rtl8366rb.c | 2 +- .../net/ethernet/wangxun/txgbe/txgbe_irq.c | 2 +- drivers/net/usb/lan78xx.c | 2 +- drivers/pci/controller/dwc/pci-dra7xx.c | 2 +- drivers/pci/controller/dwc/pci-keystone.c | 2 +- drivers/pci/controller/dwc/pcie-dw-rockchip.c | 2 +- drivers/pci/controller/dwc/pcie-uniphier.c | 2 +- .../controller/mobiveil/pcie-mobiveil-host.c | 4 +- drivers/pci/controller/pci-aardvark.c | 6 +- drivers/pci/controller/pci-ftpci100.c | 2 +- drivers/pci/controller/pci-mvebu.c | 2 +- drivers/pci/controller/pci-xgene-msi.c | 2 +- drivers/pci/controller/pcie-altera-msi.c | 2 +- drivers/pci/controller/pcie-altera.c | 2 +- drivers/pci/controller/pcie-brcmstb.c | 2 +- drivers/pci/controller/pcie-iproc-msi.c | 2 +- drivers/pci/controller/pcie-mediatek-gen3.c | 4 +- drivers/pci/controller/pcie-mediatek.c | 2 +- drivers/pci/controller/pcie-rockchip-host.c | 2 +- drivers/pci/controller/pcie-xilinx-cpm.c | 4 +- drivers/pci/controller/pcie-xilinx-dma-pl.c | 6 +- drivers/pci/controller/pcie-xilinx-nwl.c | 4 +- drivers/pci/controller/pcie-xilinx.c | 2 +- drivers/pci/controller/plda/pcie-plda-host.c | 6 +- drivers/pinctrl/mediatek/mtk-eint.c | 2 +- drivers/pinctrl/pinctrl-at91-pio4.c | 2 +- drivers/pinctrl/pinctrl-single.c | 4 +- drivers/pinctrl/sunxi/pinctrl-sunxi.c | 2 +- drivers/platform/x86/asus-tf103c-dock.c | 2 +- drivers/sh/intc/irqdomain.c | 4 +- drivers/soc/dove/pmu.c | 2 +- drivers/soc/fsl/qe/qe_ic.c | 2 +- drivers/soc/qcom/smp2p.c | 2 +- drivers/soc/qcom/smsm.c | 2 +- drivers/soc/tegra/pmc.c | 2 +- drivers/spmi/spmi-pmic-arb.c | 2 +- drivers/ssb/driver_gpio.c | 4 +- drivers/thermal/qcom/lmh.c | 2 +- drivers/thermal/tegra/soctherm.c | 2 +- include/linux/gpio/driver.h | 2 +- include/linux/irqdomain.h | 16 ++--- sound/soc/codecs/wcd937x.c | 2 +- sound/soc/codecs/wcd938x.c | 2 +- sound/soc/codecs/wcd939x.c | 2 +- 235 files changed, 316 insertions(+), 310 deletions(-)
Documentation/core-api/irq/irq-domain.rst +34 -28
@@ -42,10 +42,11 @@ irq_domain usage ================ An interrupt controller driver creates and registers an irq_domain by -calling one of the irq_domain_add_*() or irq_domain_create_*() functions -(each mapping method has a different allocator function, more on that later). -The function will return a pointer to the irq_domain on success. The caller -must provide the allocator function with an irq_domain_ops structure. +calling one of the irq_domain_add_*_of_node() or irq_domain_create_*() +functions (each mapping method has a different allocator function, +more on that later). The function will return a pointer to the +irq_domain on success. The caller must provide the allocator function +with an irq_domain_ops structure. In most cases, the irq_domain will begin empty without any mappings between hwirq and IRQ numbers. Mappings are added to the irq_domain
@@ -92,7 +93,7 @@ Linear :: - irq_domain_add_linear() + irq_domain_add_linear_of_node() irq_domain_create_linear() The linear reverse map maintains a fixed size table indexed by the
@@ -105,10 +106,11 @@ map are fixed time lookup for IRQ numbers, and irq_descs are only allocated for in-use IRQs. The disadvantage is that the table must be as large as the largest possible hwirq number. -irq_domain_add_linear() and irq_domain_create_linear() are functionally -equivalent, except for the first argument is different - the former -accepts an Open Firmware specific 'struct device_node', while the latter -accepts a more general abstraction 'struct fwnode_handle'. +irq_domain_add_linear_of_node() and irq_domain_create_linear() are +functionally equivalent, except for the first argument is different - +the former accepts an Open Firmware specific 'struct device_node', +while the latter accepts a more general abstraction 'struct +fwnode_handle'. The majority of drivers should use the linear map.
@@ -117,7 +119,7 @@ Tree :: - irq_domain_add_tree() + irq_domain_add_tree_of_node() irq_domain_create_tree() The irq_domain maintains a radix tree map from hwirq numbers to Linux
@@ -129,10 +131,11 @@ since it doesn't need to allocate a table as large as the largest hwirq number. The disadvantage is that hwirq to IRQ number lookup is dependent on how many entries are in the table. -irq_domain_add_tree() and irq_domain_create_tree() are functionally -equivalent, except for the first argument is different - the former -accepts an Open Firmware specific 'struct device_node', while the latter -accepts a more general abstraction 'struct fwnode_handle'. +irq_domain_add_tree_of_node() and irq_domain_create_tree() are +functionally equivalent, except for the first argument is different - +the former accepts an Open Firmware specific 'struct device_node', +while the latter accepts a more general abstraction 'struct +fwnode_handle'. Very few drivers should need this mapping.
@@ -141,7 +144,7 @@ No Map :: - irq_domain_add_nomap() + irq_domain_add_nomap_of_node() The No Map mapping is to be used when the hwirq number is programmable in the hardware. In this case it is best to program the
@@ -159,8 +162,8 @@ Legacy :: - irq_domain_add_simple() - irq_domain_add_legacy() + irq_domain_add_simple_of_node() + irq_domain_add_legacy_of_node() irq_domain_create_simple() irq_domain_create_legacy()
@@ -189,13 +192,15 @@ supported. For example, ISA controllers would use the legacy map for mapping Linux IRQs 0-15 so that existing ISA drivers get the correct IRQ numbers. -Most users of legacy mappings should use irq_domain_add_simple() or -irq_domain_create_simple() which will use a legacy domain only if an IRQ range -is supplied by the system and will otherwise use a linear domain mapping. -The semantics of this call are such that if an IRQ range is specified then +Most users of legacy mappings should use +irq_domain_add_simple_of_node() or irq_domain_create_simple() which +will use a legacy domain only if an IRQ range is supplied by the +system and will otherwise use a linear domain mapping. The semantics +of this call are such that if an IRQ range is specified then descriptors will be allocated on-the-fly for it, and if no range is -specified it will fall through to irq_domain_add_linear() or -irq_domain_create_linear() which means *no* irq descriptors will be allocated. +specified it will fall through to irq_domain_add_linear_of_node() or +irq_domain_create_linear() which means *no* irq descriptors will be +allocated. A typical use case for simple domains is where an irqchip provider is supporting both dynamic and static IRQ assignments.
@@ -206,11 +211,12 @@ that the driver using the simple domain call irq_create_mapping() before any irq_find_mapping() since the latter will actually work for the static IRQ assignment case. -irq_domain_add_simple() and irq_domain_create_simple() as well as -irq_domain_add_legacy() and irq_domain_create_legacy() are functionally -equivalent, except for the first argument is different - the former -accepts an Open Firmware specific 'struct device_node', while the latter -accepts a more general abstraction 'struct fwnode_handle'. +irq_domain_add_simple_of_node() and irq_domain_create_simple() as well +as irq_domain_add_legacy_of_node() and irq_domain_create_legacy() are +functionally equivalent, except for the first argument is different - +the former accepts an Open Firmware specific 'struct device_node', +while the latter accepts a more general abstraction 'struct +fwnode_handle'. Hierarchy IRQ domain --------------------
Documentation/translations/zh_CN/core-api/irq/irq-domain.rst +12 -12
@@ -43,7 +43,7 @@ irq_domain的用法 ================ 中断控制器驱动程序通过以下方式创建并注册一个irq_domain。调用 -irq_domain_add_*() 或 irq_domain_create_*()函数之一(每个映射方法都有不 +irq_domain_add_*_of_node() 或 irq_domain_create_*()函数之一(每个映射方法都有不 同的分配器函数,后面会详细介绍)。 函数成功后会返回一个指向irq_domain的指针。 调用者必须向分配器函数提供一个irq_domain_ops结构体。
@@ -83,7 +83,7 @@ irq_domain映射的类型 :: - irq_domain_add_linear() + irq_domain_add_linear_of_node() irq_domain_create_linear() 线性反向映射维护了一个固定大小的表,该表以hwirq号为索引。 当一个hwirq被映射
@@ -93,7 +93,7 @@ irq_domain映射的类型 映射的优点是固定时间查找IRQ号,而且irq_descs只分配给在用的IRQ。 缺点是该表 必须尽可能大的hwirq号。 -irq_domain_add_linear()和irq_domain_create_linear()在功能上是等价的, +irq_domain_add_linear_of_node()和irq_domain_create_linear()在功能上是等价的, 除了第一个参数不同--前者接受一个Open Firmware特定的 'struct device_node' 而 后者接受一个更通用的抽象 'struct fwnode_handle' 。
@@ -104,7 +104,7 @@ irq_domain_add_linear()和irq_domain_create_linear()在功能上是等价的, :: - irq_domain_add_tree() + irq_domain_add_tree_of_node() irq_domain_create_tree() irq_domain维护着从hwirq号到Linux IRQ的radix的树状映射。 当一个hwirq被映射时,
@@ -113,7 +113,7 @@ irq_domain维护着从hwirq号到Linux IRQ的radix的树状映射。 当一个hw 如果hwirq号可以非常大,树状映射是一个很好的选择,因为它不需要分配一个和最大hwirq 号一样大的表。 缺点是,hwirq到IRQ号的查找取决于表中有多少条目。 -irq_domain_add_tree()和irq_domain_create_tree()在功能上是等价的,除了第一 +irq_domain_add_tree_of_node()和irq_domain_create_tree()在功能上是等价的,除了第一 个参数不同——前者接受一个Open Firmware特定的 'struct device_node' ,而后者接受 一个更通用的抽象 'struct fwnode_handle' 。
@@ -124,7 +124,7 @@ irq_domain_add_tree()和irq_domain_create_tree()在功能上是等价的,除 :: - irq_domain_add_nomap() + irq_domain_add_nomap_of_node() 当硬件中的hwirq号是可编程的时候,就可以采用无映射类型。 在这种情况下,最好将 Linux IRQ号编入硬件本身,这样就不需要映射了。 调用irq_create_direct_mapping()
@@ -138,8 +138,8 @@ Linux IRQ号编入硬件本身,这样就不需要映射了。 调用irq_create :: - irq_domain_add_simple() - irq_domain_add_legacy() + irq_domain_add_simple_of_node() + irq_domain_add_legacy_of_node() irq_domain_create_simple() irq_domain_create_legacy()
@@ -158,10 +158,10 @@ Linux IRQ号编入硬件本身,这样就不需要映射了。 调用irq_create 只有在必须支持固定的IRQ映射时,才应使用传统映射。 例如,ISA控制器将使用传统映射来 映射Linux IRQ 0-15,这样现有的ISA驱动程序就能得到正确的IRQ号。 -大多数使用传统映射的用户应该使用irq_domain_add_simple()或 +大多数使用传统映射的用户应该使用irq_domain_add_simple_of_node()或 irq_domain_create_simple(),只有在系统提供IRQ范围时才会使用传统域,否则将使用 线性域映射。这个调用的语义是这样的:如果指定了一个IRQ范围,那么 描述符将被即时分配 -给它,如果没有范围被分配,它将不会执行 irq_domain_add_linear() 或 +给它,如果没有范围被分配,它将不会执行 irq_domain_add_linear_of_node() 或 irq_domain_create_linear(),这意味着 *no* irq 描述符将被分配。 一个简单域的典型用例是,irqchip供应商同时支持动态和静态IRQ分配。
@@ -170,8 +170,8 @@ irq_domain_create_linear(),这意味着 *no* irq 描述符将被分配。 irq_find_mapping()之前调用irq_create_mapping()是非常重要的,因为后者实际上 将用于静态IRQ分配情况。 -irq_domain_add_simple()和irq_domain_create_simple()以及 -irq_domain_add_legacy()和irq_domain_create_legacy()在功能上是等价的,只 +irq_domain_add_simple_of_node()和irq_domain_create_simple()以及 +irq_domain_add_legacy_of_node()和irq_domain_create_legacy()在功能上是等价的,只 是第一个参数不同--前者接受Open Firmware特定的 'struct device_node' ,而后者 接受一个更通用的抽象 'struct fwnode_handle' 。
arch/arc/kernel/intc-arcv2.c +1 -1
@@ -170,7 +170,7 @@ init_onchip_IRQ(struct device_node *intc, struct device_node *parent)if (parent)panic ("DeviceTree incore intc not a root irq controller\n" ); - root_domain =irq_domain_add_linear (intc, nr_cpu_irqs, &arcv2_irq_ops,NULL ); + root_domain =irq_domain_add_linear_of_node (intc, nr_cpu_irqs, &arcv2_irq_ops,NULL );if (!root_domain)panic ("root irq domain not avail\n" );
arch/arc/kernel/intc-compact.c +1 -1
@@ -112,7 +112,7 @@ init_onchip_IRQ(struct device_node *intc, struct device_node *parent)if (parent)panic ("DeviceTree incore intc not a root irq controller\n" ); - root_domain =irq_domain_add_linear (intc,NR_CPU_IRQS , + root_domain =irq_domain_add_linear_of_node (intc,NR_CPU_IRQS , &arc_intc_domain_ops,NULL );if (!root_domain)panic ("root irq domain not avail\n" );
arch/arc/kernel/mcip.c +1 -1
@@ -393,7 +393,7 @@ idu_of_init(struct device_node *intc, struct device_node *parent)pr_info ("MCIP: IDU supports %u common irqs\n" , nr_irqs); - domain =irq_domain_add_linear (intc, nr_irqs, &idu_irq_ops,NULL ); + domain =irq_domain_add_linear_of_node (intc, nr_irqs, &idu_irq_ops,NULL );/* Parent interrupts (core-intc) are already mapped */
arch/arm/common/sa1111.c +1 -1
@@ -416,7 +416,7 @@ static int sa1111_setup_irq(struct sa1111 *sachip, unsigned irq_base)writel_relaxed (~0 , irqbase +SA1111_INTSTATCLR0 );writel_relaxed (~0 , irqbase +SA1111_INTSTATCLR1 ); - sachip->irqdomain =irq_domain_add_linear (NULL ,SA1111_IRQ_NR , + sachip->irqdomain =irq_domain_add_linear_of_node (NULL ,SA1111_IRQ_NR , &sa1111_irqdomain_ops, sachip);if (!sachip->irqdomain) {
arch/arm/mach-exynos/suspend.c +1 -1
@@ -209,7 +209,7 @@ static int __init exynos_pmu_irq_init(struct device_node *node,return -ENOMEM ; } - domain =irq_domain_add_hierarchy (parent_domain,0 ,0 , + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 ,0 , node, &exynos_pmu_domain_ops,NULL );if (!domain) {
arch/arm/mach-imx/avic.c +1 -1
@@ -201,7 +201,7 @@ static void __init mxc_init_irq(void __iomem *irqbase)WARN_ON (irq_base <0 ); np =of_find_compatible_node (NULL ,NULL ,"fsl,avic" ); - domain =irq_domain_add_legacy (np,AVIC_NUM_IRQS , irq_base,0 , + domain =irq_domain_add_legacy_of_node (np,AVIC_NUM_IRQS , irq_base,0 , &irq_domain_simple_ops,NULL );WARN_ON (!domain);
arch/arm/mach-imx/gpc.c +1 -1
@@ -245,7 +245,7 @@ static int __init imx_gpc_init(struct device_node *node,if (WARN_ON (!gpc_base))return -ENOMEM ; - domain =irq_domain_add_hierarchy (parent_domain,0 ,GPC_MAX_IRQS , + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 ,GPC_MAX_IRQS , node, &imx_gpc_domain_ops,NULL );if (!domain) {
arch/arm/mach-imx/tzic.c +1 -1
@@ -175,7 +175,7 @@ static int __init tzic_init_dt(struct device_node *np, struct device_node *p) irq_base =irq_alloc_descs (-1 ,0 ,TZIC_NUM_IRQS ,numa_node_id ());WARN_ON (irq_base <0 ); - domain =irq_domain_add_legacy (np,TZIC_NUM_IRQS , irq_base,0 , + domain =irq_domain_add_legacy_of_node (np,TZIC_NUM_IRQS , irq_base,0 , &irq_domain_simple_ops,NULL );WARN_ON (!domain);
arch/arm/mach-omap1/irq.c +1 -1
@@ -220,7 +220,7 @@ void __init omap1_init_irq(void) omap_l2_irq = irq_base; omap_l2_irq -=NR_IRQS_LEGACY ; - domain =irq_domain_add_legacy (NULL , nr_irqs, irq_base,0 , + domain =irq_domain_add_legacy_of_node (NULL , nr_irqs, irq_base,0 , &irq_domain_simple_ops,NULL ); pr_info("Total of %lu interrupts in %i interrupt banks\n",
arch/arm/mach-omap2/omap-wakeupgen.c +1 -1
@@ -585,7 +585,7 @@ static int __init wakeupgen_init(struct device_node *node, wakeupgen_ops = &am43xx_wakeupgen_ops; } - domain =irq_domain_add_hierarchy (parent_domain,0 , max_irqs, + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 , max_irqs, node, &wakeupgen_domain_ops,NULL );if (!domain) {
arch/arm/mach-pxa/irq.c +1 -1
@@ -147,7 +147,7 @@ pxa_init_irq_common(struct device_node *node, int irq_nr,int n; pxa_internal_irq_nr = irq_nr; - pxa_irq_domain =irq_domain_add_legacy (node, irq_nr, + pxa_irq_domain =irq_domain_add_legacy_of_node (node, irq_nr,PXA_IRQ (0 ),0 , &pxa_irq_ops,NULL );if (!pxa_irq_domain)
arch/arm/plat-orion/gpio.c +1 -1
@@ -602,7 +602,7 @@ void __init orion_gpio_init(int gpio_base, int ngpio, IRQ_NOREQUEST, IRQ_LEVEL | IRQ_NOPROBE);/* Setup irq domain on top of the generic chip. */ - ochip->domain = irq_domain_add_legacy(NULL, + ochip->domain = irq_domain_add_legacy_of_node(NULL, ochip->chip.ngpio, ochip->secondary_irq_base, ochip->secondary_irq_base,
arch/mips/ath25/ar2315.c +1 -1
@@ -149,7 +149,7 @@ void __init ar2315_arch_init_irq(void) ath25_irq_dispatch = ar2315_irq_dispatch; - domain =irq_domain_add_linear (NULL ,AR2315_MISC_IRQ_COUNT , + domain =irq_domain_add_linear_of_node (NULL ,AR2315_MISC_IRQ_COUNT , &ar2315_misc_irq_domain_ops,NULL );if (!domain)panic ("Failed to add IRQ domain" );
arch/mips/ath25/ar5312.c +1 -1
@@ -143,7 +143,7 @@ void __init ar5312_arch_init_irq(void) ath25_irq_dispatch = ar5312_irq_dispatch; - domain =irq_domain_add_linear (NULL ,AR5312_MISC_IRQ_COUNT , + domain =irq_domain_add_linear_of_node (NULL ,AR5312_MISC_IRQ_COUNT , &ar5312_misc_irq_domain_ops,NULL );if (!domain)panic ("Failed to add IRQ domain" );
arch/mips/cavium-octeon/octeon-irq.c +6 -6
@@ -1503,7 +1503,7 @@ static int __init octeon_irq_init_ciu(/* Mips internal */ octeon_irq_init_core (); - ciu_domain =irq_domain_add_tree ( + ciu_domain =irq_domain_add_tree_of_node ( ciu_node, &octeon_irq_domain_ciu_ops, dd);irq_set_default_domain (ciu_domain);
@@ -1637,7 +1637,7 @@ static int __init octeon_irq_init_gpio(if (gpiod) {/* gpio domain host_data is the base hwirq number. */ gpiod->base_hwirq = base_hwirq; -irq_domain_add_linear ( +irq_domain_add_linear_of_node ( gpio_node,16 , &octeon_irq_domain_gpio_ops, gpiod); }else {pr_warn ("Cannot allocate memory for GPIO irq_domain.\n" );
@@ -2074,7 +2074,7 @@ static int __init octeon_irq_init_ciu2(/* Mips internal */ octeon_irq_init_core (); - ciu_domain =irq_domain_add_tree ( + ciu_domain =irq_domain_add_tree_of_node ( ciu_node, &octeon_irq_domain_ciu2_ops,NULL );irq_set_default_domain (ciu_domain);
@@ -2331,11 +2331,11 @@ static int __init octeon_irq_init_cib(struct device_node *ciu_node, } host_data->max_bits = val; - cib_domain =irq_domain_add_linear (ciu_node, host_data->max_bits, + cib_domain =irq_domain_add_linear_of_node (ciu_node, host_data->max_bits, &octeon_irq_domain_cib_ops, host_data);if (!cib_domain) { -pr_err ("ERROR: Couldn't irq_domain_add_linear()\n" ); +pr_err ("ERROR: Couldn't irq_domain_add_linear_of_node()\n" );return -ENOMEM ; }
@@ -2918,7 +2918,7 @@ static int __init octeon_irq_init_ciu3(struct device_node *ciu_node,* Initialize all domains to use the default domain. Specific major * blocks will overwrite the default domain as needed. */ - domain =irq_domain_add_tree (ciu_node, &octeon_dflt_domain_ciu3_ops, + domain =irq_domain_add_tree_of_node (ciu_node, &octeon_dflt_domain_ciu3_ops, ciu3_info);for (i =0 ; i <MAX_CIU3_DOMAINS ; i++) ciu3_info->domain[i] = domain;
arch/mips/lantiq/irq.c +1 -1
@@ -377,7 +377,7 @@ int __init icu_of_init(struct device_node *node, struct device_node *parent)for (i =0 ; i <MAX_IM ; i++)irq_set_chained_handler (i +2 , ltq_hw_irq_handler); - ltq_domain =irq_domain_add_linear (node, + ltq_domain =irq_domain_add_linear_of_node (node, (MAX_IM *INT_NUM_IM_OFFSET ) +MIPS_CPU_IRQ_CASCADE , &irq_domain_ops,0 );
arch/mips/pci/pci-ar2315.c +1 -1
@@ -469,7 +469,7 @@ static int ar2315_pci_probe(struct platform_device *pdev)if (err)return err; - apc->domain =irq_domain_add_linear (NULL ,AR2315_PCI_IRQ_COUNT , + apc->domain =irq_domain_add_linear_of_node (NULL ,AR2315_PCI_IRQ_COUNT , &ar2315_pci_irq_domain_ops, apc);if (!apc->domain) {dev_err (dev,"failed to add IRQ domain\n" );
arch/mips/pci/pci-rt3883.c +1 -1
@@ -208,7 +208,7 @@ static int rt3883_pci_irq_init(struct device *dev,rt3883_pci_w32 (rpc,0 ,RT3883_PCI_REG_PCIENA ); rpc->irq_domain = -irq_domain_add_linear (rpc->intc_of_node,RT3883_PCI_IRQ_COUNT , +irq_domain_add_linear_of_node (rpc->intc_of_node,RT3883_PCI_IRQ_COUNT , &rt3883_pci_irq_domain_ops, rpc);if (!rpc->irq_domain) {
arch/mips/ralink/irq.c +1 -1
@@ -176,7 +176,7 @@ static int __init intc_of_init(struct device_node *node,/* route all INTC interrupts to MIPS HW0 interrupt */ rt_intc_w32 (0 ,INTC_REG_TYPE ); - domain =irq_domain_add_legacy (node,RALINK_INTC_IRQ_COUNT , + domain =irq_domain_add_legacy_of_node (node,RALINK_INTC_IRQ_COUNT ,RALINK_INTC_IRQ_BASE ,0 , &irq_domain_ops,NULL );if (!domain)panic ("Failed to add irqdomain" );
arch/nios2/kernel/irq.c +1 -1
@@ -69,7 +69,7 @@ void __init init_IRQ(void)BUG_ON (!node); - domain =irq_domain_add_linear (node,NIOS2_CPU_NR_IRQS , &irq_ops,NULL ); + domain =irq_domain_add_linear_of_node (node,NIOS2_CPU_NR_IRQS , &irq_ops,NULL );BUG_ON (!domain);irq_set_default_domain (domain);
arch/powerpc/platforms/44x/uic.c +1 -1
@@ -254,7 +254,7 @@ static struct uic * __init uic_init_one(struct device_node *node) } uic->dcrbase = *dcrreg; - uic->irqhost =irq_domain_add_linear (node,NR_UIC_INTS , &uic_host_ops, + uic->irqhost =irq_domain_add_linear_of_node (node,NR_UIC_INTS , &uic_host_ops, uic);if (! uic->irqhost)return NULL ;/* FIXME: panic? */
arch/powerpc/platforms/512x/mpc5121_ads_cpld.c +1 -1
@@ -188,7 +188,7 @@ mpc5121_ads_cpld_pic_init(void) cpld_pic_node =of_node_get (np); - cpld_pic_host =irq_domain_add_linear (np,16 , &cpld_pic_host_ops,NULL ); + cpld_pic_host =irq_domain_add_linear_of_node (np,16 , &cpld_pic_host_ops,NULL );if (!cpld_pic_host) {printk (KERN_ERR "CPLD PIC: failed to allocate irq host!\n" ); goto end;
arch/powerpc/platforms/52xx/media5200.c +1 -1
@@ -168,7 +168,7 @@ static void __init media5200_init_irq(void)spin_lock_init (&media5200_irq.lock); - media5200_irq.irqhost =irq_domain_add_linear (fpga_np, + media5200_irq.irqhost =irq_domain_add_linear_of_node (fpga_np,MEDIA5200_NUM_IRQS , &media5200_irq_ops, &media5200_irq);if (!media5200_irq.irqhost) goto out;
arch/powerpc/platforms/52xx/mpc52xx_gpt.c +2 -2
@@ -247,9 +247,9 @@ mpc52xx_gpt_irq_setup(struct mpc52xx_gpt_priv *gpt, struct device_node *node)if (!cascade_virq)return ; - gpt->irqhost =irq_domain_add_linear (node,1 , &mpc52xx_gpt_irq_ops, gpt); + gpt->irqhost =irq_domain_add_linear_of_node (node,1 , &mpc52xx_gpt_irq_ops, gpt);if (!gpt->irqhost) { -dev_err (gpt->dev,"irq_domain_add_linear() failed\n" ); +dev_err (gpt->dev,"irq_domain_add_linear_of_node() failed\n" );return ; }
arch/powerpc/platforms/52xx/mpc52xx_pic.c +1 -1
@@ -446,7 +446,7 @@ void __init mpc52xx_init_irq(void)* As last step, add an irq host to translate the real * hw irq information provided by the ofw to linux virq */ - mpc52xx_irqhost =irq_domain_add_linear (picnode, + mpc52xx_irqhost =irq_domain_add_linear_of_node (picnode, MPC52xx_IRQ_HIGHTESTHWIRQ, &mpc52xx_irqhost_ops,NULL );
arch/powerpc/platforms/85xx/socrates_fpga_pic.c +1 -1
@@ -278,7 +278,7 @@ void __init socrates_fpga_pic_init(struct device_node *pic)int i;/* Setup an irq_domain structure */ - socrates_fpga_pic_irq_host =irq_domain_add_linear (pic, + socrates_fpga_pic_irq_host =irq_domain_add_linear_of_node (pic,SOCRATES_FPGA_NUM_IRQS , &socrates_fpga_pic_host_ops,NULL );if (socrates_fpga_pic_irq_host ==NULL ) {pr_err ("FPGA PIC: Unable to allocate host\n" );
arch/powerpc/platforms/8xx/cpm1-ic.c +1 -1
@@ -110,7 +110,7 @@ static int cpm_pic_probe(struct platform_device *pdev)out_be32 (&data->reg->cpic_cimr,0 ); - data->host =irq_domain_add_linear (dev->of_node,64 , &cpm_pic_host_ops, data); + data->host =irq_domain_add_linear_of_node (dev->of_node,64 , &cpm_pic_host_ops, data);if (!data->host)return -ENODEV ;
arch/powerpc/platforms/8xx/pic.c +1 -1
@@ -146,7 +146,7 @@ void __init mpc8xx_pic_init(void)if (!siu_reg) goto out; - mpc8xx_pic_host =irq_domain_add_linear (np,64 , &mpc8xx_pic_host_ops,NULL ); + mpc8xx_pic_host =irq_domain_add_linear_of_node (np,64 , &mpc8xx_pic_host_ops,NULL );if (!mpc8xx_pic_host)printk (KERN_ERR "MPC8xx PIC: failed to allocate irq host!\n" );
arch/powerpc/platforms/cell/axon_msi.c +1 -1
@@ -376,7 +376,7 @@ static int axon_msi_probe(struct platform_device *device)memset (msic->fifo_virt,0xff ,MSIC_FIFO_SIZE_BYTES );/* We rely on being able to stash a virq in a u16, so limit irqs to < 65536 */ - msic->irq_domain =irq_domain_add_nomap (dn,65536 , &msic_host_ops, msic); + msic->irq_domain =irq_domain_add_nomap_of_node (dn,65536 , &msic_host_ops, msic);if (!msic->irq_domain) {printk (KERN_ERR "axon_msi: couldn't allocate irq_domain for %pOF\n" , dn);
arch/powerpc/platforms/cell/interrupt.c +1 -1
@@ -357,7 +357,7 @@ static int __init setup_iic(void)void __init iic_init_IRQ (void ) {/* Setup an irq host data structure */ - iic_host =irq_domain_add_linear (NULL ,IIC_SOURCE_COUNT , &iic_host_ops, + iic_host =irq_domain_add_linear_of_node (NULL ,IIC_SOURCE_COUNT , &iic_host_ops,NULL );BUG_ON (iic_host ==NULL );irq_set_default_domain (iic_host);
arch/powerpc/platforms/cell/spider-pic.c +1 -1
@@ -282,7 +282,7 @@ static void __init spider_init_one(struct device_node *of_node, int chip,panic ("spider_pic: can't map registers !" );/* Allocate a host */ - pic->host =irq_domain_add_linear (of_node,SPIDER_SRC_COUNT , + pic->host =irq_domain_add_linear_of_node (of_node,SPIDER_SRC_COUNT , &spider_host_ops, pic);if (pic->host ==NULL )panic ("spider_pic: can't allocate irq host !" );
arch/powerpc/platforms/embedded6xx/flipper-pic.c +1 -1
@@ -149,7 +149,7 @@ static struct irq_domain * __init flipper_pic_init(struct device_node *np)__flipper_quiesce (io_base); - irq_domain =irq_domain_add_linear (np,FLIPPER_NR_IRQS , + irq_domain =irq_domain_add_linear_of_node (np,FLIPPER_NR_IRQS , &flipper_irq_domain_ops, io_base);if (!irq_domain) {pr_err ("failed to allocate irq_domain\n" );
arch/powerpc/platforms/embedded6xx/hlwd-pic.c +1 -1
@@ -175,7 +175,7 @@ static struct irq_domain *__init hlwd_pic_init(struct device_node *np)__hlwd_quiesce (io_base); - irq_domain =irq_domain_add_linear (np,HLWD_NR_IRQS , + irq_domain =irq_domain_add_linear_of_node (np,HLWD_NR_IRQS , &hlwd_irq_domain_ops, io_base);if (!irq_domain) {pr_err ("failed to allocate irq_domain\n" );
arch/powerpc/platforms/powermac/pic.c +1 -1
@@ -327,7 +327,7 @@ static void __init pmac_pic_probe_oldstyle(void)/* * Allocate an irq host */ - pmac_pic_host =irq_domain_add_linear (master, max_irqs, + pmac_pic_host =irq_domain_add_linear_of_node (master, max_irqs, &pmac_pic_host_ops,NULL );BUG_ON (pmac_pic_host ==NULL );irq_set_default_domain (pmac_pic_host);
arch/powerpc/platforms/powermac/smp.c +1 -1
@@ -190,7 +190,7 @@ static int __init psurge_secondary_ipi_init(void) {int rc = -ENOMEM ; - psurge_host =irq_domain_add_nomap (NULL , ~0 , &psurge_host_ops,NULL ); + psurge_host =irq_domain_add_nomap_of_node (NULL , ~0 , &psurge_host_ops,NULL );if (psurge_host) psurge_secondary_virq =irq_create_direct_mapping (psurge_host);
arch/powerpc/platforms/powernv/opal-irqchip.c +1 -1
@@ -191,7 +191,7 @@ int __init opal_event_init(void)* fall back to the legacy method (opal_event_request(...)) * anyway. */ dn =of_find_compatible_node (NULL ,NULL ,"ibm,opal-event" ); - opal_event_irqchip.domain =irq_domain_add_linear (dn,MAX_NUM_EVENTS , + opal_event_irqchip.domain =irq_domain_add_linear_of_node (dn,MAX_NUM_EVENTS , &opal_event_domain_ops, &opal_event_irqchip);of_node_put (dn);if (!opal_event_irqchip.domain) {
arch/powerpc/platforms/ps3/interrupt.c +1 -1
@@ -743,7 +743,7 @@ void __init ps3_init_IRQ(void)unsigned cpu;struct irq_domain *host; - host =irq_domain_add_nomap (NULL ,PS3_PLUG_MAX +1 , &ps3_host_ops,NULL ); + host =irq_domain_add_nomap_of_node (NULL ,PS3_PLUG_MAX +1 , &ps3_host_ops,NULL );irq_set_default_domain (host);for_each_possible_cpu (cpu) {
arch/powerpc/sysdev/cpm2_pic.c +1 -1
@@ -259,7 +259,7 @@ void cpm2_pic_init(struct device_node *node)out_be32 (&cpm2_intctl->ic_scprrl,0x05309770 );/* create a legacy host */ - cpm2_pic_host =irq_domain_add_linear (node,64 , &cpm2_pic_host_ops,NULL ); + cpm2_pic_host =irq_domain_add_linear_of_node (node,64 , &cpm2_pic_host_ops,NULL );if (cpm2_pic_host ==NULL ) {printk (KERN_ERR "CPM2 PIC: failed to allocate irq host!\n" );return ;
arch/powerpc/sysdev/ehv_pic.c +1 -1
@@ -269,7 +269,7 @@ void __init ehv_pic_init(void)return ; } - ehv_pic->irqhost =irq_domain_add_linear (np,NR_EHV_PIC_INTS , + ehv_pic->irqhost =irq_domain_add_linear_of_node (np,NR_EHV_PIC_INTS , &ehv_pic_host_ops, ehv_pic);if (!ehv_pic->irqhost) {of_node_put (np);
arch/powerpc/sysdev/fsl_msi.c +1 -1
@@ -412,7 +412,7 @@ static int fsl_of_msi_probe(struct platform_device *dev) }platform_set_drvdata (dev, msi); - msi->irqhost =irq_domain_add_linear (dev->dev.of_node, + msi->irqhost =irq_domain_add_linear_of_node (dev->dev.of_node,NR_MSI_IRQS_MAX , &fsl_msi_host_ops, msi);if (msi->irqhost ==NULL ) {
arch/powerpc/sysdev/ge/ge_pic.c +1 -1
@@ -214,7 +214,7 @@ void __init gef_pic_init(struct device_node *np) }/* Setup an irq_domain structure */ - gef_pic_irq_host =irq_domain_add_linear (np,GEF_PIC_NUM_IRQS , + gef_pic_irq_host =irq_domain_add_linear_of_node (np,GEF_PIC_NUM_IRQS , &gef_pic_host_ops,NULL );if (gef_pic_irq_host ==NULL )return ;
arch/powerpc/sysdev/i8259.c +1 -1
@@ -260,7 +260,7 @@ void i8259_init(struct device_node *node, unsigned long intack_addr)raw_spin_unlock_irqrestore (&i8259_lock, flags);/* create a legacy host */ - i8259_host =irq_domain_add_legacy (node,NR_IRQS_LEGACY ,0 ,0 , + i8259_host =irq_domain_add_legacy_of_node (node,NR_IRQS_LEGACY ,0 ,0 , &i8259_host_ops,NULL );if (i8259_host ==NULL ) {printk (KERN_ERR "i8259: failed to allocate irq host !\n" );
arch/powerpc/sysdev/ipic.c +1 -1
@@ -711,7 +711,7 @@ struct ipic * __init ipic_init(struct device_node *node, unsigned int flags)if (ipic ==NULL )return NULL ; - ipic->irqhost =irq_domain_add_linear (node,NR_IPIC_INTS , + ipic->irqhost =irq_domain_add_linear_of_node (node,NR_IPIC_INTS , &ipic_host_ops, ipic);if (ipic->irqhost ==NULL ) {kfree (ipic);
arch/powerpc/sysdev/mpic.c +1 -1
@@ -1483,7 +1483,7 @@ struct mpic * __init mpic_alloc(struct device_node *node, mpic->isu_shift =1 +__ilog2 (mpic->isu_size -1 ); mpic->isu_mask = (1 << mpic->isu_shift) -1 ; - mpic->irqhost =irq_domain_add_linear (mpic->node, + mpic->irqhost =irq_domain_add_linear_of_node (mpic->node, intvec_top, &mpic_host_ops, mpic);
arch/powerpc/sysdev/tsi108_pci.c +1 -1
@@ -404,7 +404,7 @@ void __init tsi108_pci_int_init(struct device_node *node) {DBG ("Tsi108_pci_int_init: initializing PCI interrupts\n" ); - pci_irq_host =irq_domain_add_legacy (node,NR_IRQS_LEGACY ,0 ,0 , + pci_irq_host =irq_domain_add_legacy_of_node (node,NR_IRQS_LEGACY ,0 ,0 , &pci_irq_domain_ops,NULL );if (pci_irq_host ==NULL ) {printk (KERN_ERR "pci_irq_host: failed to allocate irq domain!\n" );
arch/powerpc/sysdev/xive/common.c +1 -1
@@ -1464,7 +1464,7 @@ static const struct irq_domain_ops xive_irq_domain_ops = {static void __init xive_init_host (struct device_node *np) { - xive_irq_domain =irq_domain_add_tree (np, &xive_irq_domain_ops,NULL ); + xive_irq_domain =irq_domain_add_tree_of_node (np, &xive_irq_domain_ops,NULL );if (WARN_ON (xive_irq_domain ==NULL ))return ;irq_set_default_domain (xive_irq_domain);
arch/sh/boards/mach-se/7343/irq.c +1 -1
@@ -47,7 +47,7 @@ static void __init se7343_domain_init(void) {int i; - se7343_irq_domain =irq_domain_add_linear (NULL ,SE7343_FPGA_IRQ_NR , + se7343_irq_domain =irq_domain_add_linear_of_node (NULL ,SE7343_FPGA_IRQ_NR , &irq_domain_simple_ops,NULL );if (unlikely (!se7343_irq_domain)) {printk ("Failed to get IRQ domain\n" );
arch/sh/boards/mach-se/7722/irq.c +1 -1
@@ -46,7 +46,7 @@ static void __init se7722_domain_init(void) {int i; - se7722_irq_domain =irq_domain_add_linear (NULL ,SE7722_FPGA_IRQ_NR , + se7722_irq_domain =irq_domain_add_linear_of_node (NULL ,SE7722_FPGA_IRQ_NR , &irq_domain_simple_ops,NULL );if (unlikely (!se7722_irq_domain)) {printk ("Failed to get IRQ domain\n" );
arch/sh/boards/mach-x3proto/gpio.c +1 -1
@@ -108,7 +108,7 @@ int __init x3proto_gpio_setup(void)if (unlikely (ret)) goto err_gpio; - x3proto_irq_domain =irq_domain_add_linear (NULL ,NR_BASEBOARD_GPIOS , + x3proto_irq_domain =irq_domain_add_linear_of_node (NULL ,NR_BASEBOARD_GPIOS , &x3proto_gpio_irq_ops,NULL );if (unlikely (!x3proto_irq_domain)) goto err_irq;
drivers/bus/moxtet.c +1 -1
@@ -737,7 +737,7 @@ static int moxtet_irq_setup(struct moxtet *moxtet) {int i, ret; - moxtet->irq.domain =irq_domain_add_simple (moxtet->dev->of_node, + moxtet->irq.domain =irq_domain_add_simple_of_node (moxtet->dev->of_node,MOXTET_NIRQS ,0 , &moxtet_irq_domain, moxtet);if (moxtet->irq.domain ==NULL ) {
drivers/edac/altera_edac.c +1 -1
@@ -2130,7 +2130,7 @@ static int altr_edac_a10_probe(struct platform_device *pdev) edac->irq_chip.name = pdev->dev.of_node->name; edac->irq_chip.irq_mask = a10_eccmgr_irq_mask; edac->irq_chip.irq_unmask = a10_eccmgr_irq_unmask; - edac->domain =irq_domain_add_linear (pdev->dev.of_node,64 , + edac->domain =irq_domain_add_linear_of_node (pdev->dev.of_node,64 , &a10_eccmgr_ic_ops, edac);if (!edac->domain) {dev_err (&pdev->dev,"Error adding IRQ domain\n" );
drivers/gpio/gpio-brcmstb.c +1 -1
@@ -436,7 +436,7 @@ static int brcmstb_gpio_irq_setup(struct platform_device *pdev,int err; priv->irq_domain = -irq_domain_add_linear (np, priv->num_gpios, +irq_domain_add_linear_of_node (np, priv->num_gpios, &brcmstb_gpio_irq_domain_ops, priv);if (!priv->irq_domain) {
drivers/gpio/gpio-davinci.c +1 -1
@@ -477,7 +477,7 @@ static int davinci_gpio_irq_setup(struct platform_device *pdev)return irq; } - irq_domain =irq_domain_add_legacy (dev->of_node, ngpio, irq,0 , + irq_domain =irq_domain_add_legacy_of_node (dev->of_node, ngpio, irq,0 , &davinci_gpio_irq_ops, chips);if (!irq_domain) {
drivers/gpio/gpio-em.c +1 -1
@@ -323,7 +323,7 @@ static int em_gio_probe(struct platform_device *pdev) irq_chip->irq_release_resources = em_gio_irq_relres; irq_chip->flags =IRQCHIP_SKIP_SET_WAKE |IRQCHIP_MASK_ON_SUSPEND ; - p->irq_domain =irq_domain_add_simple (dev->of_node, ngpios,0 , + p->irq_domain =irq_domain_add_simple_of_node (dev->of_node, ngpios,0 , &em_gio_irq_domain_ops, p);if (!p->irq_domain) {dev_err (dev,"cannot initialize irq domain\n" );
drivers/gpio/gpio-grgpio.c +1 -1
@@ -396,7 +396,7 @@ static int grgpio_probe(struct platform_device *ofdev)return -EINVAL ; } - priv->domain =irq_domain_add_linear (np, gc->ngpio, + priv->domain =irq_domain_add_linear_of_node (np, gc->ngpio, &grgpio_irq_domain_ops, priv);if (!priv->domain) {
drivers/gpio/gpio-lpc18xx.c +1 -1
@@ -240,7 +240,7 @@ static int lpc18xx_gpio_pin_ic_probe(struct lpc18xx_gpio_chip *gc)raw_spin_lock_init (&ic->lock); - ic->domain = irq_domain_add_hierarchy(parent_domain, 0, + ic->domain = irq_domain_add_hierarchy_of_node(parent_domain, 0, NR_LPC18XX_GPIO_PIN_IC_IRQS, dev->of_node, &lpc18xx_gpio_pin_ic_domain_ops,
drivers/gpio/gpio-mvebu.c +1 -1
@@ -1241,7 +1241,7 @@ static int mvebu_gpio_probe(struct platform_device *pdev)return 0 ; mvchip->domain = -irq_domain_add_linear (np, ngpios, &irq_generic_chip_ops,NULL ); +irq_domain_add_linear_of_node (np, ngpios, &irq_generic_chip_ops,NULL );if (!mvchip->domain) {dev_err (&pdev->dev,"couldn't allocate irq domain %s (DT).\n" , mvchip->chip.label);
drivers/gpio/gpio-mxc.c +1 -1
@@ -503,7 +503,7 @@ static int mxc_gpio_probe(struct platform_device *pdev) goto out_bgio; } - port->domain =irq_domain_add_legacy (np,32 , irq_base,0 , + port->domain =irq_domain_add_legacy_of_node (np,32 , irq_base,0 , &irq_domain_simple_ops,NULL );if (!port->domain) { err = -ENODEV ;
drivers/gpio/gpio-mxs.c +1 -1
@@ -303,7 +303,7 @@ static int mxs_gpio_probe(struct platform_device *pdev) goto out_iounmap; } - port->domain =irq_domain_add_legacy (np,32 , irq_base,0 , + port->domain =irq_domain_add_legacy_of_node (np,32 , irq_base,0 , &irq_domain_simple_ops,NULL );if (!port->domain) { err = -ENODEV ;
drivers/gpio/gpio-pxa.c +1 -1
@@ -636,7 +636,7 @@ static int pxa_gpio_probe(struct platform_device *pdev)if (!pxa_last_gpio)return -EINVAL ; - pchip->irqdomain =irq_domain_add_legacy (pdev->dev.of_node, + pchip->irqdomain =irq_domain_add_legacy_of_node (pdev->dev.of_node, pxa_last_gpio +1 , irq_base,0 , &pxa_irq_domain_ops, pchip);if (!pchip->irqdomain)
drivers/gpio/gpio-rockchip.c +1 -1
@@ -521,7 +521,7 @@ static int rockchip_interrupts_register(struct rockchip_pin_bank *bank)struct irq_chip_generic *gc;int ret; - bank->domain =irq_domain_add_linear (bank->of_node,32 , + bank->domain =irq_domain_add_linear_of_node (bank->of_node,32 , &irq_generic_chip_ops,NULL );if (!bank->domain) { dev_warn(bank->dev, "could not init irq domain for bank %s\n",
drivers/gpio/gpio-sa1100.c +1 -1
@@ -319,7 +319,7 @@ void __init sa1100_init_gpio(void)gpiochip_add_data (&sa1100_gpio_chip.chip,NULL ); - sa1100_gpio_irqdomain =irq_domain_add_simple (NULL , + sa1100_gpio_irqdomain =irq_domain_add_simple_of_node (NULL ,28 ,IRQ_GPIO0 , &sa1100_gpio_irqdomain_ops, sgc);
drivers/gpio/gpio-sodaville.c +1 -1
@@ -169,7 +169,7 @@ static int sdv_register_irqsupport(struct sdv_gpio_chip_data *sd,IRQ_GC_INIT_MASK_CACHE ,IRQ_NOREQUEST , IRQ_LEVEL | IRQ_NOPROBE); - sd->id =irq_domain_add_legacy (pdev->dev.of_node,SDV_NUM_PUB_GPIOS , + sd->id =irq_domain_add_legacy_of_node (pdev->dev.of_node,SDV_NUM_PUB_GPIOS , sd->irq_base,0 , &irq_domain_sdv_ops, sd);if (!sd->id)return -ENODEV ;
drivers/gpio/gpio-tb10x.c +1 -1
@@ -183,7 +183,7 @@ static int tb10x_gpio_probe(struct platform_device *pdev)if (ret !=0 )return ret; - tb10x_gpio->domain =irq_domain_add_linear (np, + tb10x_gpio->domain =irq_domain_add_linear_of_node (np, tb10x_gpio->gc.ngpio, &irq_generic_chip_ops,NULL );if (!tb10x_gpio->domain) {
drivers/gpio/gpio-twl4030.c +1 -1
@@ -524,7 +524,7 @@ static int gpio_twl4030_probe(struct platform_device *pdev)return irq_base; } -irq_domain_add_legacy (node,TWL4030_GPIO_MAX , irq_base,0 , +irq_domain_add_legacy_of_node (node,TWL4030_GPIO_MAX , irq_base,0 , &irq_domain_simple_ops,NULL ); ret =twl4030_sih_setup (&pdev->dev,TWL4030_MODULE_GPIO , irq_base);
drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c +1 -1
@@ -725,7 +725,7 @@ static const struct irq_domain_ops amdgpu_hw_irqdomain_ops = {*/ int amdgpu_irq_add_domain (struct amdgpu_device *adev) { - adev->irq.domain =irq_domain_add_linear (NULL ,AMDGPU_MAX_IRQ_SRC_ID , + adev->irq.domain =irq_domain_add_linear_of_node (NULL ,AMDGPU_MAX_IRQ_SRC_ID , &amdgpu_hw_irqdomain_ops, adev);if (!adev->irq.domain) {DRM_ERROR ("GPU irq add domain failed\n" );
drivers/gpu/drm/msm/msm_mdss.c +1 -1
@@ -150,7 +150,7 @@ static int _msm_mdss_irq_domain_add(struct msm_mdss *msm_mdss) dev = msm_mdss->dev; - domain =irq_domain_add_linear (dev->of_node,32 , + domain =irq_domain_add_linear_of_node (dev->of_node,32 , &msm_mdss_irqdomain_ops, msm_mdss);if (!domain) {dev_err (dev,"failed to add irq_domain\n" );
drivers/gpu/ipu-v3/ipu-common.c +1 -1
@@ -1207,7 +1207,7 @@ static int ipu_irq_init(struct ipu_soc *ipu) };int ret, i; - ipu->domain =irq_domain_add_linear (ipu->dev->of_node,IPU_NUM_IRQS , + ipu->domain =irq_domain_add_linear_of_node (ipu->dev->of_node,IPU_NUM_IRQS , &irq_generic_chip_ops, ipu);if (!ipu->domain) {dev_err (ipu->dev,"failed to add irq domain\n" );
drivers/i2c/busses/i2c-cht-wc.c +1 -1
@@ -467,7 +467,7 @@ static int cht_wc_i2c_adap_i2c_probe(struct platform_device *pdev)return ret;/* Alloc and register client IRQ */ - adap->irq_domain =irq_domain_add_linear (NULL ,1 , &irq_domain_simple_ops,NULL ); + adap->irq_domain =irq_domain_add_linear_of_node (NULL ,1 , &irq_domain_simple_ops,NULL );if (!adap->irq_domain)return -ENOMEM ;
drivers/i2c/muxes/i2c-mux-pca954x.c +1 -1
@@ -442,7 +442,7 @@ static int pca954x_irq_setup(struct i2c_mux_core *muxc)raw_spin_lock_init (&data->lock); - data->irq =irq_domain_add_linear (client->dev.of_node, + data->irq =irq_domain_add_linear_of_node (client->dev.of_node, data->chip->nchans, &irq_domain_simple_ops, data);if (!data->irq)
drivers/iio/adc/stm32-adc-core.c +1 -1
@@ -421,7 +421,7 @@ static int stm32_adc_irq_probe(struct platform_device *pdev,return priv->irq[i]; } - priv->domain =irq_domain_add_simple (np,STM32_ADC_MAX_ADCS ,0 , + priv->domain =irq_domain_add_simple_of_node (np,STM32_ADC_MAX_ADCS ,0 , &stm32_adc_domain_ops, priv);if (!priv->domain) {
drivers/irqchip/exynos-combiner.c +1 -1
@@ -180,7 +180,7 @@ static void __init combiner_init(void __iomem *combiner_base,if (!combiner_data)return ; - combiner_irq_domain =irq_domain_add_linear (np, nr_irq, + combiner_irq_domain =irq_domain_add_linear_of_node (np, nr_irq, &combiner_irq_domain_ops, combiner_data);if (WARN_ON (!combiner_irq_domain)) {pr_warn ("%s: irq domain init failed\n" , __func__);
drivers/irqchip/irq-al-fic.c +1 -1
@@ -139,7 +139,7 @@ static int al_fic_register(struct device_node *node,struct irq_chip_generic *gc;int ret; - fic->domain =irq_domain_add_linear (node, + fic->domain =irq_domain_add_linear_of_node (node,NR_FIC_IRQS , &irq_generic_chip_ops, fic);
drivers/irqchip/irq-alpine-msi.c +1 -1
@@ -205,7 +205,7 @@ static int alpine_msix_init_domains(struct alpine_msix_data *priv,return -ENXIO ; } - middle_domain =irq_domain_add_hierarchy (gic_domain,0 ,0 ,NULL , + middle_domain =irq_domain_add_hierarchy_of_node (gic_domain,0 ,0 ,NULL , &alpine_msix_middle_domain_ops, priv);if (!middle_domain) {
drivers/irqchip/irq-armada-370-xp.c +2 -2
@@ -348,7 +348,7 @@ static int __init mpic_msi_init(struct mpic *mpic, struct device_node *node, mpic->msi_doorbell_mask =PCI_MSI_FULL_DOORBELL_MASK ; } - mpic->msi_inner_domain =irq_domain_add_linear (NULL , mpic->msi_doorbell_size, + mpic->msi_inner_domain =irq_domain_add_linear_of_node (NULL , mpic->msi_doorbell_size, &mpic_msi_domain_ops, mpic);if (!mpic->msi_inner_domain)return -ENOMEM ;
@@ -861,7 +861,7 @@ static int __init mpic_of_init(struct device_node *node, struct device_node *parif (!mpic_is_ipi_available (mpic)) nr_irqs =MPIC_PER_CPU_IRQS_NR ; - mpic->domain =irq_domain_add_linear (node, nr_irqs, &mpic_irq_ops, mpic); + mpic->domain =irq_domain_add_linear_of_node (node, nr_irqs, &mpic_irq_ops, mpic);if (!mpic->domain) {pr_err ("%pOF: Unable to add IRQ domain\n" , node);return -ENOMEM ;
drivers/irqchip/irq-aspeed-i2c-ic.c +1 -1
@@ -82,7 +82,7 @@ static int __init aspeed_i2c_ic_of_init(struct device_node *node, goto err_iounmap; } - i2c_ic->irq_domain =irq_domain_add_linear (node,ASPEED_I2C_IC_NUM_BUS , + i2c_ic->irq_domain =irq_domain_add_linear_of_node (node,ASPEED_I2C_IC_NUM_BUS , &aspeed_i2c_ic_irq_domain_ops,NULL );if (!i2c_ic->irq_domain) {
drivers/irqchip/irq-aspeed-intc.c +1 -1
@@ -102,7 +102,7 @@ static int __init aspeed_intc_ic_of_init(struct device_node *node,writel (0xffffffff , intc_ic->base +INTC_INT_STATUS_REG );writel (0x0 , intc_ic->base +INTC_INT_ENABLE_REG ); - intc_ic->irq_domain =irq_domain_add_linear (node,INTC_IRQS_PER_WORD , + intc_ic->irq_domain =irq_domain_add_linear_of_node (node,INTC_IRQS_PER_WORD , &aspeed_intc_ic_irq_domain_ops, intc_ic);if (!intc_ic->irq_domain) { ret = -ENOMEM ;
drivers/irqchip/irq-aspeed-scu-ic.c +1 -1
@@ -165,7 +165,7 @@ static int aspeed_scu_ic_of_init_common(struct aspeed_scu_ic *scu_ic, goto err; } - scu_ic->irq_domain =irq_domain_add_linear (node, scu_ic->num_irqs, + scu_ic->irq_domain =irq_domain_add_linear_of_node (node, scu_ic->num_irqs, &aspeed_scu_ic_domain_ops, scu_ic);if (!scu_ic->irq_domain) {
drivers/irqchip/irq-aspeed-vic.c +1 -1
@@ -211,7 +211,7 @@ static int __init avic_of_init(struct device_node *node,set_handle_irq (avic_handle_irq);/* Register our domain */ - vic->dom =irq_domain_add_simple (node,NUM_IRQS ,0 , + vic->dom =irq_domain_add_simple_of_node (node,NUM_IRQS ,0 , &avic_dom_ops, vic);return 0 ;
drivers/irqchip/irq-ath79-misc.c +2 -2
@@ -147,7 +147,7 @@ static int __init ath79_misc_intc_of_init(return -ENOMEM ; } - domain =irq_domain_add_linear (node,ATH79_MISC_IRQ_COUNT , + domain =irq_domain_add_linear_of_node (node,ATH79_MISC_IRQ_COUNT , &misc_irq_domain_ops, base);if (!domain) {pr_err ("Failed to add MISC irqdomain\n" );
@@ -188,7 +188,7 @@ void __init ath79_misc_irq_init(void __iomem *regs, int irq,else ath79_misc_irq_chip.irq_ack = ar724x_misc_irq_ack; - domain =irq_domain_add_legacy (NULL ,ATH79_MISC_IRQ_COUNT , + domain =irq_domain_add_legacy_of_node (NULL ,ATH79_MISC_IRQ_COUNT , irq_base,0 , &misc_irq_domain_ops, regs);if (!domain)panic ("Failed to create MISC irqdomain" );
drivers/irqchip/irq-atmel-aic-common.c +1 -1
@@ -228,7 +228,7 @@ struct irq_domain *__init aic_common_of_init(struct device_node *node, goto err_iounmap; } - domain =irq_domain_add_linear (node, nchips *32 , ops, aic); + domain =irq_domain_add_linear_of_node (node, nchips *32 , ops, aic);if (!domain) { ret = -ENOMEM ; goto err_free_aic;
drivers/irqchip/irq-bcm2835.c +1 -1
@@ -144,7 +144,7 @@ static int __init armctrl_of_init(struct device_node *node,if (!base)panic ("%pOF: unable to map IC registers\n" , node); - intc.domain =irq_domain_add_linear (node,MAKE_HWIRQ (NR_BANKS ,0 ), + intc.domain =irq_domain_add_linear_of_node (node,MAKE_HWIRQ (NR_BANKS ,0 ), &armctrl_ops,NULL );if (!intc.domain)panic ("%pOF: unable to create IRQ domain\n" , node);
drivers/irqchip/irq-bcm2836.c +1 -1
@@ -325,7 +325,7 @@ static int __init bcm2836_arm_irqchip_l1_intc_of_init(struct device_node *node,bcm2835_init_local_timer_frequency (); - intc.domain =irq_domain_add_linear (node,LAST_IRQ +1 , + intc.domain =irq_domain_add_linear_of_node (node,LAST_IRQ +1 , &bcm2836_arm_irqchip_intc_ops,NULL );if (!intc.domain)
drivers/irqchip/irq-bcm6345-l1.c +1 -1
@@ -316,7 +316,7 @@ static int __init bcm6345_l1_of_init(struct device_node *dn,raw_spin_lock_init (&intc->lock); - intc->domain =irq_domain_add_linear (dn,IRQS_PER_WORD * intc->n_words, + intc->domain =irq_domain_add_linear_of_node (dn,IRQS_PER_WORD * intc->n_words, &bcm6345_l1_domain_ops, intc);if (!intc->domain) {
drivers/irqchip/irq-bcm7038-l1.c +1 -1
@@ -416,7 +416,7 @@ static int __init bcm7038_l1_of_init(struct device_node *dn, } } - intc->domain =irq_domain_add_linear (dn,IRQS_PER_WORD * intc->n_words, + intc->domain =irq_domain_add_linear_of_node (dn,IRQS_PER_WORD * intc->n_words, &bcm7038_l1_domain_ops, intc);if (!intc->domain) {
drivers/irqchip/irq-bcm7120-l2.c +1 -1
@@ -264,7 +264,7 @@ static int __init bcm7120_l2_intc_probe(struct device_node *dn, goto out_free_l1_data; } - data->domain =irq_domain_add_linear (dn,IRQS_PER_WORD * data->n_words, + data->domain =irq_domain_add_linear_of_node (dn,IRQS_PER_WORD * data->n_words, &irq_generic_chip_ops,NULL );if (!data->domain) { ret = -ENOMEM ;
drivers/irqchip/irq-brcmstb-l2.c +1 -1
@@ -208,7 +208,7 @@ static int __init brcmstb_l2_intc_of_init(struct device_node *np, goto out_unmap; } - data->domain =irq_domain_add_linear (np,32 , + data->domain =irq_domain_add_linear_of_node (np,32 , &irq_generic_chip_ops,NULL );if (!data->domain) { ret = -ENOMEM ;
drivers/irqchip/irq-clps711x.c +1 -1
@@ -184,7 +184,7 @@ static int __init _clps711x_intc_init(struct device_node *np, clps711x_intc->ops.map = clps711x_intc_irq_map; clps711x_intc->ops.xlate = irq_domain_xlate_onecell; clps711x_intc->domain = -irq_domain_add_legacy (np,ARRAY_SIZE (clps711x_irqs), +irq_domain_add_legacy_of_node (np,ARRAY_SIZE (clps711x_irqs),0 ,0 , &clps711x_intc->ops,NULL );if (!clps711x_intc->domain) { err = -ENOMEM ;
drivers/irqchip/irq-crossbar.c +1 -1
@@ -351,7 +351,7 @@ static int __init irqcrossbar_init(struct device_node *node,if (err)return err; - domain =irq_domain_add_hierarchy (parent_domain,0 , + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 , cb->max_crossbar_sources, node, &crossbar_domain_ops,NULL );
drivers/irqchip/irq-csky-apb-intc.c +1 -1
@@ -114,7 +114,7 @@ ck_intc_init_comm(struct device_node *node, struct device_node *parent)return -EINVAL ; } - root_domain =irq_domain_add_linear (node, nr_irq, + root_domain =irq_domain_add_linear_of_node (node, nr_irq, &irq_generic_chip_ops,NULL );if (!root_domain) {pr_err ("C-SKY Intc irq_domain_add failed.\n" );
drivers/irqchip/irq-csky-mpintc.c +1 -1
@@ -255,7 +255,7 @@ csky_mpintc_init(struct device_node *node, struct device_node *parent)writel_relaxed (BIT (0 ), INTCG_base +INTCG_ICTLR ); } - root_domain =irq_domain_add_linear (node, nr_irq, &csky_irqdomain_ops, + root_domain =irq_domain_add_linear_of_node (node, nr_irq, &csky_irqdomain_ops,NULL );if (!root_domain)return -ENXIO ;
drivers/irqchip/irq-davinci-cp-intc.c +1 -1
@@ -212,7 +212,7 @@ davinci_cp_intc_do_init(const struct davinci_cp_intc_config *config,return irq_base; } - davinci_cp_intc_irq_domain =irq_domain_add_legacy ( + davinci_cp_intc_irq_domain =irq_domain_add_legacy_of_node ( node, config->num_irqs, irq_base,0 , &davinci_cp_intc_irq_domain_ops,NULL );
drivers/irqchip/irq-digicolor.c +1 -1
@@ -95,7 +95,7 @@ static int __init digicolor_of_init(struct device_node *node,regmap_write (ucregs,UC_IRQ_CONTROL ,1 ); digicolor_irq_domain = -irq_domain_add_linear (node,64 , &irq_generic_chip_ops,NULL ); +irq_domain_add_linear_of_node (node,64 , &irq_generic_chip_ops,NULL );if (!digicolor_irq_domain) {pr_err ("%pOF: unable to create IRQ domain\n" , node);return -ENOMEM ;
drivers/irqchip/irq-dw-apb-ictl.c +1 -1
@@ -173,7 +173,7 @@ static int __init dw_apb_ictl_init(struct device_node *np,else nrirqs =fls (readl_relaxed (iobase +APB_INT_ENABLE_L )); - domain =irq_domain_add_linear (np, nrirqs, domain_ops,NULL ); + domain =irq_domain_add_linear_of_node (np, nrirqs, domain_ops,NULL );if (!domain) {pr_err ("%pOF: unable to add irq domain\n" , np); ret = -ENOMEM ;
drivers/irqchip/irq-ftintc010.c +1 -1
@@ -180,7 +180,7 @@ static int __init ft010_of_init_irq(struct device_node *node,writel (0 ,FT010_IRQ_MASK (f->base));writel (0 ,FT010_FIQ_MASK (f->base)); - f->domain =irq_domain_add_simple (node,FT010_NUM_IRQS ,0 , + f->domain =irq_domain_add_simple_of_node (node,FT010_NUM_IRQS ,0 , &ft010_irqdomain_ops, f);set_handle_irq (ft010_irqchip_handle_irq);
drivers/irqchip/irq-goldfish-pic.c +1 -1
@@ -101,7 +101,7 @@ static int __init goldfish_pic_of_init(struct device_node *of_node,irq_setup_generic_chip (gc,IRQ_MSK (GFPIC_NR_IRQS ),0 ,IRQ_NOPROBE |IRQ_LEVEL ,0 ); - gfpic->irq_domain =irq_domain_add_legacy (of_node,GFPIC_NR_IRQS , + gfpic->irq_domain =irq_domain_add_legacy_of_node (of_node,GFPIC_NR_IRQS ,GFPIC_IRQ_BASE ,0 , &goldfish_irq_domain_ops,NULL );
drivers/irqchip/irq-hip04.c +1 -1
@@ -386,7 +386,7 @@ hip04_of_init(struct device_node *node, struct device_node *parent)return -EINVAL ; } - hip04_data.domain =irq_domain_add_legacy (node, nr_irqs, irq_base, + hip04_data.domain =irq_domain_add_legacy_of_node (node, nr_irqs, irq_base,0 , &hip04_irq_domain_ops, &hip04_data);
drivers/irqchip/irq-i8259.c +1 -1
@@ -313,7 +313,7 @@ struct irq_domain * __init __init_i8259_irqs(struct device_node *node)init_8259A (0 ); - domain =irq_domain_add_legacy (node,16 ,I8259A_IRQ_BASE ,0 , + domain =irq_domain_add_legacy_of_node (node,16 ,I8259A_IRQ_BASE ,0 , &i8259A_ops,NULL );if (!domain)panic ("Failed to add i8259 IRQ domain" );
drivers/irqchip/irq-idt3243x.c +1 -1
@@ -72,7 +72,7 @@ static int idt_pic_init(struct device_node *of_node, struct device_node *parent) goto out_unmap_irq; } - domain =irq_domain_add_linear (of_node,IDT_PIC_NR_IRQS , + domain =irq_domain_add_linear_of_node (of_node,IDT_PIC_NR_IRQS , &irq_generic_chip_ops,NULL );if (!domain) {pr_err ("Failed to add irqdomain!\n" );
drivers/irqchip/irq-imgpdc.c +1 -1
@@ -372,7 +372,7 @@ static int pdc_intc_probe(struct platform_device *pdev) priv->syswake_irq = irq;/* Set up an IRQ domain */ - priv->domain =irq_domain_add_linear (node,16 , &irq_generic_chip_ops, + priv->domain =irq_domain_add_linear_of_node (node,16 , &irq_generic_chip_ops, priv);if (unlikely (!priv->domain)) {dev_err (&pdev->dev,"cannot add IRQ domain\n" );
drivers/irqchip/irq-imx-gpcv2.c +1 -1
@@ -240,7 +240,7 @@ static int __init imx_gpcv2_irqchip_init(struct device_node *node,return -ENOMEM ; } - domain =irq_domain_add_hierarchy (parent_domain,0 ,GPC_MAX_IRQS , + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 ,GPC_MAX_IRQS , node, &gpcv2_irqchip_data_domain_ops, cd);if (!domain) {iounmap (cd->gpc_base);
drivers/irqchip/irq-imx-intmux.c +1 -1
@@ -254,7 +254,7 @@ static int imx_intmux_probe(struct platform_device *pdev) goto out; } - domain =irq_domain_add_linear (np,32 , &imx_intmux_domain_ops, + domain =irq_domain_add_linear_of_node (np,32 , &imx_intmux_domain_ops, &data->irqchip_data[i]);if (!domain) { ret = -ENOMEM ;
drivers/irqchip/irq-imx-irqsteer.c +1 -1
@@ -212,7 +212,7 @@ static int imx_irqsteer_probe(struct platform_device *pdev)/* steer all IRQs into configured channel */ writel_relaxed (BIT (data->channel), data->regs +CHANCTRL ); - data->domain =irq_domain_add_linear (np, data->reg_num *32 , + data->domain =irq_domain_add_linear_of_node (np, data->reg_num *32 , &imx_irqsteer_domain_ops, data);if (!data->domain) {dev_err (&pdev->dev,"failed to create IRQ domain\n" );
drivers/irqchip/irq-ingenic-tcu.c +1 -1
@@ -114,7 +114,7 @@ static int __init ingenic_tcu_irq_init(struct device_node *np, tcu->nb_parent_irqs = irqs; - tcu->domain =irq_domain_add_linear (np,32 , &irq_generic_chip_ops, + tcu->domain =irq_domain_add_linear_of_node (np,32 , &irq_generic_chip_ops,NULL );if (!tcu->domain) { ret = -ENOMEM ;
drivers/irqchip/irq-ingenic.c +1 -1
@@ -90,7 +90,7 @@ static int __init ingenic_intc_of_init(struct device_node *node, goto out_unmap_irq; } - domain =irq_domain_add_linear (node, num_chips *32 , + domain =irq_domain_add_linear_of_node (node, num_chips *32 , &irq_generic_chip_ops,NULL );if (!domain) { err = -ENOMEM ;
drivers/irqchip/irq-jcore-aic.c +1 -1
@@ -107,7 +107,7 @@ static int __init aic_irq_of_init(struct device_node *node,if (ret <0 )return ret; - domain =irq_domain_add_legacy (node, dom_sz - min_irq, min_irq, min_irq, + domain =irq_domain_add_legacy_of_node (node, dom_sz - min_irq, min_irq, min_irq, &jcore_aic_irqdomain_ops, &jcore_aic);if (!domain)
drivers/irqchip/irq-keystone.c +1 -1
@@ -164,7 +164,7 @@ static int keystone_irq_probe(struct platform_device *pdev) kirq->chip.irq_mask = keystone_irq_setmask; kirq->chip.irq_unmask = keystone_irq_unmask; - kirq->irqd =irq_domain_add_linear (np,KEYSTONE_N_IRQ , + kirq->irqd =irq_domain_add_linear_of_node (np,KEYSTONE_N_IRQ , &keystone_irq_ops, kirq);if (!kirq->irqd) {dev_err (dev,"IRQ domain registration failed\n" );
drivers/irqchip/irq-lpc32xx.c +1 -1
@@ -210,7 +210,7 @@ static int __init lpc32xx_of_ic_init(struct device_node *node,return -EINVAL ; } - irqc->domain =irq_domain_add_linear (node,NR_LPC32XX_IC_IRQS , + irqc->domain =irq_domain_add_linear_of_node (node,NR_LPC32XX_IC_IRQS , &lpc32xx_irq_domain_ops, irqc);if (!irqc->domain) {pr_err ("unable to add irq domain\n" );
drivers/irqchip/irq-ls-extirq.c +1 -1
@@ -208,7 +208,7 @@ ls_extirq_of_init(struct device_node *node, struct device_node *parent)of_device_is_compatible (node,"fsl,ls1043a-extirq" );raw_spin_lock_init (&priv->lock); - domain =irq_domain_add_hierarchy (parent_domain,0 , priv->nirq, node, + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 , priv->nirq, node, &extirq_domain_ops, priv);if (!domain) { ret = -ENOMEM ;
drivers/irqchip/irq-ls-scfg-msi.c +1 -1
@@ -216,7 +216,7 @@ static void ls_scfg_msi_irq_handler(struct irq_desc *desc)static int ls_scfg_msi_domains_init (struct ls_scfg_msi *msi_data) {/* Initialize MSI domain parent */ - msi_data->parent =irq_domain_add_linear (NULL , + msi_data->parent =irq_domain_add_linear_of_node (NULL , msi_data->irqs_num, &ls_scfg_msi_domain_ops, msi_data);
drivers/irqchip/irq-ls1x.c +1 -1
@@ -126,7 +126,7 @@ static int __init ls1x_intc_of_init(struct device_node *node, }/* Set up an IRQ domain */ - priv->domain =irq_domain_add_linear (node,32 , &irq_generic_chip_ops, + priv->domain =irq_domain_add_linear_of_node (node,32 , &irq_generic_chip_ops,NULL );if (!priv->domain) {pr_err ("ls1x-irq: cannot add IRQ domain\n" );
drivers/irqchip/irq-mchp-eic.c +1 -1
@@ -248,7 +248,7 @@ static int mchp_eic_init(struct device_node *node, struct device_node *parent) eic->irqs[i] = irq.args[1 ]; } - eic->domain =irq_domain_add_hierarchy (parent_domain,0 ,MCHP_EIC_NIRQ , + eic->domain =irq_domain_add_hierarchy_of_node (parent_domain,0 ,MCHP_EIC_NIRQ , node, &mchp_eic_domain_ops, eic);if (!eic->domain) {pr_err ("%pOF: Failed to add domain\n" , node);
drivers/irqchip/irq-mips-cpu.c +2 -2
@@ -238,7 +238,7 @@ static void mips_cpu_register_ipi_domain(struct device_node *of_node)struct cpu_ipi_domain_state *ipi_domain_state; ipi_domain_state =kzalloc (sizeof (*ipi_domain_state),GFP_KERNEL ); - ipi_domain = irq_domain_add_hierarchy(irq_domain, + ipi_domain = irq_domain_add_hierarchy_of_node(irq_domain, IRQ_DOMAIN_FLAG_IPI_SINGLE, 2, of_node, &mips_cpu_ipi_chip_ops,
@@ -260,7 +260,7 @@ static void __init __mips_cpu_irq_init(struct device_node *of_node)clear_c0_status (ST0_IM );clear_c0_cause (CAUSEF_IP ); - irq_domain =irq_domain_add_legacy (of_node,8 ,MIPS_CPU_IRQ_BASE ,0 , + irq_domain =irq_domain_add_legacy_of_node (of_node,8 ,MIPS_CPU_IRQ_BASE ,0 , &mips_cpu_intc_irq_domain_ops,NULL );if (!irq_domain)
drivers/irqchip/irq-mips-gic.c +2 -2
@@ -841,7 +841,7 @@ static int gic_register_ipi_domain(struct device_node *node)struct irq_domain *gic_ipi_domain;unsigned int v[2 ], num_ipis; - gic_ipi_domain =irq_domain_add_hierarchy (gic_irq_domain, + gic_ipi_domain =irq_domain_add_hierarchy_of_node (gic_irq_domain,IRQ_DOMAIN_FLAG_IPI_PER_CPU ,GIC_NUM_LOCAL_INTRS + gic_shared_intrs, node, &gic_ipi_domain_ops,NULL );
@@ -963,7 +963,7 @@ static int __init gic_of_init(struct device_node *node, gic_irq_dispatch); } - gic_irq_domain =irq_domain_add_simple (node,GIC_NUM_LOCAL_INTRS + + gic_irq_domain =irq_domain_add_simple_of_node (node,GIC_NUM_LOCAL_INTRS + gic_shared_intrs,0 , &gic_irq_domain_ops,NULL );if (!gic_irq_domain) {
drivers/irqchip/irq-mmp.c +2 -2
@@ -261,7 +261,7 @@ static int __init mmp_init_bases(struct device_node *node) } icu_data[0 ].virq_base =0 ; - icu_data[0 ].domain =irq_domain_add_linear (node, nr_irqs, + icu_data[0 ].domain =irq_domain_add_linear_of_node (node, nr_irqs, &mmp_irq_domain_ops, &icu_data[0 ]);for (irq =0 ; irq < nr_irqs; irq++) {
@@ -391,7 +391,7 @@ static int __init mmp2_mux_of_init(struct device_node *node,return -EINVAL ; icu_data[i].virq_base =0 ; - icu_data[i].domain =irq_domain_add_linear (node, nr_irqs, + icu_data[i].domain =irq_domain_add_linear_of_node (node, nr_irqs, &mmp_irq_domain_ops, &icu_data[i]);for (irq =0 ; irq < nr_irqs; irq++) {
drivers/irqchip/irq-mscc-ocelot.c +1 -1
@@ -132,7 +132,7 @@ static int __init vcoreiii_irq_init(struct device_node *node,if (!parent_irq)return -EINVAL ; - domain =irq_domain_add_linear (node, p->n_irq, + domain =irq_domain_add_linear_of_node (node, p->n_irq, &irq_generic_chip_ops,NULL );if (!domain) {pr_err ("%pOFn: unable to add irq domain\n" , node);
drivers/irqchip/irq-mst-intc.c +1 -1
@@ -273,7 +273,7 @@ static int __init mst_intc_of_init(struct device_node *dn,raw_spin_lock_init (&cd->lock); cd->irq_start = irq_start; cd->nr_irqs = irq_end - irq_start +1 ; - domain =irq_domain_add_hierarchy (domain_parent,0 , cd->nr_irqs, dn, + domain =irq_domain_add_hierarchy_of_node (domain_parent,0 , cd->nr_irqs, dn, &mst_intc_domain_ops, cd);if (!domain) {iounmap (cd->base);
drivers/irqchip/irq-mtk-cirq.c +1 -1
@@ -336,7 +336,7 @@ static int __init mtk_cirq_of_init(struct device_node *node, cirq_data->offsets = match->data; irq_num = cirq_data->ext_irq_end - cirq_data->ext_irq_start +1 ; - domain =irq_domain_add_hierarchy (domain_parent,0 , + domain =irq_domain_add_hierarchy_of_node (domain_parent,0 , irq_num, node, &cirq_domain_ops, cirq_data);if (!domain) {
drivers/irqchip/irq-mtk-sysirq.c +1 -1
@@ -207,7 +207,7 @@ static int __init mtk_sysirq_of_init(struct device_node *node, chip_data->which_word[i] = word; } - domain =irq_domain_add_hierarchy (domain_parent,0 , intpol_num, node, + domain =irq_domain_add_hierarchy_of_node (domain_parent,0 , intpol_num, node, &sysirq_domain_ops, chip_data);if (!domain) { ret = -ENOMEM ;
drivers/irqchip/irq-mvebu-pic.c +1 -1
@@ -150,7 +150,7 @@ static int mvebu_pic_probe(struct platform_device *pdev)return -EINVAL ; } - pic->domain =irq_domain_add_linear (node,PIC_MAX_IRQS , + pic->domain =irq_domain_add_linear_of_node (node,PIC_MAX_IRQS , &mvebu_pic_domain_ops, pic);if (!pic->domain) {dev_err (&pdev->dev,"Failed to allocate irq domain\n" );
drivers/irqchip/irq-mxs.c +1 -1
@@ -162,7 +162,7 @@ static const struct irq_domain_ops icoll_irq_domain_ops = {static void __init icoll_add_domain (struct device_node *np,int num) { - icoll_domain =irq_domain_add_linear (np, num, + icoll_domain =irq_domain_add_linear_of_node (np, num, &icoll_irq_domain_ops,NULL );if (!icoll_domain)
drivers/irqchip/irq-nvic.c +1 -1
@@ -90,7 +90,7 @@ static int __init nvic_of_init(struct device_node *node, irqs =NVIC_MAX_IRQ ; nvic_irq_domain = -irq_domain_add_linear (node, irqs, &nvic_irq_domain_ops,NULL ); +irq_domain_add_linear_of_node (node, irqs, &nvic_irq_domain_ops,NULL );if (!nvic_irq_domain) {pr_warn ("Failed to allocate irq domain\n" );
drivers/irqchip/irq-omap-intc.c +2 -2
@@ -248,7 +248,7 @@ static int __init omap_init_irq_of(struct device_node *node)if (WARN_ON (!omap_irq_base))return -ENOMEM ; - domain =irq_domain_add_linear (node, omap_nr_irqs, + domain =irq_domain_add_linear_of_node (node, omap_nr_irqs, &irq_generic_chip_ops,NULL );omap_irq_soft_reset ();
@@ -274,7 +274,7 @@ static int __init omap_init_irq_legacy(u32 base, struct device_node *node) irq_base =0 ; } - domain =irq_domain_add_legacy (node, omap_nr_irqs, irq_base,0 , + domain =irq_domain_add_legacy_of_node (node, omap_nr_irqs, irq_base,0 , &irq_domain_simple_ops,NULL );omap_irq_soft_reset ();
drivers/irqchip/irq-or1k-pic.c +1 -1
@@ -144,7 +144,7 @@ static int __init or1k_pic_init(struct device_node *node,/* Disable all interrupts until explicitly requested */ mtspr (SPR_PICMR , (0UL )); - root_domain =irq_domain_add_linear (node,32 , &or1k_irq_domain_ops, + root_domain =irq_domain_add_linear_of_node (node,32 , &or1k_irq_domain_ops, pic);set_handle_irq (or1k_pic_handle_irq);
drivers/irqchip/irq-orion.c +2 -2
@@ -59,7 +59,7 @@ static int __init orion_irq_init(struct device_node *np,/* count number of irq chips by valid reg addresses */ num_chips =of_address_count (np); - orion_irq_domain =irq_domain_add_linear (np, + orion_irq_domain =irq_domain_add_linear_of_node (np, num_chips *ORION_IRQS_PER_CHIP , &irq_generic_chip_ops,NULL );if (!orion_irq_domain)
@@ -146,7 +146,7 @@ static int __init orion_bridge_irq_init(struct device_node *np,/* get optional number of interrupts provided */ of_property_read_u32 (np,"marvell,#interrupts" , &nrirqs); - domain =irq_domain_add_linear (np, nrirqs, + domain =irq_domain_add_linear_of_node (np, nrirqs, &irq_generic_chip_ops,NULL );if (!domain) {pr_err ("%pOFn: unable to add irq domain\n" , np);
drivers/irqchip/irq-owl-sirq.c +1 -1
@@ -323,7 +323,7 @@ static int __init owl_sirq_init(const struct owl_sirq_params *params,owl_sirq_clear_set_extctl (chip_data,0 ,INTC_EXTCTL_CLK_SEL , i); } - domain =irq_domain_add_hierarchy (parent_domain,0 ,NUM_SIRQ , node, + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 ,NUM_SIRQ , node, &owl_sirq_domain_ops, chip_data);if (!domain) {pr_err ("%pOF: failed to add domain\n" , node);
drivers/irqchip/irq-pic32-evic.c +1 -1
@@ -227,7 +227,7 @@ static int __init pic32_of_init(struct device_node *node, goto err_iounmap; } - evic_irq_domain =irq_domain_add_linear (node, nchips *32 , + evic_irq_domain =irq_domain_add_linear_of_node (node, nchips *32 , &pic32_irq_domain_ops, priv);if (!evic_irq_domain) {
drivers/irqchip/irq-pruss-intc.c +1 -1
@@ -555,7 +555,7 @@ static int pruss_intc_probe(struct platform_device *pdev)mutex_init (&intc->lock); - intc->domain =irq_domain_add_linear (dev->of_node, max_system_events, + intc->domain =irq_domain_add_linear_of_node (dev->of_node, max_system_events, &pruss_intc_irq_domain_ops, intc);if (!intc->domain)return -ENOMEM ;
drivers/irqchip/irq-realtek-rtl.c +1 -1
@@ -162,7 +162,7 @@ static int __init realtek_rtl_of_init(struct device_node *node, struct device_noelse if (!parent_irq)return -ENODEV ; - domain =irq_domain_add_linear (node,RTL_ICTL_NUM_INPUTS , &irq_domain_ops,NULL ); + domain =irq_domain_add_linear_of_node (node,RTL_ICTL_NUM_INPUTS , &irq_domain_ops,NULL );if (!domain)return -ENOMEM ;
drivers/irqchip/irq-renesas-intc-irqpin.c +1 -1
@@ -513,7 +513,7 @@ static int intc_irqpin_probe(struct platform_device *pdev) irq_chip->irq_set_wake = intc_irqpin_irq_set_wake; irq_chip->flags =IRQCHIP_MASK_ON_SUSPEND ; - p->irq_domain =irq_domain_add_simple (dev->of_node, nirqs,0 , + p->irq_domain =irq_domain_add_simple_of_node (dev->of_node, nirqs,0 , &intc_irqpin_irq_domain_ops, p);if (!p->irq_domain) { ret = -ENXIO ;
drivers/irqchip/irq-renesas-irqc.c +1 -1
@@ -168,7 +168,7 @@ static int irqc_probe(struct platform_device *pdev) p->cpu_int_base = p->iomem +IRQC_INT_CPU_BASE (0 );/* SYS-SPI */ - p->irq_domain =irq_domain_add_linear (dev->of_node, p->number_of_irqs, + p->irq_domain =irq_domain_add_linear_of_node (dev->of_node, p->number_of_irqs, &irq_generic_chip_ops, p);if (!p->irq_domain) { ret = -ENXIO ;
drivers/irqchip/irq-renesas-rza1.c +1 -1
@@ -231,7 +231,7 @@ static int rza1_irqc_probe(struct platform_device *pdev) priv->chip.irq_set_type = rza1_irqc_set_type; priv->chip.flags =IRQCHIP_MASK_ON_SUSPEND |IRQCHIP_SKIP_SET_WAKE ; - priv->irq_domain =irq_domain_add_hierarchy (parent,0 ,IRQC_NUM_IRQ , + priv->irq_domain =irq_domain_add_hierarchy_of_node (parent,0 ,IRQC_NUM_IRQ , np, &rza1_irqc_domain_ops, priv);if (!priv->irq_domain) {
drivers/irqchip/irq-renesas-rzg2l.c +1 -1
@@ -581,7 +581,7 @@ static int rzg2l_irqc_common_init(struct device_node *node, struct device_node *raw_spin_lock_init (&rzg2l_irqc_data->lock); - irq_domain =irq_domain_add_hierarchy (parent_domain,0 ,IRQC_NUM_IRQ , + irq_domain =irq_domain_add_hierarchy_of_node (parent_domain,0 ,IRQC_NUM_IRQ , node, &rzg2l_irqc_domain_ops, rzg2l_irqc_data);if (!irq_domain) {
drivers/irqchip/irq-renesas-rzv2h.c +1 -1
@@ -481,7 +481,7 @@ static int rzv2h_icu_init(struct device_node *node, struct device_node *parent)raw_spin_lock_init (&rzv2h_icu_data->lock); - irq_domain =irq_domain_add_hierarchy (parent_domain,0 ,ICU_NUM_IRQ , node, + irq_domain =irq_domain_add_hierarchy_of_node (parent_domain,0 ,ICU_NUM_IRQ , node, &rzv2h_icu_domain_ops, rzv2h_icu_data);if (!irq_domain) {dev_err (&pdev->dev,"failed to add irq domain\n" );
drivers/irqchip/irq-sa11x0.c +1 -1
@@ -162,7 +162,7 @@ void __init sa11x0_init_irq_nodt(int irq_start, resource_size_t io_start)*/ writel_relaxed (1 , iobase +ICCR ); - sa1100_normal_irqdomain =irq_domain_add_simple (NULL , + sa1100_normal_irqdomain =irq_domain_add_simple_of_node (NULL ,32 , irq_start, &sa1100_normal_irqdomain_ops,NULL );
drivers/irqchip/irq-sni-exiu.c +1 -1
@@ -253,7 +253,7 @@ static int __init exiu_dt_init(struct device_node *node,if (IS_ERR (data))return PTR_ERR (data); - domain =irq_domain_add_hierarchy (parent_domain,0 ,NUM_IRQS , node, + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 ,NUM_IRQS , node, &exiu_domain_ops, data);if (!domain) {pr_err ("%pOF: failed to allocate domain\n" , node);
drivers/irqchip/irq-sp7021-intc.c +1 -1
@@ -256,7 +256,7 @@ static int __init sp_intc_init_dt(struct device_node *node, struct device_node *writel_relaxed (~0 ,REG_INTR_CLEAR + i *4 ); } - sp_intc.domain =irq_domain_add_linear (node,SP_INTC_NR_IRQS , + sp_intc.domain =irq_domain_add_linear_of_node (node,SP_INTC_NR_IRQS , &sp_intc_dm_ops, &sp_intc);if (!sp_intc.domain) { ret = -ENOMEM ;
drivers/irqchip/irq-starfive-jh8100-intc.c +1 -1
@@ -158,7 +158,7 @@ static int __init starfive_intc_init(struct device_node *intc,raw_spin_lock_init (&irqc->lock); - irqc->domain =irq_domain_add_linear (intc,STARFIVE_INTC_SRC_IRQ_NUM , + irqc->domain =irq_domain_add_linear_of_node (intc,STARFIVE_INTC_SRC_IRQ_NUM , &starfive_intc_domain_ops, irqc);if (!irqc->domain) {pr_err ("Unable to create IRQ domain\n" );
drivers/irqchip/irq-stm32-exti.c +1 -1
@@ -344,7 +344,7 @@ static int __init stm32_exti_init(const struct stm32_exti_drv_data *drv_data,if (!host_data)return -ENOMEM ; - domain =irq_domain_add_linear (node, drv_data->bank_nr *IRQS_PER_BANK , + domain =irq_domain_add_linear_of_node (node, drv_data->bank_nr *IRQS_PER_BANK , &irq_exti_domain_ops,NULL );if (!domain) { pr_err("%pOFn: Could not register interrupt domain.\n",
drivers/irqchip/irq-stm32mp-exti.c +1 -1
@@ -682,7 +682,7 @@ static int stm32mp_exti_probe(struct platform_device *pdev)return -EINVAL ; } - domain =irq_domain_add_hierarchy (parent_domain,0 , + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 , drv_data->bank_nr *IRQS_PER_BANK , np, &stm32mp_exti_domain_ops, host_data);
drivers/irqchip/irq-sun4i.c +1 -1
@@ -133,7 +133,7 @@ static int __init sun4i_of_init(struct device_node *node,/* Configure the external interrupt source type */ writel (0x00 , irq_ic_data->irq_base +SUN4I_IRQ_NMI_CTRL_REG ); - irq_ic_data->irq_domain =irq_domain_add_linear (node,3 *32 , + irq_ic_data->irq_domain =irq_domain_add_linear_of_node (node,3 *32 , &sun4i_irq_ops,NULL );if (!irq_ic_data->irq_domain)panic ("%pOF: unable to create IRQ domain\n" , node);
drivers/irqchip/irq-sun6i-r.c +1 -1
@@ -338,7 +338,7 @@ static int __init sun6i_r_intc_init(struct device_node *node,return PTR_ERR (base); } - domain =irq_domain_add_hierarchy (parent_domain,0 ,0 , node, + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 ,0 , node, &sun6i_r_intc_domain_ops,NULL );if (!domain) {pr_err ("%pOF: Failed to allocate domain\n" , node);
drivers/irqchip/irq-sunxi-nmi.c +1 -1
@@ -152,7 +152,7 @@ static int __init sunxi_sc_nmi_irq_init(struct device_node *node,int ret; - domain =irq_domain_add_linear (node,1 , &irq_generic_chip_ops,NULL ); + domain =irq_domain_add_linear_of_node (node,1 , &irq_generic_chip_ops,NULL );if (!domain) {pr_err ("Could not register interrupt domain.\n" );return -ENOMEM ;
drivers/irqchip/irq-tb10x.c +1 -1
@@ -121,7 +121,7 @@ static int __init of_tb10x_init_irq(struct device_node *ictl, goto ioremap_fail; } - domain =irq_domain_add_linear (ictl,AB_IRQCTL_MAXIRQ , + domain =irq_domain_add_linear_of_node (ictl,AB_IRQCTL_MAXIRQ , &irq_generic_chip_ops,NULL );if (!domain) { ret = -ENOMEM ;
drivers/irqchip/irq-tegra.c +1 -1
@@ -330,7 +330,7 @@ static int __init tegra_ictlr_init(struct device_node *node, node, num_ictlrs, soc->num_ictlrs); - domain =irq_domain_add_hierarchy (parent_domain,0 , num_ictlrs *32 , + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 , num_ictlrs *32 , node, &tegra_ictlr_domain_ops, lic);if (!domain) {
drivers/irqchip/irq-ti-sci-inta.c +1 -1
@@ -701,7 +701,7 @@ static int ti_sci_inta_irq_domain_probe(struct platform_device *pdev)if (ret)return ret; - domain =irq_domain_add_linear (dev_of_node (dev), + domain =irq_domain_add_linear_of_node (dev_of_node (dev),ti_sci_get_num_resources (inta->vint), &ti_sci_inta_irq_domain_ops, inta);if (!domain) {
drivers/irqchip/irq-ti-sci-intr.c +1 -1
@@ -274,7 +274,7 @@ static int ti_sci_intr_irq_domain_probe(struct platform_device *pdev)return PTR_ERR (intr->out_irqs); } - domain =irq_domain_add_hierarchy (parent_domain,0 ,0 ,dev_of_node (dev), + domain =irq_domain_add_hierarchy_of_node (parent_domain,0 ,0 ,dev_of_node (dev), &ti_sci_intr_irq_domain_ops, intr);if (!domain) {dev_err (dev,"Failed to allocate IRQ domain\n" );
drivers/irqchip/irq-ts4800.c +1 -1
@@ -125,7 +125,7 @@ static int ts4800_ic_probe(struct platform_device *pdev)return -EINVAL ; } - data->domain =irq_domain_add_linear (node,8 , &ts4800_ic_ops, data); + data->domain =irq_domain_add_linear_of_node (node,8 , &ts4800_ic_ops, data);if (!data->domain) {dev_err (&pdev->dev,"cannot add IRQ domain\n" );return -ENOMEM ;
drivers/irqchip/irq-versatile-fpga.c +1 -1
@@ -176,7 +176,7 @@ static void __init fpga_irq_init(void __iomem *base, int parent_irq, f); } - f->domain =irq_domain_add_linear (node,fls (valid), + f->domain =irq_domain_add_linear_of_node (node,fls (valid), &fpga_irqdomain_ops, f);/* This will allocate all valid descriptors in the linear case */
drivers/irqchip/irq-vf610-mscm-ir.c +1 -1
@@ -209,7 +209,7 @@ static int __init vf610_mscm_ir_of_init(struct device_node *node,regmap_read (mscm_cp_regmap, MSCM_CPxNUM, &cpuid); mscm_ir_data->cpu_mask =0x1 << cpuid; - domain =irq_domain_add_hierarchy (domain_parent,0 , + domain =irq_domain_add_hierarchy_of_node (domain_parent,0 ,MSCM_IRSPRC_NUM , node, &mscm_irq_domain_ops, mscm_ir_data);if (!domain) {
drivers/irqchip/irq-vic.c +1 -1
@@ -289,7 +289,7 @@ static void __init vic_register(void __iomem *base, unsigned int parent_irq, vic_handle_irq_cascaded, v); } - v->domain =irq_domain_add_simple (node,fls (valid_sources), irq, + v->domain =irq_domain_add_simple_of_node (node,fls (valid_sources), irq, &vic_irqdomain_ops, v);/* create an IRQ mapping for each valid IRQ */ for (i =0 ; i <fls (valid_sources); i++)
drivers/irqchip/irq-vt8500.c +1 -1
@@ -200,7 +200,7 @@ static int __init vt8500_irq_init(struct device_node *node, } intc[active_cnt].base =of_iomap (np,0 ); - intc[active_cnt].domain =irq_domain_add_linear (node,64 , + intc[active_cnt].domain =irq_domain_add_linear_of_node (node,64 , &vt8500_irq_domain_ops, &intc[active_cnt]);if (!intc[active_cnt].base) {
drivers/irqchip/irq-wpcm450-aic.c +1 -1
@@ -154,7 +154,7 @@ static int __init wpcm450_aic_of_init(struct device_node *node,set_handle_irq (wpcm450_aic_handle_irq); - aic->domain =irq_domain_add_linear (node,AIC_NUM_IRQS , &wpcm450_aic_ops, aic); + aic->domain =irq_domain_add_linear_of_node (node,AIC_NUM_IRQS , &wpcm450_aic_ops, aic);return 0 ; }
drivers/irqchip/irq-xilinx-intc.c +1 -1
@@ -212,7 +212,7 @@ static int __init xilinx_intc_of_init(struct device_node *intc,xintc_write (irqc,MER ,MER_HIE |MER_ME ); } - irqc->root_domain =irq_domain_add_linear (intc, irqc->nr_irq, + irqc->root_domain =irq_domain_add_linear_of_node (intc, irqc->nr_irq, &xintc_irq_domain_ops, irqc);if (!irqc->root_domain) {pr_err ("irq-xilinx: Unable to create IRQ domain\n" );
drivers/irqchip/irq-xtensa-mx.c +2 -2
@@ -167,7 +167,7 @@ static void __init xtensa_mx_init_common(struct irq_domain *root_domain)int __init xtensa_mx_init_legacy (struct device_node *interrupt_parent) {struct irq_domain *root_domain = -irq_domain_add_legacy (NULL ,NR_IRQS -1 ,1 ,0 , +irq_domain_add_legacy_of_node (NULL ,NR_IRQS -1 ,1 ,0 , &xtensa_mx_irq_domain_ops, &xtensa_mx_irq_chip);xtensa_mx_init_common (root_domain);
@@ -178,7 +178,7 @@ static int __init xtensa_mx_init(struct device_node *np, struct device_node *interrupt_parent) {struct irq_domain *root_domain = -irq_domain_add_linear (np,NR_IRQS , &xtensa_mx_irq_domain_ops, +irq_domain_add_linear_of_node (np,NR_IRQS , &xtensa_mx_irq_domain_ops, &xtensa_mx_irq_chip);xtensa_mx_init_common (root_domain);return 0 ;
drivers/irqchip/irq-xtensa-pic.c +2 -2
@@ -85,7 +85,7 @@ static struct irq_chip xtensa_irq_chip = {int __init xtensa_pic_init_legacy (struct device_node *interrupt_parent) {struct irq_domain *root_domain = -irq_domain_add_legacy (NULL ,NR_IRQS -1 ,1 ,0 , +irq_domain_add_legacy_of_node (NULL ,NR_IRQS -1 ,1 ,0 , &xtensa_irq_domain_ops, &xtensa_irq_chip);irq_set_default_domain (root_domain);return 0 ;
@@ -95,7 +95,7 @@ static int __init xtensa_pic_init(struct device_node *np, struct device_node *interrupt_parent) {struct irq_domain *root_domain = -irq_domain_add_linear (np,NR_IRQS , &xtensa_irq_domain_ops, +irq_domain_add_linear_of_node (np,NR_IRQS , &xtensa_irq_domain_ops, &xtensa_irq_chip);irq_set_default_domain (root_domain);return 0 ;
drivers/irqchip/irq-zevio.c +1 -1
@@ -92,7 +92,7 @@ static int __init zevio_of_init(struct device_node *node,zevio_init_irq_base (zevio_irq_io +IO_IRQ_BASE );zevio_init_irq_base (zevio_irq_io +IO_FIQ_BASE ); - zevio_irq_domain =irq_domain_add_linear (node,MAX_INTRS , + zevio_irq_domain =irq_domain_add_linear_of_node (node,MAX_INTRS , &irq_generic_chip_ops,NULL );BUG_ON (!zevio_irq_domain);
drivers/irqchip/spear-shirq.c +1 -1
@@ -239,7 +239,7 @@ static int __init shirq_init(struct spear_shirq **shirq_blocks, int block_nr, goto err_unmap; } - shirq_domain =irq_domain_add_legacy (np, nr_irqs, virq_base,0 , + shirq_domain =irq_domain_add_legacy_of_node (np, nr_irqs, virq_base,0 , &irq_domain_simple_ops,NULL );if (WARN_ON (!shirq_domain)) {pr_warn ("%s: irq domain init failed\n" , __func__);
drivers/mailbox/qcom-ipcc.c +1 -1
@@ -296,7 +296,7 @@ static int qcom_ipcc_probe(struct platform_device *pdev)if (!name)return -ENOMEM ; - ipcc->irq_domain =irq_domain_add_tree (pdev->dev.of_node, + ipcc->irq_domain =irq_domain_add_tree_of_node (pdev->dev.of_node, &qcom_ipcc_irq_ops, ipcc);if (!ipcc->irq_domain)return -ENOMEM ;
drivers/memory/omap-gpmc.c +1 -1
@@ -1455,7 +1455,7 @@ static int gpmc_setup_irq(struct gpmc_device *gpmc) gpmc->irq_chip.irq_unmask = gpmc_irq_unmask; gpmc->irq_chip.irq_set_type = gpmc_irq_set_type; - gpmc_irq_domain =irq_domain_add_linear (gpmc->dev->of_node, + gpmc_irq_domain =irq_domain_add_linear_of_node (gpmc->dev->of_node, gpmc->nirqs, &gpmc_irq_domain_ops, gpmc);
drivers/mfd/88pm860x-core.c +1 -1
@@ -624,7 +624,7 @@ static int device_irq_init(struct pm860x_chip *chip, ret = -EBUSY ; goto out; } -irq_domain_add_legacy (node, nr_irqs, chip->irq_base,0 , +irq_domain_add_legacy_of_node (node, nr_irqs, chip->irq_base,0 , &pm860x_irq_domain_ops, chip); chip->core_irq = i2c->irq;if (!chip->core_irq)
drivers/mfd/ab8500-core.c +1 -1
@@ -580,7 +580,7 @@ static int ab8500_irq_init(struct ab8500 *ab8500, struct device_node *np) num_irqs =AB8500_NR_IRQS ;/* If ->irq_base is zero this will give a linear mapping */ - ab8500->domain =irq_domain_add_simple (ab8500->dev->of_node, + ab8500->domain =irq_domain_add_simple_of_node (ab8500->dev->of_node, num_irqs,0 , &ab8500_irq_ops, ab8500);
drivers/mfd/arizona-irq.c +1 -1
@@ -312,7 +312,7 @@ int arizona_irq_init(struct arizona *arizona) flags |= arizona->pdata.irq_flags;/* Allocate a virtual IRQ domain to distribute to the regmap domains */ - arizona->virq =irq_domain_add_linear (NULL ,2 , &arizona_domain_ops, + arizona->virq =irq_domain_add_linear_of_node (NULL ,2 , &arizona_domain_ops, arizona);if (!arizona->virq) {dev_err (arizona->dev,"Failed to add core IRQ domain\n" );
drivers/mfd/db8500-prcmu.c +1 -1
@@ -2607,7 +2607,7 @@ static int db8500_irq_init(struct device_node *np) {int i; - db8500_irq_domain =irq_domain_add_simple ( + db8500_irq_domain =irq_domain_add_simple_of_node ( np,NUM_PRCMU_WAKEUPS ,0 , &db8500_irq_ops,NULL );
drivers/mfd/fsl-imx25-tsadc.c +1 -1
@@ -72,7 +72,7 @@ static int mx25_tsadc_setup_irq(struct platform_device *pdev,if (irq <0 )return irq; - tsadc->domain =irq_domain_add_simple (np,2 ,0 , &mx25_tsadc_domain_ops, + tsadc->domain =irq_domain_add_simple_of_node (np,2 ,0 , &mx25_tsadc_domain_ops, tsadc);if (!tsadc->domain) {dev_err (dev,"Failed to add irq domain\n" );
drivers/mfd/lp8788-irq.c +1 -1
@@ -161,7 +161,7 @@ int lp8788_irq_init(struct lp8788 *lp, int irq)return -ENOMEM ; irqd->lp = lp; - irqd->domain =irq_domain_add_linear (lp->dev->of_node,LP8788_INT_MAX , + irqd->domain =irq_domain_add_linear_of_node (lp->dev->of_node,LP8788_INT_MAX , &lp8788_domain_ops, irqd);if (!irqd->domain) {dev_err (lp->dev,"failed to add irq domain err\n" );
drivers/mfd/max8925-core.c +1 -1
@@ -682,7 +682,7 @@ static int max8925_irq_init(struct max8925_chip *chip, int irq,return -EBUSY ; } -irq_domain_add_legacy (node,MAX8925_NR_IRQS , chip->irq_base,0 , +irq_domain_add_legacy_of_node (node,MAX8925_NR_IRQS , chip->irq_base,0 , &max8925_irq_domain_ops, chip);/* request irq handler for pmic main irq*/
drivers/mfd/max8997-irq.c +1 -1
@@ -327,7 +327,7 @@ int max8997_irq_init(struct max8997_dev *max8997) true : false; } - domain =irq_domain_add_linear (NULL ,MAX8997_IRQ_NR , + domain =irq_domain_add_linear_of_node (NULL ,MAX8997_IRQ_NR , &max8997_irq_domain_ops, max8997);if (!domain) {dev_err (max8997->dev,"could not create irq domain\n" );
drivers/mfd/max8998-irq.c +1 -1
@@ -230,7 +230,7 @@ int max8998_irq_init(struct max8998_dev *max8998)max8998_write_reg (max8998->i2c,MAX8998_REG_STATUSM1 ,0xff );max8998_write_reg (max8998->i2c,MAX8998_REG_STATUSM2 ,0xff ); - domain =irq_domain_add_simple (NULL ,MAX8998_IRQ_NR , + domain =irq_domain_add_simple_of_node (NULL ,MAX8998_IRQ_NR , max8998->irq_base, &max8998_irq_domain_ops, max8998);if (!domain) {dev_err (max8998->dev,"could not create irq domain\n" );
drivers/mfd/mt6358-irq.c +1 -1
@@ -272,7 +272,7 @@ int mt6358_irq_init(struct mt6397_chip *chip) irqd->pmic_ints[i].en_reg_shift * j, 0); } - chip->irq_domain =irq_domain_add_linear (chip->dev->of_node, + chip->irq_domain =irq_domain_add_linear_of_node (chip->dev->of_node, irqd->num_pmic_irqs, &mt6358_irq_domain_ops, chip);if (!chip->irq_domain) {
drivers/mfd/mt6397-irq.c +1 -1
@@ -216,7 +216,7 @@ int mt6397_irq_init(struct mt6397_chip *chip)regmap_write (chip->regmap, chip->int_con[2 ],0x0 ); chip->pm_nb.notifier_call = mt6397_irq_pm_notifier; - chip->irq_domain =irq_domain_add_linear (chip->dev->of_node, + chip->irq_domain =irq_domain_add_linear_of_node (chip->dev->of_node,MT6397_IRQ_NR , &mt6397_irq_domain_ops, chip);
drivers/mfd/qcom-pm8xxx.c +1 -1
@@ -559,7 +559,7 @@ static int pm8xxx_probe(struct platform_device *pdev) chip->pm_irq_data = data;spin_lock_init (&chip->pm_irq_lock); - chip->irqdomain =irq_domain_add_linear (pdev->dev.of_node, + chip->irqdomain =irq_domain_add_linear_of_node (pdev->dev.of_node, data->num_irqs, &pm8xxx_irq_domain_ops, chip);
drivers/mfd/stmfx.c +1 -1
@@ -269,7 +269,7 @@ static int stmfx_irq_init(struct i2c_client *client)u32 irqoutpin =0 , irqtrigger;int ret; - stmfx->irq_domain =irq_domain_add_simple (stmfx->dev->of_node, + stmfx->irq_domain =irq_domain_add_simple_of_node (stmfx->dev->of_node,STMFX_REG_IRQ_SRC_MAX ,0 , &stmfx_irq_ops, stmfx);if (!stmfx->irq_domain) {
drivers/mfd/stmpe.c +1 -1
@@ -1219,7 +1219,7 @@ static int stmpe_irq_init(struct stmpe *stmpe, struct device_node *np)int base =0 ;int num_irqs = stmpe->variant->num_irqs; - stmpe->domain =irq_domain_add_simple (np, num_irqs, base, + stmpe->domain =irq_domain_add_simple_of_node (np, num_irqs, base, &stmpe_irq_ops, stmpe);if (!stmpe->domain) {dev_err (stmpe->dev,"Failed to create irqdomain\n" );
drivers/mfd/tc3589x.c +1 -1
@@ -234,7 +234,7 @@ static const struct irq_domain_ops tc3589x_irq_ops = {static int tc3589x_irq_init (struct tc3589x *tc3589x,struct device_node *np) { - tc3589x->domain =irq_domain_add_simple ( + tc3589x->domain =irq_domain_add_simple_of_node ( np, TC3589x_NR_INTERNAL_IRQS,0 , &tc3589x_irq_ops, tc3589x);
drivers/mfd/tps65217.c +1 -1
@@ -158,7 +158,7 @@ static int tps65217_irq_init(struct tps65217 *tps, int irq)tps65217_set_bits (tps,TPS65217_REG_INT ,TPS65217_INT_MASK ,TPS65217_INT_MASK ,TPS65217_PROTECT_NONE ); - tps->irq_domain =irq_domain_add_linear (tps->dev->of_node, + tps->irq_domain =irq_domain_add_linear_of_node (tps->dev->of_node,TPS65217_NUM_IRQ , &tps65217_irq_domain_ops, tps);if (!tps->irq_domain) {dev_err (tps->dev,"Could not create IRQ domain\n" );
drivers/mfd/tps6586x.c +1 -1
@@ -363,7 +363,7 @@ static int tps6586x_irq_init(struct tps6586x *tps6586x, int irq, new_irq_base =0 ; } - tps6586x->irq_domain =irq_domain_add_simple (tps6586x->dev->of_node, + tps6586x->irq_domain =irq_domain_add_simple_of_node (tps6586x->dev->of_node, irq_num, new_irq_base, &tps6586x_domain_ops, tps6586x);if (!tps6586x->irq_domain) {
drivers/mfd/twl4030-irq.c +1 -1
@@ -691,7 +691,7 @@ int twl4030_init_irq(struct device *dev, int irq_num)return irq_base; } -irq_domain_add_legacy (node, nr_irqs, irq_base,0 , +irq_domain_add_legacy_of_node (node, nr_irqs, irq_base,0 , &irq_domain_simple_ops,NULL ); irq_end = irq_base +TWL4030_CORE_NR_IRQS ;
drivers/mfd/twl6030-irq.c +1 -1
@@ -412,7 +412,7 @@ int twl6030_init_irq(struct device *dev, int irq_num) twl6030_irq->irq_mapping_tbl = of_id->data; twl6030_irq->irq_domain = -irq_domain_add_linear (node, nr_irqs, +irq_domain_add_linear_of_node (node, nr_irqs, &twl6030_irq_domain_ops, twl6030_irq);if (!twl6030_irq->irq_domain) {dev_err (dev,"Can't add irq_domain\n" );
drivers/mfd/wm831x-irq.c +2 -2
@@ -587,13 +587,13 @@ int wm831x_irq_init(struct wm831x *wm831x, int irq) }if (irq_base) - domain =irq_domain_add_legacy (wm831x->dev->of_node, + domain =irq_domain_add_legacy_of_node (wm831x->dev->of_node,ARRAY_SIZE (wm831x_irqs), irq_base,0 , &wm831x_irq_domain_ops, wm831x);else - domain =irq_domain_add_linear (wm831x->dev->of_node, + domain =irq_domain_add_linear_of_node (wm831x->dev->of_node,ARRAY_SIZE (wm831x_irqs), &wm831x_irq_domain_ops, wm831x);
drivers/mfd/wm8994-irq.c +1 -1
@@ -213,7 +213,7 @@ int wm8994_irq_init(struct wm8994 *wm8994)return ret; } - wm8994->edge_irq =irq_domain_add_linear (NULL ,1 , + wm8994->edge_irq =irq_domain_add_linear_of_node (NULL ,1 , &wm8994_edge_irq_ops, wm8994);
drivers/misc/hi6421v600-irq.c +1 -1
@@ -254,7 +254,7 @@ static int hi6421v600_irq_probe(struct platform_device *pdev)if (!priv->irqs)return -ENOMEM ; - priv->domain =irq_domain_add_simple (np,PMIC_IRQ_LIST_MAX ,0 , + priv->domain =irq_domain_add_simple_of_node (np,PMIC_IRQ_LIST_MAX ,0 , &hi6421v600_domain_ops, priv);if (!priv->domain) {dev_err (dev,"Failed to create IRQ domain\n" );
drivers/net/dsa/microchip/ksz_common.c +1 -1
@@ -2697,7 +2697,7 @@ static int ksz_irq_common_setup(struct ksz_device *dev, struct ksz_irq *kirq) kirq->dev = dev; kirq->masked = ~0 ; - kirq->domain =irq_domain_add_simple (dev->dev->of_node, kirq->nirqs,0 , + kirq->domain =irq_domain_add_simple_of_node (dev->dev->of_node, kirq->nirqs,0 , &ksz_irq_domain_ops, kirq);if (!kirq->domain)return -ENOMEM ;
drivers/net/dsa/microchip/ksz_ptp.c +1 -1
@@ -1136,7 +1136,7 @@ int ksz_ptp_irq_setup(struct dsa_switch *ds, u8 p)init_completion (&port->tstamp_msg_comp); - ptpirq->domain =irq_domain_add_linear (dev->dev->of_node, ptpirq->nirqs, + ptpirq->domain =irq_domain_add_linear_of_node (dev->dev->of_node, ptpirq->nirqs, &ksz_ptp_irq_domain_ops, ptpirq);if (!ptpirq->domain)return -ENOMEM ;
drivers/net/dsa/mt7530.c +2 -2
@@ -2210,11 +2210,11 @@ mt7530_setup_irq(struct mt7530_priv *priv) }if (priv->id ==ID_MT7988 || priv->id ==ID_EN7581 ) - priv->irq_domain =irq_domain_add_linear (np,MT7530_NUM_PHYS , + priv->irq_domain =irq_domain_add_linear_of_node (np,MT7530_NUM_PHYS , &mt7988_irq_domain_ops, priv);else - priv->irq_domain =irq_domain_add_linear (np,MT7530_NUM_PHYS , + priv->irq_domain =irq_domain_add_linear_of_node (np,MT7530_NUM_PHYS , &mt7530_irq_domain_ops, priv);
drivers/net/dsa/mv88e6xxx/chip.c +1 -1
@@ -297,7 +297,7 @@ static int mv88e6xxx_g1_irq_setup_common(struct mv88e6xxx_chip *chip)u16 reg, mask; chip->g1_irq.nirqs = chip->info->g1_irqs; - chip->g1_irq.domain =irq_domain_add_simple ( + chip->g1_irq.domain =irq_domain_add_simple_of_node (NULL , chip->g1_irq.nirqs,0 , &mv88e6xxx_g1_irq_domain_ops, chip);if (!chip->g1_irq.domain)
drivers/net/dsa/mv88e6xxx/global2.c +1 -1
@@ -1154,7 +1154,7 @@ int mv88e6xxx_g2_irq_setup(struct mv88e6xxx_chip *chip)if (err)return err; - chip->g2_irq.domain =irq_domain_add_simple ( + chip->g2_irq.domain =irq_domain_add_simple_of_node ( chip->dev->of_node,16 ,0 , &mv88e6xxx_g2_irq_domain_ops, chip);if (!chip->g2_irq.domain)return -ENOMEM ;
drivers/net/dsa/qca/ar9331.c +1 -1
@@ -821,7 +821,7 @@ static int ar9331_sw_irq_init(struct ar9331_sw_priv *priv)return ret; } - priv->irqdomain =irq_domain_add_linear (np,1 , &ar9331_sw_irqdomain_ops, + priv->irqdomain =irq_domain_add_linear_of_node (np,1 , &ar9331_sw_irqdomain_ops, priv);if (!priv->irqdomain) {dev_err (dev,"failed to create IRQ domain\n" );
drivers/net/dsa/realtek/rtl8365mb.c +1 -1
@@ -1719,7 +1719,7 @@ static int rtl8365mb_irq_setup(struct realtek_priv *priv) goto out_put_node; } - priv->irqdomain =irq_domain_add_linear (intc, priv->num_ports, + priv->irqdomain =irq_domain_add_linear_of_node (intc, priv->num_ports, &rtl8365mb_irqdomain_ops, priv);if (!priv->irqdomain) {dev_err (priv->dev,"failed to add irq domain\n" );
drivers/net/dsa/realtek/rtl8366rb.c +1 -1
@@ -627,7 +627,7 @@ static int rtl8366rb_setup_cascaded_irq(struct realtek_priv *priv)dev_err (priv->dev,"unable to request irq: %d\n" , ret); goto out_put_node; } - priv->irqdomain =irq_domain_add_linear (intc, + priv->irqdomain =irq_domain_add_linear_of_node (intc,RTL8366RB_NUM_INTERRUPT , &rtl8366rb_irqdomain_ops, priv);
drivers/net/ethernet/wangxun/txgbe/txgbe_irq.c +1 -1
@@ -178,7 +178,7 @@ int txgbe_setup_misc_irq(struct txgbe *txgbe)int hwirq, err; txgbe->misc.nirqs =1 ; - txgbe->misc.domain =irq_domain_add_simple (NULL , txgbe->misc.nirqs,0 , + txgbe->misc.domain =irq_domain_add_simple_of_node (NULL , txgbe->misc.nirqs,0 , &txgbe_misc_irq_domain_ops, txgbe);if (!txgbe->misc.domain)return -ENOMEM ;
drivers/net/usb/lan78xx.c +1 -1
@@ -2475,7 +2475,7 @@ static int lan78xx_setup_irq_domain(struct lan78xx_net *dev) dev->domain_data.irqchip = &lan78xx_irqchip; dev->domain_data.irq_handler = handle_simple_irq; - irqdomain =irq_domain_add_simple (of_node,MAX_INT_EP ,0 , + irqdomain =irq_domain_add_simple_of_node (of_node,MAX_INT_EP ,0 , &chip_domain_ops, &dev->domain_data);if (irqdomain) {/* create mapping for PHY interrupt */
drivers/pci/controller/dwc/pci-dra7xx.c +1 -1
@@ -359,7 +359,7 @@ static int dra7xx_pcie_init_irq_domain(struct dw_pcie_rp *pp)irq_set_chained_handler_and_data (pp->irq, dra7xx_pcie_msi_irq_handler, pp); - dra7xx->irq_domain =irq_domain_add_linear (pcie_intc_node,PCI_NUM_INTX , + dra7xx->irq_domain =irq_domain_add_linear_of_node (pcie_intc_node,PCI_NUM_INTX , &intx_domain_ops, pp);of_node_put (pcie_intc_node);if (!dra7xx->irq_domain) {
drivers/pci/controller/dwc/pci-keystone.c +1 -1
@@ -761,7 +761,7 @@ static int ks_pcie_config_intx_irq(struct keystone_pcie *ks_pcie) ks_pcie); } - intx_irq_domain =irq_domain_add_linear (intc_np,PCI_NUM_INTX , + intx_irq_domain =irq_domain_add_linear_of_node (intc_np,PCI_NUM_INTX , &ks_pcie_intx_irq_domain_ops,NULL );if (!intx_irq_domain) {dev_err (dev,"Failed to add irq domain for INTX irqs\n" );
drivers/pci/controller/dwc/pcie-dw-rockchip.c +1 -1
@@ -144,7 +144,7 @@ static int rockchip_pcie_init_irq_domain(struct rockchip_pcie *rockchip)return -EINVAL ; } - rockchip->irq_domain =irq_domain_add_linear (intc,PCI_NUM_INTX , + rockchip->irq_domain =irq_domain_add_linear_of_node (intc,PCI_NUM_INTX , &intx_domain_ops, rockchip);of_node_put (intc);if (!rockchip->irq_domain) {
drivers/pci/controller/dwc/pcie-uniphier.c +1 -1
@@ -279,7 +279,7 @@ static int uniphier_pcie_config_intx_irq(struct dw_pcie_rp *pp) goto out_put_node; } - pcie->intx_irq_domain =irq_domain_add_linear (np_intc,PCI_NUM_INTX , + pcie->intx_irq_domain =irq_domain_add_linear_of_node (np_intc,PCI_NUM_INTX , &uniphier_intx_domain_ops, pp);if (!pcie->intx_irq_domain) {dev_err (pci->dev,"Failed to get INTx domain\n" );
drivers/pci/controller/mobiveil/pcie-mobiveil-host.c +2 -2
@@ -439,7 +439,7 @@ static int mobiveil_allocate_msi_domains(struct mobiveil_pcie *pcie)struct mobiveil_msi *msi = &pcie->rp.msi;mutex_init (&msi->lock); - msi->dev_domain =irq_domain_add_linear (NULL , msi->num_of_vectors, + msi->dev_domain =irq_domain_add_linear_of_node (NULL , msi->num_of_vectors, &msi_domain_ops, pcie);if (!msi->dev_domain) {dev_err (dev,"failed to create IRQ domain\n" );
@@ -465,7 +465,7 @@ static int mobiveil_pcie_init_irq_domain(struct mobiveil_pcie *pcie)struct mobiveil_root_port *rp = &pcie->rp;/* setup INTx */ - rp->intx_domain =irq_domain_add_linear (node,PCI_NUM_INTX , + rp->intx_domain =irq_domain_add_linear_of_node (node,PCI_NUM_INTX , &intx_domain_ops, pcie);if (!rp->intx_domain) {
drivers/pci/controller/pci-aardvark.c +3 -3
@@ -1457,7 +1457,7 @@ static int advk_pcie_init_msi_irq_domain(struct advk_pcie *pcie)mutex_init (&pcie->msi_used_lock); pcie->msi_inner_domain = -irq_domain_add_linear (NULL ,MSI_IRQ_NUM , +irq_domain_add_linear_of_node (NULL ,MSI_IRQ_NUM , &advk_msi_domain_ops, pcie);if (!pcie->msi_inner_domain)return -ENOMEM ;
@@ -1509,7 +1509,7 @@ static int advk_pcie_init_irq_domain(struct advk_pcie *pcie) irq_chip->irq_unmask = advk_pcie_irq_unmask; pcie->irq_domain = -irq_domain_add_linear (pcie_intc_node,PCI_NUM_INTX , +irq_domain_add_linear_of_node (pcie_intc_node,PCI_NUM_INTX , &advk_pcie_irq_domain_ops, pcie);if (!pcie->irq_domain) {dev_err (dev,"Failed to get a INTx IRQ domain\n" );
@@ -1549,7 +1549,7 @@ static const struct irq_domain_ops advk_pcie_rp_irq_domain_ops = {static int advk_pcie_init_rp_irq_domain (struct advk_pcie *pcie) { - pcie->rp_irq_domain =irq_domain_add_linear (NULL ,1 , + pcie->rp_irq_domain =irq_domain_add_linear_of_node (NULL ,1 , &advk_pcie_rp_irq_domain_ops, pcie);if (!pcie->rp_irq_domain) {
drivers/pci/controller/pci-ftpci100.c +1 -1
@@ -345,7 +345,7 @@ static int faraday_pci_setup_cascaded_irq(struct faraday_pci *p)return irq ?: -EINVAL ; } - p->irqdomain =irq_domain_add_linear (intc,PCI_NUM_INTX , + p->irqdomain =irq_domain_add_linear_of_node (intc,PCI_NUM_INTX , &faraday_pci_irqdomain_ops, p);of_node_put (intc);if (!p->irqdomain) {
drivers/pci/controller/pci-mvebu.c +1 -1
@@ -1078,7 +1078,7 @@ static int mvebu_pcie_init_irq_domain(struct mvebu_pcie_port *port)return -ENODEV ; } - port->intx_irq_domain =irq_domain_add_linear (pcie_intc_node,PCI_NUM_INTX , + port->intx_irq_domain =irq_domain_add_linear_of_node (pcie_intc_node,PCI_NUM_INTX , &mvebu_pcie_intx_irq_domain_ops, port);of_node_put (pcie_intc_node);
drivers/pci/controller/pci-xgene-msi.c +1 -1
@@ -242,7 +242,7 @@ static const struct irq_domain_ops msi_domain_ops = {static int xgene_allocate_domains (struct xgene_msi *msi) { - msi->inner_domain =irq_domain_add_linear (NULL ,NR_MSI_VEC , + msi->inner_domain =irq_domain_add_linear_of_node (NULL ,NR_MSI_VEC , &msi_domain_ops, msi);if (!msi->inner_domain)return -ENOMEM ;
drivers/pci/controller/pcie-altera-msi.c +1 -1
@@ -166,7 +166,7 @@ static int altera_allocate_domains(struct altera_msi *msi) {struct fwnode_handle *fwnode =of_fwnode_handle (msi->pdev->dev.of_node); - msi->inner_domain =irq_domain_add_linear (NULL , msi->num_of_vectors, + msi->inner_domain =irq_domain_add_linear_of_node (NULL , msi->num_of_vectors, &msi_domain_ops, msi);if (!msi->inner_domain) {dev_err (&msi->pdev->dev,"failed to create IRQ domain\n" );
drivers/pci/controller/pcie-altera.c +1 -1
@@ -669,7 +669,7 @@ static int altera_pcie_init_irq_domain(struct altera_pcie *pcie)struct device_node *node = dev->of_node;/* Setup INTx */ - pcie->irq_domain =irq_domain_add_linear (node,PCI_NUM_INTX , + pcie->irq_domain =irq_domain_add_linear_of_node (node,PCI_NUM_INTX , &intx_domain_ops, pcie);if (!pcie->irq_domain) {dev_err (dev,"Failed to get a INTx IRQ domain\n" );
drivers/pci/controller/pcie-brcmstb.c +1 -1
@@ -575,7 +575,7 @@ static int brcm_allocate_domains(struct brcm_msi *msi)struct fwnode_handle *fwnode =of_fwnode_handle (msi->np);struct device *dev = msi->dev; - msi->inner_domain =irq_domain_add_linear (NULL , msi->nr, &msi_domain_ops, msi); + msi->inner_domain =irq_domain_add_linear_of_node (NULL , msi->nr, &msi_domain_ops, msi);if (!msi->inner_domain) {dev_err (dev,"failed to create IRQ domain\n" );return -ENOMEM ;
drivers/pci/controller/pcie-iproc-msi.c +1 -1
@@ -446,7 +446,7 @@ static void iproc_msi_disable(struct iproc_msi *msi)static int iproc_msi_alloc_domains (struct device_node *node,struct iproc_msi *msi) { - msi->inner_domain =irq_domain_add_linear (NULL , msi->nr_msi_vecs, + msi->inner_domain =irq_domain_add_linear_of_node (NULL , msi->nr_msi_vecs, &msi_domain_ops, msi);if (!msi->inner_domain)return -ENOMEM ;
drivers/pci/controller/pcie-mediatek-gen3.c +2 -2
@@ -745,7 +745,7 @@ static int mtk_pcie_init_irq_domains(struct mtk_gen3_pcie *pcie)return -ENODEV ; } - pcie->intx_domain =irq_domain_add_linear (intc_node,PCI_NUM_INTX , + pcie->intx_domain =irq_domain_add_linear_of_node (intc_node,PCI_NUM_INTX , &intx_domain_ops, pcie);if (!pcie->intx_domain) {dev_err (dev,"failed to create INTx IRQ domain\n" );
@@ -756,7 +756,7 @@ static int mtk_pcie_init_irq_domains(struct mtk_gen3_pcie *pcie)/* Setup MSI */ mutex_init (&pcie->lock); - pcie->msi_bottom_domain =irq_domain_add_linear (node,PCIE_MSI_IRQS_NUM , + pcie->msi_bottom_domain =irq_domain_add_linear_of_node (node,PCIE_MSI_IRQS_NUM , &mtk_msi_bottom_domain_ops, pcie);if (!pcie->msi_bottom_domain) {dev_err (dev,"failed to create MSI bottom domain\n" );
drivers/pci/controller/pcie-mediatek.c +1 -1
@@ -569,7 +569,7 @@ static int mtk_pcie_init_irq_domain(struct mtk_pcie_port *port,return -ENODEV ; } - port->irq_domain =irq_domain_add_linear (pcie_intc_node,PCI_NUM_INTX , + port->irq_domain =irq_domain_add_linear_of_node (pcie_intc_node,PCI_NUM_INTX , &intx_domain_ops, port);of_node_put (pcie_intc_node);if (!port->irq_domain) {
drivers/pci/controller/pcie-rockchip-host.c +1 -1
@@ -693,7 +693,7 @@ static int rockchip_pcie_init_irq_domain(struct rockchip_pcie *rockchip)return -EINVAL ; } - rockchip->irq_domain =irq_domain_add_linear (intc,PCI_NUM_INTX , + rockchip->irq_domain =irq_domain_add_linear_of_node (intc,PCI_NUM_INTX , &intx_domain_ops, rockchip);of_node_put (intc);if (!rockchip->irq_domain) {
drivers/pci/controller/pcie-xilinx-cpm.c +2 -2
@@ -394,7 +394,7 @@ static int xilinx_cpm_pcie_init_irq_domain(struct xilinx_cpm_pcie *port)return -EINVAL ; } - port->cpm_domain =irq_domain_add_linear (pcie_intc_node,32 , + port->cpm_domain =irq_domain_add_linear_of_node (pcie_intc_node,32 , &event_domain_ops, port);if (!port->cpm_domain)
@@ -402,7 +402,7 @@ static int xilinx_cpm_pcie_init_irq_domain(struct xilinx_cpm_pcie *port)irq_domain_update_bus_token (port->cpm_domain,DOMAIN_BUS_NEXUS ); - port->intx_domain =irq_domain_add_linear (pcie_intc_node,PCI_NUM_INTX , + port->intx_domain =irq_domain_add_linear_of_node (pcie_intc_node,PCI_NUM_INTX , &intx_domain_ops, port);if (!port->intx_domain)
drivers/pci/controller/pcie-xilinx-dma-pl.c +3 -3
@@ -472,7 +472,7 @@ static int xilinx_pl_dma_pcie_init_msi_irq_domain(struct pl_dma_pcie *port)int size =BITS_TO_LONGS (XILINX_NUM_MSI_IRQS ) *sizeof (long );struct fwnode_handle *fwnode =of_fwnode_handle (port->dev->of_node); - msi->dev_domain =irq_domain_add_linear (NULL ,XILINX_NUM_MSI_IRQS , + msi->dev_domain =irq_domain_add_linear_of_node (NULL ,XILINX_NUM_MSI_IRQS , &dev_msi_domain_ops, port);if (!msi->dev_domain) goto out;
@@ -585,14 +585,14 @@ static int xilinx_pl_dma_pcie_init_irq_domain(struct pl_dma_pcie *port)return -EINVAL ; } - port->pldma_domain =irq_domain_add_linear (pcie_intc_node,32 , + port->pldma_domain =irq_domain_add_linear_of_node (pcie_intc_node,32 , &event_domain_ops, port);if (!port->pldma_domain)return -ENOMEM ;irq_domain_update_bus_token (port->pldma_domain,DOMAIN_BUS_NEXUS ); - port->intx_domain =irq_domain_add_linear (pcie_intc_node,PCI_NUM_INTX , + port->intx_domain =irq_domain_add_linear_of_node (pcie_intc_node,PCI_NUM_INTX , &intx_domain_ops, port);if (!port->intx_domain) {dev_err (dev,"Failed to get a INTx IRQ domain\n" );
drivers/pci/controller/pcie-xilinx-nwl.c +2 -2
@@ -498,7 +498,7 @@ static int nwl_pcie_init_msi_irq_domain(struct nwl_pcie *pcie)struct fwnode_handle *fwnode =of_fwnode_handle (dev->of_node);struct nwl_msi *msi = &pcie->msi; - msi->dev_domain =irq_domain_add_linear (NULL ,INT_PCI_MSI_NR , + msi->dev_domain =irq_domain_add_linear_of_node (NULL ,INT_PCI_MSI_NR , &dev_msi_domain_ops, pcie);if (!msi->dev_domain) {dev_err (dev,"failed to create dev IRQ domain\n" );
@@ -582,7 +582,7 @@ static int nwl_pcie_init_irq_domain(struct nwl_pcie *pcie)return -EINVAL ; } - pcie->intx_irq_domain =irq_domain_add_linear (intc_node, + pcie->intx_irq_domain =irq_domain_add_linear_of_node (intc_node,PCI_NUM_INTX , &intx_domain_ops, pcie);
drivers/pci/controller/pcie-xilinx.c +1 -1
@@ -461,7 +461,7 @@ static int xilinx_pcie_init_irq_domain(struct xilinx_pcie *pcie)return -ENODEV ; } - pcie->leg_domain =irq_domain_add_linear (pcie_intc_node,PCI_NUM_INTX , + pcie->leg_domain =irq_domain_add_linear_of_node (pcie_intc_node,PCI_NUM_INTX , &intx_domain_ops, pcie);of_node_put (pcie_intc_node);
drivers/pci/controller/plda/pcie-plda-host.c +3 -3
@@ -152,7 +152,7 @@ static int plda_allocate_msi_domains(struct plda_pcie_rp *port)mutex_init (&port->msi.lock); - msi->dev_domain =irq_domain_add_linear (NULL , msi->num_vectors, + msi->dev_domain =irq_domain_add_linear_of_node (NULL , msi->num_vectors, &msi_domain_ops, port);if (!msi->dev_domain) {dev_err (dev,"failed to create IRQ domain\n" );
@@ -390,7 +390,7 @@ static int plda_pcie_init_irq_domains(struct plda_pcie_rp *port)return -EINVAL ; } - port->event_domain =irq_domain_add_linear (pcie_intc_node, + port->event_domain =irq_domain_add_linear_of_node (pcie_intc_node, port->num_events, &plda_event_domain_ops, port);
@@ -402,7 +402,7 @@ static int plda_pcie_init_irq_domains(struct plda_pcie_rp *port)irq_domain_update_bus_token (port->event_domain,DOMAIN_BUS_NEXUS ); - port->intx_domain =irq_domain_add_linear (pcie_intc_node,PCI_NUM_INTX , + port->intx_domain =irq_domain_add_linear_of_node (pcie_intc_node,PCI_NUM_INTX , &intx_domain_ops, port);if (!port->intx_domain) {dev_err (dev,"failed to get an INTx IRQ domain\n" );
drivers/pinctrl/mediatek/mtk-eint.c +1 -1
@@ -508,7 +508,7 @@ int mtk_eint_do_init(struct mtk_eint *eint)if (!eint->dual_edge)return -ENOMEM ; - eint->domain =irq_domain_add_linear (eint->dev->of_node, + eint->domain =irq_domain_add_linear_of_node (eint->dev->of_node, eint->hw->ap_num, &irq_domain_simple_ops,NULL );if (!eint->domain)
drivers/pinctrl/pinctrl-at91-pio4.c +1 -1
@@ -1206,7 +1206,7 @@ static int atmel_pinctrl_probe(struct platform_device *pdev)dev_dbg (dev,"bank %i: irq=%d\n" , i, ret); } - atmel_pioctrl->irq_domain =irq_domain_add_linear (dev->of_node, + atmel_pioctrl->irq_domain =irq_domain_add_linear_of_node (dev->of_node, atmel_pioctrl->gpio_chip->ngpio, &irq_domain_simple_ops,NULL );if (!atmel_pioctrl->irq_domain)
drivers/pinctrl/pinctrl-single.c +2 -2
@@ -1611,13 +1611,13 @@ static int pcs_irq_init_chained_handler(struct pcs_device *pcs,/* * We can use the register offset as the hardirq -* number as irq_domain_add_simple maps them lazily. +* number as irq_domain_add_simple_of_node maps them lazily. * This way we can easily support more than one * interrupt per function if needed. */ num_irqs = pcs->size; - pcs->domain =irq_domain_add_simple (np, num_irqs,0 , + pcs->domain =irq_domain_add_simple_of_node (np, num_irqs,0 , &pcs_irqdomain_ops, pcs_soc);if (!pcs->domain) {
drivers/pinctrl/sunxi/pinctrl-sunxi.c +1 -1
@@ -1626,7 +1626,7 @@ int sunxi_pinctrl_init_with_variant(struct platform_device *pdev, } } - pctl->domain =irq_domain_add_linear (node, + pctl->domain =irq_domain_add_linear_of_node (node, pctl->desc->irq_banks *IRQ_PER_BANK , &sunxi_pinctrl_irq_domain_ops, pctl);
drivers/platform/x86/asus-tf103c-dock.c +1 -1
@@ -856,7 +856,7 @@ static int tf103c_dock_probe(struct i2c_client *client)/* 5. Setup irqchip for touchpad IRQ pass-through */ dock->tp_irqchip.name =KBUILD_MODNAME ; - dock->tp_irq_domain =irq_domain_add_linear (NULL ,1 , &irq_domain_simple_ops,NULL ); + dock->tp_irq_domain =irq_domain_add_linear_of_node (NULL ,1 , &irq_domain_simple_ops,NULL );if (!dock->tp_irq_domain)return -ENOMEM ;
drivers/sh/intc/irqdomain.c +2 -2
@@ -59,10 +59,10 @@ void __init intc_irq_domain_init(struct intc_desc_int *d,* tree penalty for linear cases with non-zero hwirq bases. */ if (irq_base ==0 && irq_end == (irq_base + hw->nr_vectors -1 )) - d->domain =irq_domain_add_linear (NULL , hw->nr_vectors, + d->domain =irq_domain_add_linear_of_node (NULL , hw->nr_vectors, &intc_evt_ops,NULL );else - d->domain =irq_domain_add_tree (NULL , &intc_evt_ops,NULL ); + d->domain =irq_domain_add_tree_of_node (NULL , &intc_evt_ops,NULL );BUG_ON (!d->domain); }
drivers/soc/dove/pmu.c +1 -1
@@ -274,7 +274,7 @@ static int __init dove_init_pmu_irq(struct pmu_data *pmu, int irq)writel (0 , pmu->pmc_base +PMC_IRQ_MASK );writel (0 , pmu->pmc_base +PMC_IRQ_CAUSE ); - domain =irq_domain_add_linear (pmu->of_node,NR_PMU_IRQS , + domain =irq_domain_add_linear_of_node (pmu->of_node,NR_PMU_IRQS , &irq_generic_chip_ops,NULL );if (!domain) {pr_err ("%s: unable to add irq domain\n" , name);
drivers/soc/fsl/qe/qe_ic.c +1 -1
@@ -446,7 +446,7 @@ static int qe_ic_init(struct platform_device *pdev) high_handler =NULL ; } - qe_ic->irqhost =irq_domain_add_linear (node,NR_QE_IC_INTS , + qe_ic->irqhost =irq_domain_add_linear_of_node (node,NR_QE_IC_INTS , &qe_ic_host_ops, qe_ic);if (qe_ic->irqhost ==NULL ) {dev_err (dev,"failed to add irq domain\n" );
drivers/soc/qcom/smp2p.c +1 -1
@@ -399,7 +399,7 @@ static int qcom_smp2p_inbound_entry(struct qcom_smp2p *smp2p,struct smp2p_entry *entry, struct device_node *node) { - entry->domain = irq_domain_add_linear(node, 32, &smp2p_irq_ops, entry); + entry->domain = irq_domain_add_linear_of_node(node, 32, &smp2p_irq_ops, entry);if (!entry->domain) {dev_err (smp2p->dev,"failed to add irq_domain\n" );return -ENOMEM ;
drivers/soc/qcom/smsm.c +1 -1
@@ -456,7 +456,7 @@ static int smsm_inbound_entry(struct qcom_smsm *smsm,return ret; } - entry->domain =irq_domain_add_linear (node,32 , &smsm_irq_ops, entry); + entry->domain =irq_domain_add_linear_of_node (node,32 , &smsm_irq_ops, entry);if (!entry->domain) {dev_err (smsm->dev,"failed to add irq_domain\n" );return -ENOMEM ;
drivers/soc/tegra/pmc.c +1 -1
@@ -2499,7 +2499,7 @@ static int tegra_pmc_irq_init(struct tegra_pmc *pmc) pmc->irq.irq_set_type = pmc->soc->irq_set_type; pmc->irq.irq_set_wake = pmc->soc->irq_set_wake; - pmc->domain =irq_domain_add_hierarchy (parent,0 ,96 , pmc->dev->of_node, + pmc->domain =irq_domain_add_hierarchy_of_node (parent,0 ,96 , pmc->dev->of_node, &tegra_pmc_irq_domain_ops, pmc);if (!pmc->domain) {dev_err (pmc->dev,"failed to allocate domain\n" );
drivers/spmi/spmi-pmic-arb.c +1 -1
@@ -1737,7 +1737,7 @@ static int spmi_pmic_arb_bus_init(struct platform_device *pdev,dev_dbg (&pdev->dev,"adding irq domain for bus %d\n" , bus_index); - bus->domain =irq_domain_add_tree (node, &pmic_arb_irq_domain_ops, bus); + bus->domain =irq_domain_add_tree_of_node (node, &pmic_arb_irq_domain_ops, bus);if (!bus->domain) {dev_err (&pdev->dev,"unable to create irq_domain\n" );return -ENOMEM ;
drivers/ssb/driver_gpio.c +2 -2
@@ -148,7 +148,7 @@ static int ssb_gpio_irq_chipco_domain_init(struct ssb_bus *bus)if (bus->bustype !=SSB_BUSTYPE_SSB )return 0 ; - bus->irq_domain =irq_domain_add_linear (NULL , chip->ngpio, + bus->irq_domain =irq_domain_add_linear_of_node (NULL , chip->ngpio, &irq_domain_simple_ops, chipco);if (!bus->irq_domain) { err = -ENODEV ;
@@ -347,7 +347,7 @@ static int ssb_gpio_irq_extif_domain_init(struct ssb_bus *bus)if (bus->bustype !=SSB_BUSTYPE_SSB )return 0 ; - bus->irq_domain =irq_domain_add_linear (NULL , chip->ngpio, + bus->irq_domain =irq_domain_add_linear_of_node (NULL , chip->ngpio, &irq_domain_simple_ops, extif);if (!bus->irq_domain) { err = -ENODEV ;
drivers/thermal/qcom/lmh.c +1 -1
@@ -209,7 +209,7 @@ static int lmh_probe(struct platform_device *pdev) } lmh_data->irq =platform_get_irq (pdev,0 ); - lmh_data->domain =irq_domain_add_linear (np,1 , &lmh_irq_ops, lmh_data); + lmh_data->domain =irq_domain_add_linear_of_node (np,1 , &lmh_irq_ops, lmh_data);if (!lmh_data->domain) {dev_err (dev,"Error adding irq_domain\n" );return -EINVAL ;
drivers/thermal/tegra/soctherm.c +1 -1
@@ -1234,7 +1234,7 @@ static int soctherm_oc_int_init(struct device_node *np, int num_irqs) soc_irq_cdata.irq_chip.irq_set_type = soctherm_oc_irq_set_type; soc_irq_cdata.irq_chip.irq_set_wake =NULL ; - soc_irq_cdata.domain =irq_domain_add_linear (np, num_irqs, + soc_irq_cdata.domain =irq_domain_add_linear_of_node (np, num_irqs, &soctherm_oc_domain_ops, &soc_irq_cdata);
include/linux/gpio/driver.h +1 -1
@@ -286,7 +286,7 @@ struct gpio_irq_chip {/** * @first: * -* Required for static IRQ allocation. If set, irq_domain_add_simple() +* Required for static IRQ allocation. If set, irq_domain_add_simple_of_node() * will allocate and map all IRQs during initialization. */ unsigned int first;
include/linux/irqdomain.h +8 -8
@@ -346,7 +346,7 @@ struct irq_domain *irq_domain_create_legacy(struct fwnode_handle *fwnode, void *host_data);/** -* irq_domain_add_legacy() - Allocate and register a legacy revmap irq_domain. +* irq_domain_add_legacy_of_node() - Allocate and register a legacy revmap irq_domain. * @of_node: pointer to interrupt controller's device tree node. * @size: total number of irqs in legacy mapping * @first_irq: first number of irq block assigned to the domain
@@ -360,7 +360,7 @@ struct irq_domain *irq_domain_create_legacy(struct fwnode_handle *fwnode,* for all legacy interrupts except 0 (which is always the invalid irq for * a legacy controller). */ -static inline struct irq_domain *irq_domain_add_legacy(struct device_node *of_node, +static inline struct irq_domain *irq_domain_add_legacy_of_node(struct device_node *of_node, unsigned int size, unsigned int first_irq, irq_hw_number_t first_hwirq,
@@ -417,7 +417,7 @@ static inline struct irq_domain *irq_find_host(struct device_node *node)return d; } -static inline struct irq_domain *irq_domain_add_simple(struct device_node *of_node, +static inline struct irq_domain *irq_domain_add_simple_of_node(struct device_node *of_node, unsigned int size, unsigned int first_irq, const struct irq_domain_ops *ops,
@@ -427,13 +427,13 @@ static inline struct irq_domain *irq_domain_add_simple(struct device_node *of_no }/** -* irq_domain_add_linear() - Allocate and register a linear revmap irq_domain. +* irq_domain_add_linear_of_node() - Allocate and register a linear revmap irq_domain. * @of_node: pointer to interrupt controller's device tree node. * @size: Number of interrupts in the domain. * @ops: map/unmap domain callbacks * @host_data: Controller private data pointer */ -static inline struct irq_domain *irq_domain_add_linear (struct device_node *of_node, +static inline struct irq_domain *irq_domain_add_linear_of_node (struct device_node *of_node,unsigned int size,const struct irq_domain_ops *ops,void *host_data)
@@ -451,7 +451,7 @@ static inline struct irq_domain *irq_domain_add_linear(struct device_node *of_no }#ifdef CONFIG_IRQ_DOMAIN_NOMAP -static inline struct irq_domain *irq_domain_add_nomap (struct device_node *of_node, +static inline struct irq_domain *irq_domain_add_nomap_of_node (struct device_node *of_node,unsigned int max_irq,const struct irq_domain_ops *ops,void *host_data)
@@ -471,7 +471,7 @@ static inline struct irq_domain *irq_domain_add_nomap(struct device_node *of_nodunsigned int irq_create_direct_mapping (struct irq_domain *domain);#endif -static inline struct irq_domain *irq_domain_add_tree (struct device_node *of_node, +static inline struct irq_domain *irq_domain_add_tree_of_node (struct device_node *of_node,const struct irq_domain_ops *ops,void *host_data) {
@@ -643,7 +643,7 @@ static inline struct irq_domain *irq_domain_create_hierarchy(struct irq_domain *return IS_ERR (d) ?NULL : d; } -static inline struct irq_domain *irq_domain_add_hierarchy(struct irq_domain *parent, +static inline struct irq_domain *irq_domain_add_hierarchy_of_node(struct irq_domain *parent, unsigned int flags, unsigned int size, struct device_node *node,
sound/soc/codecs/wcd937x.c +1 -1
@@ -2472,7 +2472,7 @@ static const struct irq_domain_ops wcd_domain_ops = {static int wcd937x_irq_init (struct wcd937x_priv *wcd,struct device *dev) { - wcd->virq =irq_domain_add_linear (NULL ,1 , &wcd_domain_ops,NULL ); + wcd->virq =irq_domain_add_linear_of_node (NULL ,1 , &wcd_domain_ops,NULL );if (!(wcd->virq)) {dev_err (dev,"%s: Failed to add IRQ domain\n" , __func__);return -EINVAL ;
sound/soc/codecs/wcd938x.c +1 -1
@@ -3030,7 +3030,7 @@ static const struct irq_domain_ops wcd_domain_ops = {static int wcd938x_irq_init (struct wcd938x_priv *wcd,struct device *dev) { - wcd->virq =irq_domain_add_linear (NULL ,1 , &wcd_domain_ops,NULL ); + wcd->virq =irq_domain_add_linear_of_node (NULL ,1 , &wcd_domain_ops,NULL );if (!(wcd->virq)) {dev_err (dev,"%s: Failed to add IRQ domain\n" , __func__);return -EINVAL ;
sound/soc/codecs/wcd939x.c +1 -1
@@ -2975,7 +2975,7 @@ static const struct irq_domain_ops wcd_domain_ops = {static int wcd939x_irq_init (struct wcd939x_priv *wcd,struct device *dev) { - wcd->virq =irq_domain_add_linear (NULL ,1 , &wcd_domain_ops,NULL ); + wcd->virq =irq_domain_add_linear_of_node (NULL ,1 , &wcd_domain_ops,NULL );if (!(wcd->virq)) {dev_err (dev,"%s: Failed to add IRQ domain\n" , __func__);return -EINVAL ;
Signature · 1 line
2.48.0
PATCH 10/18 irqdomain: Rename _create functions to _add_*_fwnode
In reply to Jiri Slaby (SUSE)Continuing the unifying idea of the previous patch, all "_create" functions are renamed to "_add" and appended with a "_fwnode" suffix.
Now, the interface is:
* dom = irq_domain_add_linear_fwnode(fwnode, ...)
* irq_domain_remove(dom)
Note: Sorry, I am not capable of wrapping chinese text properly.
--- Documentation/core-api/irq/irq-domain.rst | 42 +++++++++---------- .../driver-api/driver-model/devres.rst | 2 +- .../zh_CN/core-api/irq/irq-domain.rst | 22 +++++----- arch/arm64/kvm/arch_timer.c | 2 +- arch/mips/pci/pci-xtalk-bridge.c | 2 +- arch/mips/sgi-ip27/ip27-irq.c | 2 +- arch/mips/sgi-ip30/ip30-irq.c | 2 +- arch/powerpc/platforms/powernv/pci-ioda.c | 2 +- arch/powerpc/platforms/pseries/msi.c | 2 +- arch/powerpc/sysdev/xics/xics-common.c | 2 +- arch/powerpc/sysdev/xive/common.c | 2 +- arch/x86/kernel/apic/io_apic.c | 2 +- arch/x86/kernel/apic/vector.c | 2 +- arch/x86/platform/uv/uv_irq.c | 2 +- drivers/acpi/irq.c | 2 +- drivers/gpio/gpio-bcm-kona.c | 2 +- drivers/gpio/gpio-mockup.c | 2 +- drivers/gpio/gpio-mpc8xxx.c | 2 +- drivers/gpio/gpio-sim.c | 2 +- drivers/gpio/gpio-uniphier.c | 2 +- drivers/gpio/gpio-xgene-sb.c | 2 +- drivers/gpio/gpiolib.c | 4 +- drivers/hid/hid-rmi.c | 2 +- drivers/i2c/i2c-core-base.c | 2 +- drivers/iio/dummy/iio_dummy_evgen.c | 2 +- drivers/input/rmi4/rmi_driver.c | 2 +- drivers/iommu/amd/init.c | 2 +- drivers/iommu/amd/iommu.c | 2 +- drivers/iommu/hyperv-iommu.c | 2 +- drivers/iommu/intel/irq_remapping.c | 2 +- drivers/irqchip/irq-apple-aic.c | 2 +- drivers/irqchip/irq-armada-370-xp.c | 2 +- drivers/irqchip/irq-bcm2836.c | 2 +- drivers/irqchip/irq-gic-v2m.c | 2 +- drivers/irqchip/irq-gic-v3-its.c | 2 +- drivers/irqchip/irq-gic-v3-mbi.c | 2 +- drivers/irqchip/irq-gic-v3.c | 2 +- drivers/irqchip/irq-gic-v4.c | 4 +- drivers/irqchip/irq-gic.c | 2 +- drivers/irqchip/irq-imx-mu-msi.c | 2 +- drivers/irqchip/irq-ixp4xx.c | 2 +- drivers/irqchip/irq-loongarch-avec.c | 2 +- drivers/irqchip/irq-loongarch-cpu.c | 4 +- drivers/irqchip/irq-loongson-eiointc.c | 2 +- drivers/irqchip/irq-loongson-htvec.c | 2 +- drivers/irqchip/irq-loongson-liointc.c | 4 +- drivers/irqchip/irq-loongson-pch-lpc.c | 2 +- drivers/irqchip/irq-loongson-pch-msi.c | 2 +- drivers/irqchip/irq-loongson-pch-pic.c | 2 +- drivers/irqchip/irq-meson-gpio.c | 2 +- drivers/irqchip/irq-mvebu-gicp.c | 2 +- drivers/irqchip/irq-mvebu-odmi.c | 2 +- drivers/irqchip/irq-mvebu-sei.c | 6 +-- drivers/irqchip/irq-partition-percpu.c | 2 +- drivers/irqchip/irq-qcom-mpm.c | 2 +- drivers/irqchip/irq-rda-intc.c | 2 +- drivers/irqchip/irq-riscv-aplic-direct.c | 2 +- drivers/irqchip/irq-riscv-imsic-platform.c | 2 +- drivers/irqchip/irq-riscv-intc.c | 2 +- drivers/irqchip/irq-sifive-plic.c | 2 +- drivers/irqchip/irq-uniphier-aidet.c | 2 +- drivers/irqchip/qcom-irq-combiner.c | 4 +- drivers/irqchip/qcom-pdc.c | 2 +- drivers/mfd/ioc3.c | 2 +- drivers/misc/lan966x_pci.c | 2 +- drivers/net/usb/smsc95xx.c | 2 +- .../pci/controller/dwc/pcie-designware-host.c | 2 +- drivers/pci/controller/pci-tegra.c | 2 +- drivers/pci/controller/pcie-apple.c | 4 +- drivers/pci/controller/pcie-mediatek.c | 2 +- drivers/pci/controller/pcie-rcar-host.c | 2 +- drivers/pci/controller/pcie-xilinx.c | 2 +- drivers/pinctrl/samsung/pinctrl-exynos.c | 4 +- drivers/pinctrl/samsung/pinctrl-s3c64xx.c | 4 +- drivers/pinctrl/stm32/pinctrl-stm32.c | 2 +- .../platform/x86/intel/crystal_cove_charger.c | 2 +- drivers/soundwire/irq.c | 2 +- include/linux/irq_sim.h | 8 ++-- include/linux/irqdomain.h | 18 ++++---- kernel/irq/ipi-mux.c | 2 +- kernel/irq/irq_sim.c | 28 ++++++------- kernel/irq/irqdomain.c | 10 ++--- kernel/irq/msi.c | 2 +- sound/soc/codecs/rt5677.c | 2 +- 84 files changed, 152 insertions(+), 152 deletions(-)
Documentation/core-api/irq/irq-domain.rst +21 -21
@@ -42,11 +42,11 @@ irq_domain usage ================ An interrupt controller driver creates and registers an irq_domain by -calling one of the irq_domain_add_*_of_node() or irq_domain_create_*() -functions (each mapping method has a different allocator function, -more on that later). The function will return a pointer to the -irq_domain on success. The caller must provide the allocator function -with an irq_domain_ops structure. +calling one of the irq_domain_add_*_of_node() or +irq_domain_add_*_fwnode() functions (each mapping method has a +different allocator function, more on that later). The function will +return a pointer to the irq_domain on success. The caller must provide +the allocator function with an irq_domain_ops structure. In most cases, the irq_domain will begin empty without any mappings between hwirq and IRQ numbers. Mappings are added to the irq_domain
@@ -94,7 +94,7 @@ Linear :: irq_domain_add_linear_of_node() - irq_domain_create_linear() + irq_domain_add_linear_fwnode() The linear reverse map maintains a fixed size table indexed by the hwirq number. When a hwirq is mapped, an irq_desc is allocated for
@@ -106,7 +106,7 @@ map are fixed time lookup for IRQ numbers, and irq_descs are only allocated for in-use IRQs. The disadvantage is that the table must be as large as the largest possible hwirq number. -irq_domain_add_linear_of_node() and irq_domain_create_linear() are +irq_domain_add_linear_of_node() and irq_domain_add_linear_fwnode() are functionally equivalent, except for the first argument is different - the former accepts an Open Firmware specific 'struct device_node', while the latter accepts a more general abstraction 'struct
@@ -120,7 +120,7 @@ Tree :: irq_domain_add_tree_of_node() - irq_domain_create_tree() + irq_domain_add_tree_fwnode() The irq_domain maintains a radix tree map from hwirq numbers to Linux IRQs. When an hwirq is mapped, an irq_desc is allocated and the
@@ -131,7 +131,7 @@ since it doesn't need to allocate a table as large as the largest hwirq number. The disadvantage is that hwirq to IRQ number lookup is dependent on how many entries are in the table. -irq_domain_add_tree_of_node() and irq_domain_create_tree() are +irq_domain_add_tree_of_node() and irq_domain_add_tree_fwnode() are functionally equivalent, except for the first argument is different - the former accepts an Open Firmware specific 'struct device_node', while the latter accepts a more general abstraction 'struct
@@ -164,8 +164,8 @@ Legacy irq_domain_add_simple_of_node() irq_domain_add_legacy_of_node() - irq_domain_create_simple() - irq_domain_create_legacy() + irq_domain_add_simple_fwnode() + irq_domain_add_legacy_fwnode() The Legacy mapping is a special case for drivers that already have a range of irq_descs allocated for the hwirqs. It is used when the
@@ -193,14 +193,14 @@ mapping Linux IRQs 0-15 so that existing ISA drivers get the correct IRQ numbers. Most users of legacy mappings should use -irq_domain_add_simple_of_node() or irq_domain_create_simple() which -will use a legacy domain only if an IRQ range is supplied by the +irq_domain_add_simple_of_node() or irq_domain_add_simple_fwnode() +which will use a legacy domain only if an IRQ range is supplied by the system and will otherwise use a linear domain mapping. The semantics of this call are such that if an IRQ range is specified then descriptors will be allocated on-the-fly for it, and if no range is specified it will fall through to irq_domain_add_linear_of_node() or -irq_domain_create_linear() which means *no* irq descriptors will be -allocated. +irq_domain_add_linear_fwnode() which means *no* irq descriptors will +be allocated. A typical use case for simple domains is where an irqchip provider is supporting both dynamic and static IRQ assignments.
@@ -211,12 +211,12 @@ that the driver using the simple domain call irq_create_mapping() before any irq_find_mapping() since the latter will actually work for the static IRQ assignment case. -irq_domain_add_simple_of_node() and irq_domain_create_simple() as well -as irq_domain_add_legacy_of_node() and irq_domain_create_legacy() are -functionally equivalent, except for the first argument is different - -the former accepts an Open Firmware specific 'struct device_node', -while the latter accepts a more general abstraction 'struct -fwnode_handle'. +irq_domain_add_simple_of_node() and irq_domain_add_simple_fwnode() as +well as irq_domain_add_legacy_of_node() and +irq_domain_add_legacy_fwnode() are functionally equivalent, except for +the first argument is different - the former accepts an Open Firmware +specific 'struct device_node', while the latter accepts a more general +abstraction 'struct fwnode_handle'. Hierarchy IRQ domain --------------------
Documentation/driver-api/driver-model/devres.rst +1 -1
@@ -337,7 +337,7 @@ IRQ devm_irq_alloc_descs_from() devm_irq_alloc_generic_chip() devm_irq_setup_generic_chip() - devm_irq_domain_create_sim() + devm_irq_domain_add_sim_fwnode() LED devm_led_classdev_register()
Documentation/translations/zh_CN/core-api/irq/irq-domain.rst +11 -11
@@ -43,7 +43,7 @@ irq_domain的用法 ================ 中断控制器驱动程序通过以下方式创建并注册一个irq_domain。调用 -irq_domain_add_*_of_node() 或 irq_domain_create_*()函数之一(每个映射方法都有不 +irq_domain_add_*_of_node() 或 irq_domain_add_*_fwnode()函数之一(每个映射方法都有不 同的分配器函数,后面会详细介绍)。 函数成功后会返回一个指向irq_domain的指针。 调用者必须向分配器函数提供一个irq_domain_ops结构体。
@@ -84,7 +84,7 @@ irq_domain映射的类型 :: irq_domain_add_linear_of_node() - irq_domain_create_linear() + irq_domain_add_linear_fwnode() 线性反向映射维护了一个固定大小的表,该表以hwirq号为索引。 当一个hwirq被映射 时,会给hwirq分配一个irq_desc,并将irq号存储在表中。
@@ -93,7 +93,7 @@ irq_domain映射的类型 映射的优点是固定时间查找IRQ号,而且irq_descs只分配给在用的IRQ。 缺点是该表 必须尽可能大的hwirq号。 -irq_domain_add_linear_of_node()和irq_domain_create_linear()在功能上是等价的, +irq_domain_add_linear_of_node()和irq_domain_add_linear_fwnode()在功能上是等价的, 除了第一个参数不同--前者接受一个Open Firmware特定的 'struct device_node' 而 后者接受一个更通用的抽象 'struct fwnode_handle' 。
@@ -105,7 +105,7 @@ irq_domain_add_linear_of_node()和irq_domain_create_linear()在功能上是等 :: irq_domain_add_tree_of_node() - irq_domain_create_tree() + irq_domain_add_tree_fwnode() irq_domain维护着从hwirq号到Linux IRQ的radix的树状映射。 当一个hwirq被映射时, 一个irq_desc被分配,hwirq被用作radix树的查找键。
@@ -113,7 +113,7 @@ irq_domain维护着从hwirq号到Linux IRQ的radix的树状映射。 当一个hw 如果hwirq号可以非常大,树状映射是一个很好的选择,因为它不需要分配一个和最大hwirq 号一样大的表。 缺点是,hwirq到IRQ号的查找取决于表中有多少条目。 -irq_domain_add_tree_of_node()和irq_domain_create_tree()在功能上是等价的,除了第一 +irq_domain_add_tree_of_node()和irq_domain_add_tree_fwnode()在功能上是等价的,除了第一 个参数不同——前者接受一个Open Firmware特定的 'struct device_node' ,而后者接受 一个更通用的抽象 'struct fwnode_handle' 。
@@ -140,8 +140,8 @@ Linux IRQ号编入硬件本身,这样就不需要映射了。 调用irq_create irq_domain_add_simple_of_node() irq_domain_add_legacy_of_node() - irq_domain_create_simple() - irq_domain_create_legacy() + irq_domain_add_simple_fwnode() + irq_domain_add_legacy_fwnode() 传统映射是已经为 hwirqs 分配了一系列 irq_descs 的驱动程序的特殊情况。 当驱动程 序不能立即转换为使用线性映射时,就会使用它。 例如,许多嵌入式系统板卡支持文件使用
@@ -159,10 +159,10 @@ Linux IRQ号编入硬件本身,这样就不需要映射了。 调用irq_create 映射Linux IRQ 0-15,这样现有的ISA驱动程序就能得到正确的IRQ号。 大多数使用传统映射的用户应该使用irq_domain_add_simple_of_node()或 -irq_domain_create_simple(),只有在系统提供IRQ范围时才会使用传统域,否则将使用 +irq_domain_add_simple_fwnode(),只有在系统提供IRQ范围时才会使用传统域,否则将使用 线性域映射。这个调用的语义是这样的:如果指定了一个IRQ范围,那么 描述符将被即时分配 给它,如果没有范围被分配,它将不会执行 irq_domain_add_linear_of_node() 或 -irq_domain_create_linear(),这意味着 *no* irq 描述符将被分配。 +irq_domain_add_linear_fwnode(),这意味着 *no* irq 描述符将被分配。 一个简单域的典型用例是,irqchip供应商同时支持动态和静态IRQ分配。
@@ -170,8 +170,8 @@ irq_domain_create_linear(),这意味着 *no* irq 描述符将被分配。 irq_find_mapping()之前调用irq_create_mapping()是非常重要的,因为后者实际上 将用于静态IRQ分配情况。 -irq_domain_add_simple_of_node()和irq_domain_create_simple()以及 -irq_domain_add_legacy_of_node()和irq_domain_create_legacy()在功能上是等价的,只 +irq_domain_add_simple_of_node()和irq_domain_add_simple_fwnode()以及 +irq_domain_add_legacy_of_node()和irq_domain_add_legacy_fwnode()在功能上是等价的,只 是第一个参数不同--前者接受Open Firmware特定的 'struct device_node' ,而后者 接受一个更通用的抽象 'struct fwnode_handle' 。
arch/arm64/kvm/arch_timer.c +1 -1
@@ -1445,7 +1445,7 @@ static int kvm_irq_init(struct arch_timer_kvm_info *info)/* Assume both vtimer and ptimer in the same parent */ data =irq_get_irq_data (host_vtimer_irq); - domain =irq_domain_create_hierarchy (data->domain,0 , + domain =irq_domain_add_hierarchy_fwnode (data->domain,0 ,NR_KVM_TIMERS , fwnode, &timer_domain_ops,NULL );if (!domain) {
arch/mips/pci/pci-xtalk-bridge.c +1 -1
@@ -626,7 +626,7 @@ static int bridge_probe(struct platform_device *pdev) fn =irq_domain_alloc_named_fwnode ("BRIDGE" );if (!fn)return -ENOMEM ; - domain =irq_domain_create_hierarchy (parent,0 ,8 , fn, + domain =irq_domain_add_hierarchy_fwnode (parent,0 ,8 , fn, &bridge_domain_ops,NULL );if (!domain) {irq_domain_free_fwnode (fn);
arch/mips/sgi-ip27/ip27-irq.c +1 -1
@@ -292,7 +292,7 @@ void __init arch_init_irq(void)if (WARN_ON (fn ==NULL ))return ; - domain =irq_domain_create_linear (fn,IP27_HUB_IRQ_COUNT , + domain =irq_domain_add_linear_fwnode (fn,IP27_HUB_IRQ_COUNT , &hub_domain_ops,NULL );if (WARN_ON (domain ==NULL ))return ;
arch/mips/sgi-ip30/ip30-irq.c +1 -1
@@ -307,7 +307,7 @@ void __init arch_init_irq(void)WARN_ON (fn ==NULL );if (!fn)return ; - domain =irq_domain_create_linear (fn,HEART_NUM_IRQS , + domain =irq_domain_add_linear_fwnode (fn,HEART_NUM_IRQS , &heart_domain_ops,NULL );WARN_ON (domain ==NULL );if (!domain)
arch/powerpc/platforms/powernv/pci-ioda.c +1 -1
@@ -1930,7 +1930,7 @@ static int __init pnv_msi_allocate_domains(struct pci_controller *hose, unsignedif (!hose->fwnode)return -ENOMEM ; - hose->dev_domain =irq_domain_create_hierarchy (parent,0 , count, + hose->dev_domain =irq_domain_add_hierarchy_fwnode (parent,0 , count, hose->fwnode, &pnv_irq_domain_ops, hose);if (!hose->dev_domain) {
arch/powerpc/platforms/pseries/msi.c +1 -1
@@ -618,7 +618,7 @@ static int __pseries_msi_allocate_domains(struct pci_controller *phb,if (!phb->fwnode)return -ENOMEM ; - phb->dev_domain =irq_domain_create_hierarchy (parent,0 , count, + phb->dev_domain =irq_domain_add_hierarchy_fwnode (parent,0 , count, phb->fwnode, &pseries_irq_domain_ops, phb);if (!phb->dev_domain) {
arch/powerpc/sysdev/xics/xics-common.c +1 -1
@@ -466,7 +466,7 @@ static int __init xics_allocate_domain(void)if (!fn)return -ENOMEM ; - xics_host =irq_domain_create_tree (fn, &xics_host_ops,NULL ); + xics_host =irq_domain_add_tree_fwnode (fn, &xics_host_ops,NULL );if (!xics_host) {irq_domain_free_fwnode (fn);return -ENOMEM ;
arch/powerpc/sysdev/xive/common.c +1 -1
@@ -1141,7 +1141,7 @@ static int __init xive_init_ipis(void)if (!fwnode) goto out; - ipi_domain =irq_domain_create_linear (fwnode, nr_node_ids, + ipi_domain =irq_domain_add_linear_fwnode (fwnode, nr_node_ids, &xive_ipi_irq_domain_ops,NULL );if (!ipi_domain) goto out_free_fwnode;
arch/x86/kernel/apic/io_apic.c +1 -1
@@ -2243,7 +2243,7 @@ static int mp_irqdomain_create(int ioapic)return -ENODEV ; } - ip->irqdomain =irq_domain_create_hierarchy (parent,0 , hwirqs, fn, cfg->ops, + ip->irqdomain =irq_domain_add_hierarchy_fwnode (parent,0 , hwirqs, fn, cfg->ops, (void *)(long )ioapic);if (!ip->irqdomain) {/* Release fw handle if it was allocated above */
arch/x86/kernel/apic/vector.c +1 -1
@@ -796,7 +796,7 @@ int __init arch_early_irq_init(void) fn =irq_domain_alloc_named_fwnode ("VECTOR" );BUG_ON (!fn); - x86_vector_domain =irq_domain_create_tree (fn, &x86_vector_domain_ops, + x86_vector_domain =irq_domain_add_tree_fwnode (fn, &x86_vector_domain_ops,NULL );BUG_ON (x86_vector_domain ==NULL );irq_set_default_domain (x86_vector_domain);
arch/x86/platform/uv/uv_irq.c +1 -1
@@ -166,7 +166,7 @@ static struct irq_domain *uv_get_irq_domain(void)if (!fn) goto out; - uv_domain =irq_domain_create_hierarchy (x86_vector_domain,0 ,0 , fn, + uv_domain =irq_domain_add_hierarchy_fwnode (x86_vector_domain,0 ,0 , fn, &uv_domain_ops,NULL );if (!uv_domain)irq_domain_free_fwnode (fn);
drivers/acpi/irq.c +1 -1
@@ -350,7 +350,7 @@ struct irq_domain *acpi_irq_create_hierarchy(unsigned int flags,if (!d)return NULL ; -return irq_domain_create_hierarchy (d, flags, size, fwnode, ops, +return irq_domain_add_hierarchy_fwnode (d, flags, size, fwnode, ops, host_data); }EXPORT_SYMBOL_GPL (acpi_irq_create_hierarchy);
drivers/gpio/gpio-bcm-kona.c +1 -1
@@ -593,7 +593,7 @@ static int bcm_kona_gpio_probe(struct platform_device *pdev) chip->parent = dev; chip->ngpio = kona_gpio->num_bank *GPIO_PER_BANK ; - kona_gpio->irq_domain =irq_domain_create_linear (dev_fwnode (dev), + kona_gpio->irq_domain =irq_domain_add_linear_fwnode (dev_fwnode (dev), chip->ngpio, &bcm_kona_irq_ops, kona_gpio);
drivers/gpio/gpio-mockup.c +1 -1
@@ -464,7 +464,7 @@ static int gpio_mockup_probe(struct platform_device *pdev)for (i =0 ; i < gc->ngpio; i++) chip->lines[i].dir =GPIO_LINE_DIRECTION_IN ; - chip->irq_sim_domain =devm_irq_domain_create_sim (dev,NULL , + chip->irq_sim_domain =devm_irq_domain_add_sim_fwnode (dev,NULL , gc->ngpio);if (IS_ERR (chip->irq_sim_domain))return PTR_ERR (chip->irq_sim_domain);
drivers/gpio/gpio-mpc8xxx.c +1 -1
@@ -388,7 +388,7 @@ static int mpc8xxx_probe(struct platform_device *pdev)if (mpc8xxx_gc->irqn <0 )return mpc8xxx_gc->irqn; - mpc8xxx_gc->irq =irq_domain_create_linear (fwnode, + mpc8xxx_gc->irq =irq_domain_add_linear_fwnode (fwnode,MPC8XXX_GPIO_PINS , &mpc8xxx_gpio_irq_ops, mpc8xxx_gc);
drivers/gpio/gpio-sim.c +1 -1
@@ -459,7 +459,7 @@ static int gpio_sim_add_bank(struct fwnode_handle *swnode, struct device *dev)if (!chip->pull_map)return -ENOMEM ; - chip->irq_sim =devm_irq_domain_create_sim_full (dev, swnode, num_lines, + chip->irq_sim =devm_irq_domain_add_sim_full_fwnode (dev, swnode, num_lines, &gpio_sim_irq_sim_ops, chip);if (IS_ERR (chip->irq_sim))
drivers/gpio/gpio-uniphier.c +1 -1
@@ -402,7 +402,7 @@ static int uniphier_gpio_probe(struct platform_device *pdev)if (ret)return ret; - priv->domain = irq_domain_create_hierarchy( + priv->domain = irq_domain_add_hierarchy_fwnode( parent_domain, 0, UNIPHIER_GPIO_IRQ_MAX_NUM, dev_fwnode(dev),
drivers/gpio/gpio-xgene-sb.c +1 -1
@@ -272,7 +272,7 @@ static int xgene_gpio_sb_probe(struct platform_device *pdev)platform_set_drvdata (pdev, priv); - priv->irq_domain =irq_domain_create_hierarchy (parent_domain, + priv->irq_domain =irq_domain_add_hierarchy_fwnode (parent_domain,0 , priv->nirq, pdev->dev.fwnode, &xgene_gpio_sb_domain_ops, priv);if (!priv->irq_domain)
drivers/gpio/gpiolib.c +2 -2
@@ -1623,7 +1623,7 @@ static struct irq_domain *gpiochip_hierarchy_create_domain(struct gpio_chip *gc)gpiochip_hierarchy_setup_domain_ops (&gc->irq.child_irq_domain_ops); - domain = irq_domain_create_hierarchy( + domain = irq_domain_add_hierarchy_fwnode( gc->irq.parent_domain, 0, gc->ngpio,
@@ -1766,7 +1766,7 @@ static struct irq_domain *gpiochip_simple_create_domain(struct gpio_chip *gc)struct fwnode_handle *fwnode =dev_fwnode (&gc->gpiodev->dev);struct irq_domain *domain; - domain =irq_domain_create_simple (fwnode, gc->ngpio, gc->irq.first, + domain =irq_domain_add_simple_fwnode (fwnode, gc->ngpio, gc->irq.first, &gpiochip_domain_ops, gc);if (!domain)return ERR_PTR (-EINVAL );
drivers/hid/hid-rmi.c +1 -1
@@ -621,7 +621,7 @@ static int rmi_setup_irq_domain(struct hid_device *hdev)struct rmi_data *hdata =hid_get_drvdata (hdev);int ret; - hdata->domain =irq_domain_create_linear (hdev->dev.fwnode,1 , + hdata->domain =irq_domain_add_linear_fwnode (hdev->dev.fwnode,1 , &rmi_irq_ops, hdata);if (!hdata->domain)return -ENOMEM ;
drivers/i2c/i2c-core-base.c +1 -1
@@ -1463,7 +1463,7 @@ static int i2c_setup_host_notify_irq_domain(struct i2c_adapter *adap)if (!i2c_check_functionality (adap,I2C_FUNC_SMBUS_HOST_NOTIFY ))return 0 ; - domain =irq_domain_create_linear (adap->dev.parent->fwnode, + domain =irq_domain_add_linear_fwnode (adap->dev.parent->fwnode,I2C_ADDR_7BITS_COUNT , &i2c_host_notify_irq_ops, adap);if (!domain)
drivers/iio/dummy/iio_dummy_evgen.c +1 -1
@@ -51,7 +51,7 @@ static int iio_dummy_evgen_create(void)if (!iio_evgen)return -ENOMEM ; - iio_evgen->irq_sim_domain =irq_domain_create_sim (NULL , + iio_evgen->irq_sim_domain =irq_domain_add_sim_fwnode (NULL ,IIO_EVENTGEN_NO );if (IS_ERR (iio_evgen->irq_sim_domain)) { ret =PTR_ERR (iio_evgen->irq_sim_domain);
drivers/input/rmi4/rmi_driver.c +1 -1
@@ -1036,7 +1036,7 @@ int rmi_probe_interrupts(struct rmi_driver_data *data)dev_warn (dev,"Device in bootloader mode.\n" );/* Allocate and register a linear revmap irq_domain */ - data->irqdomain =irq_domain_create_linear (fwnode, irq_count, + data->irqdomain =irq_domain_add_linear_fwnode (fwnode, irq_count, &irq_domain_simple_ops, data);if (!data->irqdomain) {
drivers/iommu/amd/init.c +1 -1
@@ -2376,7 +2376,7 @@ static struct irq_domain *iommu_get_irqdomain(void)if (!fn)return NULL ; - iommu_irqdomain =irq_domain_create_hierarchy (x86_vector_domain,0 ,0 , + iommu_irqdomain =irq_domain_add_hierarchy_fwnode (x86_vector_domain,0 ,0 , fn, &intcapxt_domain_ops,NULL );if (!iommu_irqdomain)
drivers/iommu/amd/iommu.c +1 -1
@@ -4018,7 +4018,7 @@ int amd_iommu_create_irq_domain(struct amd_iommu *iommu) fn =irq_domain_alloc_named_id_fwnode ("AMD-IR" , iommu->index);if (!fn)return -ENOMEM ; - iommu->ir_domain =irq_domain_create_hierarchy (arch_get_ir_parent_domain (),0 ,0 , + iommu->ir_domain =irq_domain_add_hierarchy_fwnode (arch_get_ir_parent_domain (),0 ,0 , fn, &amd_ir_domain_ops, iommu);if (!iommu->ir_domain) {irq_domain_free_fwnode (fn);
drivers/iommu/hyperv-iommu.c +1 -1
@@ -143,7 +143,7 @@ static int __init hyperv_prepare_irq_remapping(void)return -ENOMEM ; ioapic_ir_domain = -irq_domain_create_hierarchy (arch_get_ir_parent_domain (), +irq_domain_add_hierarchy_fwnode (arch_get_ir_parent_domain (),0 ,IOAPIC_REMAPPING_ENTRY , fn, ops,NULL );if (!ioapic_ir_domain) {
drivers/iommu/intel/irq_remapping.c +1 -1
@@ -557,7 +557,7 @@ static int intel_setup_irq_remapping(struct intel_iommu *iommu) goto out_free_bitmap; iommu->ir_domain = -irq_domain_create_hierarchy (arch_get_ir_parent_domain (), +irq_domain_add_hierarchy_fwnode (arch_get_ir_parent_domain (),0 ,INTR_REMAP_TABLE_ENTRIES , fn, &intel_ir_domain_ops, iommu);
drivers/irqchip/irq-apple-aic.c +1 -1
@@ -1013,7 +1013,7 @@ static int __init aic_of_ic_init(struct device_node *node, struct device_node *p irqc->info.die_stride = off - start_off; - irqc->hw_domain =irq_domain_create_tree (of_fwnode_handle (node), + irqc->hw_domain =irq_domain_add_tree_fwnode (of_fwnode_handle (node), &aic_irq_domain_ops, irqc);if (WARN_ON (!irqc->hw_domain)) goto err_unmap;
drivers/irqchip/irq-armada-370-xp.c +1 -1
@@ -492,7 +492,7 @@ static int __init mpic_ipi_init(struct mpic *mpic, struct device_node *node) {int base_ipi; - mpic->ipi_domain =irq_domain_create_linear (of_fwnode_handle (node),IPI_DOORBELL_NR , + mpic->ipi_domain =irq_domain_add_linear_fwnode (of_fwnode_handle (node),IPI_DOORBELL_NR , &mpic_ipi_domain_ops, mpic);if (WARN_ON (!mpic->ipi_domain))return -ENOMEM ;
drivers/irqchip/irq-bcm2836.c +1 -1
@@ -262,7 +262,7 @@ static void __init bcm2836_arm_irqchip_smp_init(void)if (WARN_ON (mux_irq <=0 ))return ; - ipi_domain =irq_domain_create_linear (intc.domain->fwnode, + ipi_domain =irq_domain_add_linear_fwnode (intc.domain->fwnode,BITS_PER_MBOX , &ipi_domain_ops,NULL );if (WARN_ON (!ipi_domain))
drivers/irqchip/irq-gic-v2m.c +1 -1
@@ -270,7 +270,7 @@ static __init int gicv2m_allocate_domains(struct irq_domain *parent)if (!v2m)return 0 ; - inner_domain =irq_domain_create_hierarchy (parent,0 ,0 , v2m->fwnode, + inner_domain =irq_domain_add_hierarchy_fwnode (parent,0 ,0 , v2m->fwnode, &gicv2m_domain_ops, v2m);if (!inner_domain) {pr_err ("Failed to create GICv2m domain\n" );
drivers/irqchip/irq-gic-v3-its.c +1 -1
@@ -5114,7 +5114,7 @@ static int its_init_domain(struct its_node *its) info->ops = &its_msi_domain_ops; info->data = its; - inner_domain =irq_domain_create_hierarchy (its_parent, + inner_domain =irq_domain_add_hierarchy_fwnode (its_parent, its->msi_domain_flags,0 , its->fwnode_handle, &its_domain_ops, info);
drivers/irqchip/irq-gic-v3-mbi.c +1 -1
@@ -211,7 +211,7 @@ static int mbi_allocate_domain(struct irq_domain *parent) {struct irq_domain *nexus_domain; - nexus_domain =irq_domain_create_hierarchy (parent,0 ,0 , parent->fwnode, + nexus_domain =irq_domain_add_hierarchy_fwnode (parent,0 ,0 , parent->fwnode, &mbi_domain_ops,NULL );if (!nexus_domain)return -ENOMEM ;
drivers/irqchip/irq-gic-v3.c +1 -1
@@ -2068,7 +2068,7 @@ static int __init gic_init_bases(phys_addr_t dist_phys_base,if (!(gic_data.flags &FLAGS_WORKAROUND_CAVIUM_ERRATUM_38539 )) gic_data.rdists.gicd_typer2 =readl_relaxed (gic_data.dist_base +GICD_TYPER2 ); - gic_data.domain =irq_domain_create_tree (handle, &gic_irq_domain_ops, + gic_data.domain =irq_domain_add_tree_fwnode (handle, &gic_irq_domain_ops, &gic_data); gic_data.rdists.rdist =alloc_percpu (typeof (*gic_data.rdists.rdist));if (!static_branch_unlikely (&gic_nvidia_t241_erratum)) {
drivers/irqchip/irq-gic-v4.c +2 -2
@@ -135,7 +135,7 @@ static int its_alloc_vcpu_sgis(struct its_vpe *vpe, int idx)kfree (name); name =NULL ; - vpe->sgi_domain =irq_domain_create_linear (vpe->fwnode,16 , + vpe->sgi_domain =irq_domain_add_linear_fwnode (vpe->fwnode,16 , sgi_domain_ops, vpe);if (!vpe->sgi_domain) goto err;
@@ -164,7 +164,7 @@ int its_alloc_vcpu_irqs(struct its_vm *vm)if (!vm->fwnode) goto err; - vm->domain =irq_domain_create_hierarchy (gic_domain,0 , vm->nr_vpes, + vm->domain =irq_domain_add_hierarchy_fwnode (gic_domain,0 , vm->nr_vpes, vm->fwnode, vpe_domain_ops, vm);if (!vm->domain)
drivers/irqchip/irq-gic.c +1 -1
@@ -1207,7 +1207,7 @@ static int gic_init_bases(struct gic_chip_data *gic, gic_irqs =1020 ; gic->gic_irqs = gic_irqs; - gic->domain =irq_domain_create_linear (handle, gic_irqs, + gic->domain =irq_domain_add_linear_fwnode (handle, gic_irqs, &gic_irq_domain_hierarchy_ops, gic);if (WARN_ON (!gic->domain)) {
drivers/irqchip/irq-imx-mu-msi.c +1 -1
@@ -226,7 +226,7 @@ static int imx_mu_msi_domains_init(struct imx_mu_msi *msi_data, struct device *dstruct irq_domain *parent;/* Initialize MSI domain parent */ - parent =irq_domain_create_linear (fwnodes,IMX_MU_CHANS , + parent =irq_domain_add_linear_fwnode (fwnodes,IMX_MU_CHANS , &imx_mu_msi_domain_ops, msi_data);if (!parent) {dev_err (dev,"failed to create IRQ domain\n" );
drivers/irqchip/irq-ixp4xx.c +1 -1
@@ -234,7 +234,7 @@ static int __init ixp4xx_irq_setup(struct ixp4xx_irq *ixi, ixi->irqchip.irq_unmask = ixp4xx_irq_unmask; ixi->irqchip.irq_set_type = ixp4xx_set_irq_type; - ixi->domain =irq_domain_create_linear (fwnode, nr_irqs, + ixi->domain =irq_domain_add_linear_fwnode (fwnode, nr_irqs, &ixp4xx_irqdomain_ops, ixi);if (!ixi->domain) {
drivers/irqchip/irq-loongarch-avec.c +1 -1
@@ -350,7 +350,7 @@ static int __init avecintc_init(struct irq_domain *parent) goto out; } - loongarch_avec.domain =irq_domain_create_tree (loongarch_avec.fwnode, + loongarch_avec.domain =irq_domain_add_tree_fwnode (loongarch_avec.fwnode, &avecintc_domain_ops,NULL );if (!loongarch_avec.domain) {pr_err ("Unable to create IRQ domain\n" );
drivers/irqchip/irq-loongarch-cpu.c +2 -2
@@ -102,7 +102,7 @@ static int __init cpuintc_of_init(struct device_node *of_node, { cpuintc_handle =of_fwnode_handle (of_node); - irq_domain =irq_domain_create_linear (cpuintc_handle,EXCCODE_INT_NUM , + irq_domain =irq_domain_add_linear_fwnode (cpuintc_handle,EXCCODE_INT_NUM , &loongarch_cpu_intc_irq_domain_ops,NULL );if (!irq_domain)panic ("Failed to add irqdomain for loongarch CPU" );
@@ -161,7 +161,7 @@ static int __init cpuintc_acpi_init(union acpi_subtable_headers *header,clear_csr_estat (ESTATF_IP ); cpuintc_handle =irq_domain_alloc_named_fwnode ("CPUINTC" ); - irq_domain =irq_domain_create_linear (cpuintc_handle,EXCCODE_INT_NUM , + irq_domain =irq_domain_add_linear_fwnode (cpuintc_handle,EXCCODE_INT_NUM , &loongarch_cpu_intc_irq_domain_ops,NULL );if (!irq_domain)
drivers/irqchip/irq-loongson-eiointc.c +1 -1
@@ -438,7 +438,7 @@ static int __init eiointc_init(struct eiointc_priv *priv, int parent_irq, } } - priv->eiointc_domain =irq_domain_create_linear (priv->domain_handle, + priv->eiointc_domain =irq_domain_add_linear_fwnode (priv->domain_handle, priv->vec_count, &eiointc_domain_ops, priv);
drivers/irqchip/irq-loongson-htvec.c +1 -1
@@ -197,7 +197,7 @@ static int htvec_init(phys_addr_t addr, unsigned long size,raw_spin_lock_init (&priv->htvec_lock);/* Setup IRQ domain */ - priv->htvec_domain =irq_domain_create_linear (domain_handle, + priv->htvec_domain =irq_domain_add_linear_fwnode (domain_handle, (VEC_COUNT_PER_REG * priv->num_parents), &htvec_domain_ops, priv);if (!priv->htvec_domain) {
drivers/irqchip/irq-loongson-liointc.c +2 -2
@@ -241,10 +241,10 @@ static int liointc_init(phys_addr_t addr, unsigned long size, int revision,/* Setup IRQ domain */ if (!acpi_disabled) - domain =irq_domain_create_linear (domain_handle,LIOINTC_CHIP_IRQ , + domain =irq_domain_add_linear_fwnode (domain_handle,LIOINTC_CHIP_IRQ , &acpi_irq_gc_ops, priv);else - domain =irq_domain_create_linear (domain_handle,LIOINTC_CHIP_IRQ , + domain =irq_domain_add_linear_fwnode (domain_handle,LIOINTC_CHIP_IRQ , &irq_generic_chip_ops, priv);if (!domain) {pr_err ("loongson-liointc: cannot add IRQ domain\n" );
drivers/irqchip/irq-loongson-pch-lpc.c +1 -1
@@ -200,7 +200,7 @@ int __init pch_lpc_acpi_init(struct irq_domain *parent, goto iounmap_base; } - priv->lpc_domain =irq_domain_create_linear (irq_handle,LPC_COUNT , + priv->lpc_domain =irq_domain_add_linear_fwnode (irq_handle,LPC_COUNT , &pch_lpc_domain_ops, priv);if (!priv->lpc_domain) {pr_err ("Failed to create IRQ domain\n" );
drivers/irqchip/irq-loongson-pch-msi.c +1 -1
@@ -158,7 +158,7 @@ static int pch_msi_init_domains(struct pch_msi_data *priv, {struct irq_domain *middle_domain; - middle_domain =irq_domain_create_hierarchy (parent,0 , priv->num_irqs, + middle_domain =irq_domain_add_hierarchy_fwnode (parent,0 , priv->num_irqs, domain_handle, &pch_msi_middle_domain_ops, priv);
drivers/irqchip/irq-loongson-pch-pic.c +1 -1
@@ -342,7 +342,7 @@ static int pch_pic_init(phys_addr_t addr, unsigned long size, int vec_base, priv->vec_count = ((readq (priv->base) >>48 ) &0xff ) +1 ; priv->gsi_base = gsi_base; - priv->pic_domain =irq_domain_create_hierarchy (parent_domain,0 , + priv->pic_domain =irq_domain_add_hierarchy_fwnode (parent_domain,0 , priv->vec_count, domain_handle, &pch_pic_domain_ops, priv);
drivers/irqchip/irq-meson-gpio.c +1 -1
@@ -579,7 +579,7 @@ static int meson_gpio_irq_of_init(struct device_node *node, struct device_node *if (ret) goto free_channel_irqs; - domain = irq_domain_create_hierarchy(parent_domain, 0, + domain = irq_domain_add_hierarchy_fwnode(parent_domain, 0, ctl->params->nr_hwirq, of_fwnode_handle(node), &meson_gpio_irq_domain_ops,
drivers/irqchip/irq-mvebu-gicp.c +1 -1
@@ -229,7 +229,7 @@ static int mvebu_gicp_probe(struct platform_device *pdev)return -ENODEV ; } - inner_domain =irq_domain_create_hierarchy (parent_domain,0 , + inner_domain =irq_domain_add_hierarchy_fwnode (parent_domain,0 , gicp->spi_cnt,of_fwnode_handle (node), &gicp_domain_ops, gicp);
drivers/irqchip/irq-mvebu-odmi.c +1 -1
@@ -204,7 +204,7 @@ static int __init mvebu_odmi_init(struct device_node *node, parent_domain =irq_find_host (parent); - inner_domain =irq_domain_create_hierarchy (parent_domain,0 , + inner_domain =irq_domain_add_hierarchy_fwnode (parent_domain,0 , odmis_count *NODMIS_PER_FRAME ,of_fwnode_handle (node), &odmi_domain_ops,NULL );
drivers/irqchip/irq-mvebu-sei.c +3 -3
@@ -401,7 +401,7 @@ static int mvebu_sei_probe(struct platform_device *pdev) }/* Create the root SEI domain */ - sei->sei_domain = irq_domain_create_linear(of_fwnode_handle(node), + sei->sei_domain = irq_domain_add_linear_fwnode(of_fwnode_handle(node), (sei->caps->ap_range.size + sei->caps->cp_range.size), &mvebu_sei_domain_ops,
@@ -415,7 +415,7 @@ static int mvebu_sei_probe(struct platform_device *pdev)irq_domain_update_bus_token (sei->sei_domain,DOMAIN_BUS_NEXUS );/* Create the 'wired' domain */ - sei->ap_domain = irq_domain_create_hierarchy(sei->sei_domain, 0, + sei->ap_domain = irq_domain_add_hierarchy_fwnode(sei->sei_domain, 0, sei->caps->ap_range.size, of_fwnode_handle(node), &mvebu_sei_ap_domain_ops,
@@ -429,7 +429,7 @@ static int mvebu_sei_probe(struct platform_device *pdev)irq_domain_update_bus_token (sei->ap_domain,DOMAIN_BUS_WIRED );/* Create the 'MSI' domain */ - sei->cp_domain = irq_domain_create_hierarchy(sei->sei_domain, 0, + sei->cp_domain = irq_domain_add_hierarchy_fwnode(sei->sei_domain, 0, sei->caps->cp_range.size, of_fwnode_handle(node), &mvebu_sei_cp_domain_ops,
drivers/irqchip/irq-partition-percpu.c +1 -1
@@ -210,7 +210,7 @@ struct partition_desc *partition_create_desc(struct fwnode_handle *fwnode, desc->ops.free = partition_domain_free; desc->ops.alloc = partition_domain_alloc; - d =irq_domain_create_linear (fwnode, nr_parts, &desc->ops, desc); + d =irq_domain_add_linear_fwnode (fwnode, nr_parts, &desc->ops, desc);if (!d) goto out; desc->domain = d;
drivers/irqchip/irq-qcom-mpm.c +1 -1
@@ -445,7 +445,7 @@ static int qcom_mpm_init(struct device_node *np, struct device_node *parent) goto free_mbox; } - priv->domain =irq_domain_create_hierarchy (parent_domain, + priv->domain =irq_domain_add_hierarchy_fwnode (parent_domain,IRQ_DOMAIN_FLAG_QCOM_MPM_WAKEUP , pin_cnt,of_fwnode_handle (np), &qcom_mpm_ops, priv);if (!priv->domain) {
drivers/irqchip/irq-rda-intc.c +1 -1
@@ -91,7 +91,7 @@ static int __init rda8810_intc_init(struct device_node *node,/* Mask all interrupt sources */ writel_relaxed (RDA_IRQ_MASK_ALL , rda_intc_base +RDA_INTC_MASK_CLR ); - rda_irq_domain =irq_domain_create_linear (&node->fwnode,RDA_NR_IRQS , + rda_irq_domain =irq_domain_add_linear_fwnode (&node->fwnode,RDA_NR_IRQS , &rda_irq_domain_ops, rda_intc_base);if (!rda_irq_domain) {
drivers/irqchip/irq-riscv-aplic-direct.c +1 -1
@@ -314,7 +314,7 @@ int aplic_direct_setup(struct device *dev, void __iomem *regs)aplic_init_hw_global (priv, false);/* Create irq domain instance for the APLIC */ - direct->irqdomain =irq_domain_create_linear (dev->fwnode, priv->nr_irqs +1 , + direct->irqdomain =irq_domain_add_linear_fwnode (dev->fwnode, priv->nr_irqs +1 , &aplic_direct_irqdomain_ops, priv);if (!direct->irqdomain) {dev_err (dev,"failed to create direct irq domain\n" );
drivers/irqchip/irq-riscv-imsic-platform.c +1 -1
@@ -325,7 +325,7 @@ int imsic_irqdomain_init(void) }/* Create Base IRQ domain */ - imsic->base_domain =irq_domain_create_tree (imsic->fwnode, + imsic->base_domain =irq_domain_add_tree_fwnode (imsic->fwnode, &imsic_base_domain_ops, imsic);if (!imsic->base_domain) {pr_err ("%pfwP: failed to create IMSIC base domain\n" , imsic->fwnode);
drivers/irqchip/irq-riscv-intc.c +1 -1
@@ -178,7 +178,7 @@ static int __init riscv_intc_init_common(struct fwnode_handle *fn, struct irq_ch {int rc; - intc_domain =irq_domain_create_tree (fn, &riscv_intc_domain_ops, chip); + intc_domain =irq_domain_add_tree_fwnode (fn, &riscv_intc_domain_ops, chip);if (!intc_domain) {pr_err ("unable to add IRQ domain\n" );return -ENXIO ;
drivers/irqchip/irq-sifive-plic.c +1 -1
@@ -639,7 +639,7 @@ static int plic_probe(struct fwnode_handle *fwnode) nr_handlers++; } - priv->irqdomain =irq_domain_create_linear (fwnode, nr_irqs +1 , + priv->irqdomain =irq_domain_add_linear_fwnode (fwnode, nr_irqs +1 , &plic_irqdomain_ops, priv);if (WARN_ON (!priv->irqdomain)) { error = -ENOMEM ;
drivers/irqchip/irq-uniphier-aidet.c +1 -1
@@ -185,7 +185,7 @@ static int uniphier_aidet_probe(struct platform_device *pdev)spin_lock_init (&priv->lock); - priv->domain = irq_domain_create_hierarchy( + priv->domain = irq_domain_add_hierarchy_fwnode( parent_domain, 0, UNIPHIER_AIDET_NR_IRQS, of_fwnode_handle(dev->of_node),
drivers/irqchip/qcom-irq-combiner.c +2 -2
@@ -247,10 +247,10 @@ static int __init combiner_probe(struct platform_device *pdev)if (combiner->parent_irq <=0 )return -EPROBE_DEFER ; - combiner->domain =irq_domain_create_linear (pdev->dev.fwnode, combiner->nirqs, + combiner->domain =irq_domain_add_linear_fwnode (pdev->dev.fwnode, combiner->nirqs, &domain_ops, combiner);if (!combiner->domain) -/* Errors printed by irq_domain_create_linear */ +/* Errors printed by irq_domain_add_linear_fwnode */ return -ENODEV ; irq_set_chained_handler_and_data(combiner->parent_irq,
drivers/irqchip/qcom-pdc.c +1 -1
@@ -345,7 +345,7 @@ static int qcom_pdc_init(struct device_node *node, struct device_node *parent) goto fail; } - pdc_domain = irq_domain_create_hierarchy(parent_domain, + pdc_domain = irq_domain_add_hierarchy_fwnode(parent_domain, IRQ_DOMAIN_FLAG_QCOM_PDC_WAKEUP, PDC_MAX_GPIO_IRQS, of_fwnode_handle(node),
drivers/mfd/ioc3.c +1 -1
@@ -138,7 +138,7 @@ static int ioc3_irq_domain_setup(struct ioc3_priv_data *ipd, int irq)if (!fn) goto err; - domain =irq_domain_create_linear (fn,24 , &ioc3_irq_domain_ops, ipd); + domain =irq_domain_add_linear_fwnode (fn,24 , &ioc3_irq_domain_ops, ipd);if (!domain) {irq_domain_free_fwnode (fn); goto err;
drivers/misc/lan966x_pci.c +1 -1
@@ -64,7 +64,7 @@ static struct pci_dev_intr_ctrl *pci_dev_create_intr_ctrl(struct pci_dev *pdev) intr_ctrl->pci_dev = pdev; - intr_ctrl->irq_domain =irq_domain_create_linear (fwnode,1 , &pci_dev_irq_domain_ops, + intr_ctrl->irq_domain =irq_domain_add_linear_fwnode (fwnode,1 , &pci_dev_irq_domain_ops, intr_ctrl);if (!intr_ctrl->irq_domain) {pci_err (pdev,"Failed to create irqdomain\n" );
drivers/net/usb/smsc95xx.c +1 -1
@@ -1145,7 +1145,7 @@ static int smsc95xx_bind(struct usbnet *dev, struct usb_interface *intf) goto free_pdata; } - pdata->irqdomain =irq_domain_create_linear (pdata->irqfwnode, + pdata->irqdomain =irq_domain_add_linear_fwnode (pdata->irqfwnode,SMSC95XX_NR_IRQS , &irq_domain_simple_ops, pdata);
drivers/pci/controller/dwc/pcie-designware-host.c +1 -1
@@ -229,7 +229,7 @@ int dw_pcie_allocate_domains(struct dw_pcie_rp *pp)struct dw_pcie *pci =to_dw_pcie_from_pp (pp);struct fwnode_handle *fwnode =of_fwnode_handle (pci->dev->of_node); - pp->irq_domain =irq_domain_create_linear (fwnode, pp->num_vectors, + pp->irq_domain =irq_domain_add_linear_fwnode (fwnode, pp->num_vectors, &dw_pcie_msi_domain_ops, pp);if (!pp->irq_domain) {dev_err (pci->dev,"Failed to create IRQ domain\n" );
drivers/pci/controller/pci-tegra.c +1 -1
@@ -1702,7 +1702,7 @@ static int tegra_allocate_domains(struct tegra_msi *msi)struct fwnode_handle *fwnode =dev_fwnode (pcie->dev);struct irq_domain *parent; - parent =irq_domain_create_linear (fwnode,INT_PCI_MSI_NR , + parent =irq_domain_add_linear_fwnode (fwnode,INT_PCI_MSI_NR , &tegra_msi_domain_ops, msi);if (!parent) {dev_err (pcie->dev,"failed to create IRQ domain\n" );
drivers/pci/controller/pcie-apple.c +2 -2
@@ -381,7 +381,7 @@ static int apple_pcie_port_setup_irq(struct apple_pcie_port *port)if (!irq)return -ENXIO ; - port->domain =irq_domain_create_linear (fwnode,32 , + port->domain =irq_domain_add_linear_fwnode (fwnode,32 , &apple_port_irq_domain_ops, port);if (!port->domain)
@@ -626,7 +626,7 @@ static int apple_msi_init(struct apple_pcie *pcie)return -ENXIO ; } - parent =irq_domain_create_hierarchy (parent,0 , pcie->nvecs, fwnode, + parent =irq_domain_add_hierarchy_fwnode (parent,0 , pcie->nvecs, fwnode, &apple_msi_domain_ops, pcie);if (!parent) {dev_err (pcie->dev,"failed to create IRQ domain\n" );
drivers/pci/controller/pcie-mediatek.c +1 -1
@@ -489,7 +489,7 @@ static int mtk_pcie_allocate_msi_domains(struct mtk_pcie_port *port)mutex_init (&port->lock); - port->inner_domain =irq_domain_create_linear (fwnode,MTK_MSI_IRQS_NUM , + port->inner_domain =irq_domain_add_linear_fwnode (fwnode,MTK_MSI_IRQS_NUM , &msi_domain_ops, port);if (!port->inner_domain) {dev_err (port->pcie->dev,"failed to create IRQ domain\n" );
drivers/pci/controller/pcie-rcar-host.c +1 -1
@@ -730,7 +730,7 @@ static int rcar_allocate_domains(struct rcar_msi *msi)struct fwnode_handle *fwnode =dev_fwnode (pcie->dev);struct irq_domain *parent; - parent =irq_domain_create_linear (fwnode,INT_PCI_MSI_NR , + parent =irq_domain_add_linear_fwnode (fwnode,INT_PCI_MSI_NR , &rcar_msi_domain_ops, msi);if (!parent) {dev_err (pcie->dev,"failed to create IRQ domain\n" );
drivers/pci/controller/pcie-xilinx.c +1 -1
@@ -275,7 +275,7 @@ static int xilinx_allocate_msi_domains(struct xilinx_pcie *pcie)struct fwnode_handle *fwnode =dev_fwnode (pcie->dev);struct irq_domain *parent; - parent =irq_domain_create_linear (fwnode,XILINX_NUM_MSI_IRQS , + parent =irq_domain_add_linear_fwnode (fwnode,XILINX_NUM_MSI_IRQS , &xilinx_msi_domain_ops, pcie);if (!parent) {dev_err (pcie->dev,"failed to create IRQ domain\n" );
drivers/pinctrl/samsung/pinctrl-exynos.c +2 -2
@@ -405,7 +405,7 @@ __init int exynos_eint_gpio_init(struct samsung_pinctrl_drv_data *d) } bank->irq_chip->chip.name = bank->name; - bank->irq_domain =irq_domain_create_linear (bank->fwnode, + bank->irq_domain =irq_domain_add_linear_fwnode (bank->fwnode, bank->nr_pins, &exynos_eint_irqd_ops, bank);if (!bank->irq_domain) {dev_err (dev,"gpio irq domain add failed\n" );
@@ -697,7 +697,7 @@ __init int exynos_eint_wkup_init(struct samsung_pinctrl_drv_data *d)return -ENOMEM ; bank->irq_chip->chip.name = bank->name; - bank->irq_domain =irq_domain_create_linear (bank->fwnode, + bank->irq_domain =irq_domain_add_linear_fwnode (bank->fwnode, bank->nr_pins, &exynos_eint_irqd_ops, bank);if (!bank->irq_domain) {dev_err (dev,"wkup irq domain add failed\n" );
drivers/pinctrl/samsung/pinctrl-s3c64xx.c +2 -2
@@ -484,7 +484,7 @@ static int s3c64xx_eint_gpio_init(struct samsung_pinctrl_drv_data *d) mask = bank->eint_mask; nr_eints =fls (mask); - bank->irq_domain =irq_domain_create_linear (bank->fwnode, + bank->irq_domain =irq_domain_add_linear_fwnode (bank->fwnode, nr_eints, &s3c64xx_gpio_irqd_ops, bank);if (!bank->irq_domain) {dev_err (dev,"gpio irq domain add failed\n" );
@@ -756,7 +756,7 @@ static int s3c64xx_eint_eint0_init(struct samsung_pinctrl_drv_data *d)return -ENOMEM ; ddata->bank = bank; - bank->irq_domain =irq_domain_create_linear (bank->fwnode, + bank->irq_domain =irq_domain_add_linear_fwnode (bank->fwnode, nr_eints, &s3c64xx_eint0_irqd_ops, ddata);if (!bank->irq_domain) {dev_err (dev,"wkup irq domain add failed\n" );
drivers/pinctrl/stm32/pinctrl-stm32.c +1 -1
@@ -1356,7 +1356,7 @@ static int stm32_gpiolib_register_bank(struct stm32_pinctrl *pctl, struct fwnode/* create irq hierarchical domain */ bank->fwnode = fwnode; - bank->domain =irq_domain_create_hierarchy (pctl->domain,0 ,STM32_GPIO_IRQ_LINE , + bank->domain =irq_domain_add_hierarchy_fwnode (pctl->domain,0 ,STM32_GPIO_IRQ_LINE , bank->fwnode, &stm32_gpio_domain_ops, bank);
drivers/platform/x86/intel/crystal_cove_charger.c +1 -1
@@ -100,7 +100,7 @@ static int crystal_cove_charger_probe(struct platform_device *pdev)if (charger->irq <0 )return charger->irq; - charger->irq_domain =irq_domain_create_linear (dev_fwnode (pdev->dev.parent),1 , + charger->irq_domain =irq_domain_add_linear_fwnode (dev_fwnode (pdev->dev.parent),1 , &irq_domain_simple_ops,NULL );if (!charger->irq_domain)return -ENOMEM ;
drivers/soundwire/irq.c +1 -1
@@ -31,7 +31,7 @@ int sdw_irq_create(struct sdw_bus *bus, { bus->irq_chip.name =dev_name (bus->dev); - bus->domain =irq_domain_create_linear (fwnode,SDW_MAX_DEVICES , + bus->domain =irq_domain_add_linear_fwnode (fwnode,SDW_MAX_DEVICES , &sdw_domain_ops, bus);if (!bus->domain) {dev_err (bus->dev,"Failed to add IRQ domain\n" );
include/linux/irq_sim.h +4 -4
@@ -23,17 +23,17 @@ struct irq_sim_ops { irq_hw_number_t hwirq, void *data); }; -struct irq_domain *irq_domain_create_sim (struct fwnode_handle *fwnode, +struct irq_domain *irq_domain_add_sim_fwnode (struct fwnode_handle *fwnode,unsigned int num_irqs); -struct irq_domain *devm_irq_domain_create_sim (struct device *dev, +struct irq_domain *devm_irq_domain_add_sim_fwnode (struct device *dev,struct fwnode_handle *fwnode,unsigned int num_irqs); -struct irq_domain *irq_domain_create_sim_full (struct fwnode_handle *fwnode, +struct irq_domain *irq_domain_add_sim_full_fwnode (struct fwnode_handle *fwnode,unsigned int num_irqs,const struct irq_sim_ops *ops,void *data);struct irq_domain * -devm_irq_domain_create_sim_full(struct device *dev, +devm_irq_domain_add_sim_full_fwnode(struct device *dev, struct fwnode_handle *fwnode, unsigned int num_irqs, const struct irq_sim_ops *ops,
include/linux/irqdomain.h +9 -9
@@ -333,12 +333,12 @@ struct irq_domain *irq_domain_instantiate(const struct irq_domain_info *info);struct irq_domain *devm_irq_domain_instantiate (struct device *dev,const struct irq_domain_info *info); -struct irq_domain *irq_domain_create_simple (struct fwnode_handle *fwnode, +struct irq_domain *irq_domain_add_simple_fwnode (struct fwnode_handle *fwnode,unsigned int size,unsigned int first_irq,const struct irq_domain_ops *ops,void *host_data); -struct irq_domain *irq_domain_create_legacy(struct fwnode_handle *fwnode, +struct irq_domain *irq_domain_add_legacy_fwnode(struct fwnode_handle *fwnode, unsigned int size, unsigned int first_irq, irq_hw_number_t first_hwirq,
@@ -367,7 +367,7 @@ static inline struct irq_domain *irq_domain_add_legacy_of_node(struct device_nodconst struct irq_domain_ops *ops, void *host_data) { - return irq_domain_create_legacy(of_fwnode_handle(of_node), size, + return irq_domain_add_legacy_fwnode(of_fwnode_handle(of_node), size,first_irq ,first_hwirq ,ops ,host_data ); }
@@ -423,7 +423,7 @@ static inline struct irq_domain *irq_domain_add_simple_of_node(struct device_nodconst struct irq_domain_ops *ops, void *host_data) { - return irq_domain_create_simple(of_fwnode_handle(of_node), size, first_irq, ops, host_data); + return irq_domain_add_simple_fwnode(of_fwnode_handle(of_node), size, first_irq, ops, host_data); }/**
@@ -486,7 +486,7 @@ static inline struct irq_domain *irq_domain_add_tree_of_node(struct device_nodereturn IS_ERR (d) ?NULL : d; } -static inline struct irq_domain *irq_domain_create_linear (struct fwnode_handle *fwnode, +static inline struct irq_domain *irq_domain_add_linear_fwnode (struct fwnode_handle *fwnode,unsigned int size,const struct irq_domain_ops *ops,void *host_data)
@@ -503,7 +503,7 @@ static inline struct irq_domain *irq_domain_create_linear(struct fwnode_handle *return IS_ERR (d) ?NULL : d; } -static inline struct irq_domain *irq_domain_create_tree (struct fwnode_handle *fwnode, +static inline struct irq_domain *irq_domain_add_tree_fwnode (struct fwnode_handle *fwnode,const struct irq_domain_ops *ops,void *host_data) {
@@ -608,7 +608,7 @@ void irq_domain_set_info(struct irq_domain *domain, unsigned int virq,void irq_domain_reset_irq_data (struct irq_data *irq_data);#ifdef CONFIG_IRQ_DOMAIN_HIERARCHY /** -* irq_domain_create_hierarchy - Add a irqdomain into the hierarchy +* irq_domain_add_hierarchy_fwnode - Add a irqdomain into the hierarchy * @parent: Parent irq domain to associate with the new domain * @flags: Irq domain flags associated to the domain * @size: Size of the domain. See below
@@ -622,7 +622,7 @@ void irq_domain_reset_irq_data(struct irq_data *irq_data);* domain flags are set. * Returns pointer to IRQ domain, or NULL on failure. */ -static inline struct irq_domain *irq_domain_create_hierarchy(struct irq_domain *parent, +static inline struct irq_domain *irq_domain_add_hierarchy_fwnode(struct irq_domain *parent, unsigned int flags, unsigned int size, struct fwnode_handle *fwnode,
@@ -650,7 +650,7 @@ static inline struct irq_domain *irq_domain_add_hierarchy_of_node(struct irq_domconst struct irq_domain_ops *ops, void *host_data) { - return irq_domain_create_hierarchy(parent, flags, size, + return irq_domain_add_hierarchy_fwnode(parent, flags, size,of_fwnode_handle (node ),ops ,host_data ); }
kernel/irq/ipi-mux.c +1 -1
@@ -174,7 +174,7 @@ int ipi_mux_create(unsigned int nr_ipi, void (*mux_send)(unsigned int cpu)) goto fail_free_cpu; } - domain =irq_domain_create_linear (fwnode, nr_ipi, + domain =irq_domain_add_linear_fwnode (fwnode, nr_ipi, &ipi_mux_domain_ops,NULL );if (!domain) {pr_err ("unable to add IPI Mux domain\n" );
kernel/irq/irq_sim.c +14 -14
@@ -180,7 +180,7 @@ static const struct irq_domain_ops irq_sim_domain_ops = { };/** -* irq_domain_create_sim - Create a new interrupt simulator irq_domain and +* irq_domain_add_sim_fwnode - Create a new interrupt simulator irq_domain and * allocate a range of dummy interrupts. * * @fwnode: struct fwnode_handle to be associated with this domain.
@@ -189,14 +189,14 @@ static const struct irq_domain_ops irq_sim_domain_ops = {* On success: return a new irq_domain object. * On failure: a negative errno wrapped with ERR_PTR(). */ -struct irq_domain *irq_domain_create_sim (struct fwnode_handle *fwnode, +struct irq_domain *irq_domain_add_sim_fwnode (struct fwnode_handle *fwnode,unsigned int num_irqs) { -return irq_domain_create_sim_full (fwnode, num_irqs,NULL ,NULL ); +return irq_domain_add_sim_full_fwnode (fwnode, num_irqs,NULL ,NULL ); } -EXPORT_SYMBOL_GPL (irq_domain_create_sim); +EXPORT_SYMBOL_GPL (irq_domain_add_sim_fwnode); -struct irq_domain *irq_domain_create_sim_full (struct fwnode_handle *fwnode, +struct irq_domain *irq_domain_add_sim_full_fwnode (struct fwnode_handle *fwnode,unsigned int num_irqs,const struct irq_sim_ops *ops,void *data)
@@ -211,7 +211,7 @@ struct irq_domain *irq_domain_create_sim_full(struct fwnode_handle *fwnode,if (!pending)return ERR_PTR (-ENOMEM ); - work_ctx->domain =irq_domain_create_linear (fwnode, num_irqs, + work_ctx->domain =irq_domain_add_linear_fwnode (fwnode, num_irqs, &irq_sim_domain_ops, work_ctx);if (!work_ctx->domain)
@@ -227,7 +227,7 @@ struct irq_domain *irq_domain_create_sim_full(struct fwnode_handle *fwnode,return no_free_ptr (work_ctx)->domain; } -EXPORT_SYMBOL_GPL (irq_domain_create_sim_full); +EXPORT_SYMBOL_GPL (irq_domain_add_sim_full_fwnode);/** * irq_domain_remove_sim - Deinitialize the interrupt simulator domain: free
@@ -255,7 +255,7 @@ static void devm_irq_domain_remove_sim(void *data) }/** -* devm_irq_domain_create_sim - Create a new interrupt simulator for +* devm_irq_domain_add_sim_fwnode - Create a new interrupt simulator for * a managed device. * * @dev: Device to initialize the simulator object for.
@@ -265,17 +265,17 @@ static void devm_irq_domain_remove_sim(void *data)* On success: return a new irq_domain object. * On failure: a negative errno wrapped with ERR_PTR(). */ -struct irq_domain *devm_irq_domain_create_sim (struct device *dev, +struct irq_domain *devm_irq_domain_add_sim_fwnode (struct device *dev,struct fwnode_handle *fwnode,unsigned int num_irqs) { -return devm_irq_domain_create_sim_full (dev, fwnode, num_irqs, +return devm_irq_domain_add_sim_full_fwnode (dev, fwnode, num_irqs,NULL ,NULL ); } -EXPORT_SYMBOL_GPL (devm_irq_domain_create_sim); +EXPORT_SYMBOL_GPL (devm_irq_domain_add_sim_fwnode);struct irq_domain * -devm_irq_domain_create_sim_full(struct device *dev, +devm_irq_domain_add_sim_full_fwnode(struct device *dev, struct fwnode_handle *fwnode, unsigned int num_irqs, const struct irq_sim_ops *ops,
@@ -284,7 +284,7 @@ devm_irq_domain_create_sim_full(struct device *dev,struct irq_domain *domain;int ret; - domain =irq_domain_create_sim_full (fwnode, num_irqs, ops, data); + domain =irq_domain_add_sim_full_fwnode (fwnode, num_irqs, ops, data);if (IS_ERR (domain))return domain;
@@ -294,4 +294,4 @@ devm_irq_domain_create_sim_full(struct device *dev,return domain; } -EXPORT_SYMBOL_GPL (devm_irq_domain_create_sim_full); +EXPORT_SYMBOL_GPL (devm_irq_domain_add_sim_full_fwnode);
kernel/irq/irqdomain.c +5 -5
@@ -443,7 +443,7 @@ void irq_domain_update_bus_token(struct irq_domain *domain,EXPORT_SYMBOL_GPL (irq_domain_update_bus_token);/** -* irq_domain_create_simple() - Register an irq_domain and optionally map a range of irqs +* irq_domain_add_simple_fwnode() - Register an irq_domain and optionally map a range of irqs * @fwnode: firmware node for the interrupt controller * @size: total number of irqs in mapping * @first_irq: first number of irq block assigned to the domain,
@@ -460,7 +460,7 @@ EXPORT_SYMBOL_GPL(irq_domain_update_bus_token);* irqs get mapped dynamically on the fly. However, if the controller requires * static virq assignments (non-DT boot) then it will set that up correctly. */ -struct irq_domain *irq_domain_create_simple(struct fwnode_handle *fwnode, +struct irq_domain *irq_domain_add_simple_fwnode(struct fwnode_handle *fwnode, unsigned int size, unsigned int first_irq, const struct irq_domain_ops *ops,
@@ -478,9 +478,9 @@ struct irq_domain *irq_domain_create_simple(struct fwnode_handle *fwnode,return IS_ERR (domain) ?NULL : domain; } -EXPORT_SYMBOL_GPL (irq_domain_create_simple); +EXPORT_SYMBOL_GPL (irq_domain_add_simple_fwnode); -struct irq_domain *irq_domain_create_legacy(struct fwnode_handle *fwnode, +struct irq_domain *irq_domain_add_legacy_fwnode(struct fwnode_handle *fwnode, unsigned int size, unsigned int first_irq, irq_hw_number_t first_hwirq,
@@ -500,7 +500,7 @@ struct irq_domain *irq_domain_create_legacy(struct fwnode_handle *fwnode,return IS_ERR (domain) ?NULL : domain; } -EXPORT_SYMBOL_GPL (irq_domain_create_legacy); +EXPORT_SYMBOL_GPL (irq_domain_add_legacy_fwnode);/** * irq_find_matching_fwspec() - Locates a domain for a given fwspec
kernel/irq/msi.c +1 -1
@@ -858,7 +858,7 @@ static struct irq_domain *__msi_create_irq_domain(struct fwnode_handle *fwnode,if (info->flags &MSI_FLAG_USE_DEF_CHIP_OPS )msi_domain_update_chip_ops (info); - domain =irq_domain_create_hierarchy (parent, flags |IRQ_DOMAIN_FLAG_MSI ,0 , + domain =irq_domain_add_hierarchy_fwnode (parent, flags |IRQ_DOMAIN_FLAG_MSI ,0 , fwnode, &msi_domain_ops, info);if (domain) {
sound/soc/codecs/rt5677.c +1 -1
@@ -5509,7 +5509,7 @@ static int rt5677_init_irq(struct i2c_client *i2c) RT5677_GPIO1_PIN_MASK, RT5677_GPIO1_PIN_IRQ);/* Ready to listen for interrupts */ - rt5677->domain =irq_domain_create_linear (dev_fwnode (&i2c->dev), + rt5677->domain =irq_domain_add_linear_fwnode (dev_fwnode (&i2c->dev),RT5677_IRQ_NUM , &rt5677_domain_ops, rt5677);if (!rt5677->domain) {dev_err (&i2c->dev,"Failed to create IRQ domain\n" );
Signature · 1 line
2.48.0
PATCH 11/18 irqdomain: Rename _instantiate functions to _add
In reply to Jiri Slaby (SUSE)Continuing the unifying idea of previous patches, all "_instantiate" functions are renamed to "_add".
Now, the interface is:
* dom = irq_domain_add(info)
* irq_domain_remove(dom)
--- arch/um/drivers/virt-pci.c | 2 +- drivers/base/regmap/regmap-irq.c | 2 +- drivers/irqchip/irq-lan966x-oic.c | 2 +- include/linux/irqdomain.h | 16 ++++++++-------- kernel/irq/devres.c | 8 ++++---- kernel/irq/irqdomain.c | 16 ++++++++-------- 6 files changed, 23 insertions(+), 23 deletions(-)
arch/um/drivers/virt-pci.c +1 -1
@@ -1023,7 +1023,7 @@ static int __init um_pci_init(void) } inner_domain_info.fwnode = um_pci_fwnode; - um_pci_inner_domain =irq_domain_instantiate (&inner_domain_info); + um_pci_inner_domain =irq_domain_add (&inner_domain_info);if (IS_ERR (um_pci_inner_domain)) { err =PTR_ERR (um_pci_inner_domain); goto free;
drivers/base/regmap/regmap-irq.c +1 -1
@@ -623,7 +623,7 @@ static int regmap_irq_create_domain(struct fwnode_handle *fwnode, int irq_base, .name_suffix = chip->domain_suffix, }; - d->domain =irq_domain_instantiate (&info); + d->domain =irq_domain_add (&info);if (IS_ERR (d->domain)) {dev_err (d->map->dev,"Failed to create IRQ domain\n" );return PTR_ERR (d->domain);
drivers/irqchip/irq-lan966x-oic.c +1 -1
@@ -251,7 +251,7 @@ static int lan966x_oic_probe(struct platform_device *pdev)return dev_err_probe (dev, lan966x_oic->irq,"failed to get the IRQ\n" ); d_info.host_data = lan966x_oic; - domain =devm_irq_domain_instantiate (dev, &d_info); + domain =devm_irq_domain_add (dev, &d_info);if (IS_ERR (domain))return dev_err_probe (dev,PTR_ERR (domain),"failed to instantiate the IRQ domain\n" );
include/linux/irqdomain.h +8 -8
@@ -329,8 +329,8 @@ struct irq_domain_info {void (*exit)(struct irq_domain *d); }; -struct irq_domain *irq_domain_instantiate (const struct irq_domain_info *info); -struct irq_domain *devm_irq_domain_instantiate (struct device *dev, +struct irq_domain *irq_domain_add (const struct irq_domain_info *info); +struct irq_domain *devm_irq_domain_add (struct device *dev,const struct irq_domain_info *info); struct irq_domain *irq_domain_add_simple_fwnode(struct fwnode_handle *fwnode,
@@ -445,7 +445,7 @@ static inline struct irq_domain *irq_domain_add_linear_of_node(struct device_nod .ops = ops, .host_data = host_data, }; -struct irq_domain *d =irq_domain_instantiate (&info); +struct irq_domain *d =irq_domain_add (&info);return IS_ERR (d) ?NULL : d; }
@@ -463,7 +463,7 @@ static inline struct irq_domain *irq_domain_add_nomap_of_node(struct device_node .ops = ops, .host_data = host_data, }; -struct irq_domain *d =irq_domain_instantiate (&info); +struct irq_domain *d =irq_domain_add (&info);return IS_ERR (d) ?NULL : d; }
@@ -481,7 +481,7 @@ static inline struct irq_domain *irq_domain_add_tree_of_node(struct device_node .ops = ops, .host_data = host_data, }; -struct irq_domain *d =irq_domain_instantiate (&info); +struct irq_domain *d =irq_domain_add (&info);return IS_ERR (d) ?NULL : d; }
@@ -498,7 +498,7 @@ static inline struct irq_domain *irq_domain_add_linear_fwnode(struct fwnode_hand .ops = ops, .host_data = host_data, }; -struct irq_domain *d =irq_domain_instantiate (&info); +struct irq_domain *d =irq_domain_add (&info);return IS_ERR (d) ?NULL : d; }
@@ -513,7 +513,7 @@ static inline struct irq_domain *irq_domain_add_tree_fwnode(struct fwnode_handle .ops = ops, .host_data = host_data, }; -struct irq_domain *d =irq_domain_instantiate (&info); +struct irq_domain *d =irq_domain_add (&info);return IS_ERR (d) ?NULL : d; }
@@ -638,7 +638,7 @@ static inline struct irq_domain *irq_domain_add_hierarchy_fwnode(struct irq_doma .domain_flags = flags, .parent = parent, }; -struct irq_domain *d =irq_domain_instantiate (&info); +struct irq_domain *d =irq_domain_add (&info);return IS_ERR (d) ?NULL : d; }
kernel/irq/devres.c +4 -4
@@ -292,7 +292,7 @@ static void devm_irq_domain_remove(struct device *dev, void *res) }/** -* devm_irq_domain_instantiate() - Instantiate a new irq domain data for a +* devm_irq_domain_add() - Instantiate a new irq domain data for a * managed device. * @dev: Device to instantiate the domain for * @info: Domain information pointer pointing to the information for this
@@ -300,7 +300,7 @@ static void devm_irq_domain_remove(struct device *dev, void *res)* * Return: A pointer to the instantiated irq domain or an ERR_PTR value. */ -struct irq_domain *devm_irq_domain_instantiate (struct device *dev, +struct irq_domain *devm_irq_domain_add (struct device *dev,const struct irq_domain_info *info) {struct irq_domain *domain;
@@ -310,7 +310,7 @@ struct irq_domain *devm_irq_domain_instantiate(struct device *dev,if (!dr)return ERR_PTR (-ENOMEM ); - domain =irq_domain_instantiate (info); + domain =irq_domain_add (info);if (!IS_ERR (domain)) { *dr = domain;devres_add (dev, dr);
@@ -320,5 +320,5 @@ struct irq_domain *devm_irq_domain_instantiate(struct device *dev, return domain; } -EXPORT_SYMBOL_GPL (devm_irq_domain_instantiate); +EXPORT_SYMBOL_GPL (devm_irq_domain_add);#endif /* CONFIG_IRQ_DOMAIN */
kernel/irq/irqdomain.c +8 -8
@@ -305,8 +305,8 @@ static void irq_domain_instantiate_descs(const struct irq_domain_info *info) } } -static struct irq_domain *__irq_domain_instantiate (const struct irq_domain_info *info, -bool cond_alloc_descs,bool force_associate) +static struct irq_domain *__irq_domain_add (const struct irq_domain_info *info, +bool cond_alloc_descs,bool force_associate) {struct irq_domain *domain;int err;
@@ -363,16 +363,16 @@ static struct irq_domain *__irq_domain_instantiate(const struct irq_domain_info }/** -* irq_domain_instantiate() - Instantiate a new irq domain data structure +* irq_domain_add() - Instantiate a new irq domain data structure * @info: Domain information pointer pointing to the information for this domain * * Return: A pointer to the instantiated irq domain or an ERR_PTR value. */ -struct irq_domain *irq_domain_instantiate (const struct irq_domain_info *info) +struct irq_domain *irq_domain_add (const struct irq_domain_info *info) { -return __irq_domain_instantiate (info, false, false); +return __irq_domain_add (info, false, false); } -EXPORT_SYMBOL_GPL (irq_domain_instantiate); +EXPORT_SYMBOL_GPL (irq_domain_add);/** * irq_domain_remove() - Remove an irq domain.
@@ -474,7 +474,7 @@ struct irq_domain *irq_domain_add_simple_fwnode(struct fwnode_handle *fwnode, .ops = ops, .host_data = host_data, }; -struct irq_domain *domain =__irq_domain_instantiate (&info, true, false); +struct irq_domain *domain =__irq_domain_add (&info, true, false);return IS_ERR (domain) ?NULL : domain; }
@@ -496,7 +496,7 @@ struct irq_domain *irq_domain_add_legacy_fwnode(struct fwnode_handle *fwnode, .ops = ops, .host_data = host_data, }; -struct irq_domain *domain =__irq_domain_instantiate (&info, false, true); +struct irq_domain *domain =__irq_domain_add (&info, false, true);return IS_ERR (domain) ?NULL : domain; }
Signature · 1 line
2.48.0
PATCH 12/18 irqdomain: Switch away from irq_linear_revmap() and drop it
In reply to Jiri Slaby (SUSE)irq_linear_revmap() is deprecated, so remove all its uses and supersede them by an identical call to irq_find_mapping().
--- Documentation/core-api/irq/irq-domain.rst | 2 -- .../translations/zh_CN/core-api/irq/irq-domain.rst | 2 -- arch/powerpc/platforms/44x/uic.c | 2 +- arch/powerpc/platforms/52xx/mpc52xx_gpt.c | 2 +- arch/powerpc/platforms/52xx/mpc52xx_pic.c | 2 +- arch/powerpc/platforms/85xx/socrates_fpga_pic.c | 2 +- arch/powerpc/platforms/8xx/cpm1-ic.c | 2 +- arch/powerpc/platforms/8xx/pic.c | 2 +- arch/powerpc/platforms/cell/interrupt.c | 2 +- arch/powerpc/platforms/embedded6xx/flipper-pic.c | 2 +- arch/powerpc/platforms/embedded6xx/hlwd-pic.c | 2 +- arch/powerpc/platforms/powermac/pic.c | 2 +- arch/powerpc/sysdev/cpm2_pic.c | 2 +- arch/powerpc/sysdev/ehv_pic.c | 2 +- arch/powerpc/sysdev/ge/ge_pic.c | 2 +- arch/powerpc/sysdev/ipic.c | 2 +- arch/powerpc/sysdev/mpic.c | 4 ++-- arch/sh/boards/mach-se/7343/irq.c | 2 +- arch/sh/boards/mach-se/7722/irq.c | 2 +- drivers/gpio/gpio-idt3243x.c | 2 +- drivers/gpu/ipu-v3/ipu-common.c | 4 ++-- drivers/i2c/muxes/i2c-mux-pca954x.c | 2 +- drivers/irqchip/irq-armada-370-xp.c | 4 ++-- drivers/pinctrl/pinctrl-keembay.c | 2 +- drivers/soc/fsl/qe/qe_ic.c | 4 ++-- include/linux/irqdomain.h | 6 ------ 26 files changed, 27 insertions(+), 37 deletions(-)
Documentation/core-api/irq/irq-domain.rst +0 -2
@@ -64,8 +64,6 @@ variety of methods: mapping. - irq_find_mapping() returns a Linux IRQ number for a given domain and hwirq number, and 0 if there was no mapping -- irq_linear_revmap() is now identical to irq_find_mapping(), and is - deprecated - generic_handle_domain_irq() handles an interrupt described by a domain and a hwirq number
Documentation/translations/zh_CN/core-api/irq/irq-domain.rst +0 -2
@@ -60,8 +60,6 @@ irq_domain和一个hwirq号作为参数。 如果hwirq的映射还不存在, - irq_find_mapping()返回给定域和hwirq的Linux IRQ号,如果没有映射则返回0。 -- irq_linear_revmap()现与irq_find_mapping()相同,已被废弃。 - - generic_handle_domain_irq()处理一个由域和hwirq号描述的中断。 请注意,irq域的查找必须发生在与RCU读临界区兼容的上下文中。
arch/powerpc/platforms/44x/uic.c +1 -1
@@ -327,5 +327,5 @@ unsigned int uic_get_irq(void) msr =mfdcr (primary_uic->dcrbase +UIC_MSR ); src =32 -ffs (msr); -return irq_linear_revmap (primary_uic->irqhost, src); +return irq_find_mapping (primary_uic->irqhost, src); }
arch/powerpc/platforms/52xx/mpc52xx_gpt.c +1 -1
@@ -369,7 +369,7 @@ struct mpc52xx_gpt_priv *mpc52xx_gpt_from_irq(int irq)mutex_lock (&mpc52xx_gpt_list_mutex);list_for_each (pos, &mpc52xx_gpt_list) { gpt = container_of(pos, struct mpc52xx_gpt_priv, list); -if (gpt->irqhost && irq ==irq_linear_revmap (gpt->irqhost,0 )) { +if (gpt->irqhost && irq ==irq_find_mapping (gpt->irqhost,0 )) {mutex_unlock (&mpc52xx_gpt_list_mutex);return gpt; }
arch/powerpc/platforms/52xx/mpc52xx_pic.c +1 -1
@@ -515,5 +515,5 @@ unsigned int mpc52xx_get_irq(void)return 0 ; } -return irq_linear_revmap (mpc52xx_irqhost, irq); +return irq_find_mapping (mpc52xx_irqhost, irq); }
arch/powerpc/platforms/85xx/socrates_fpga_pic.c +1 -1
@@ -83,7 +83,7 @@ static inline unsigned int socrates_fpga_pic_get_irq(unsigned int irq)if (cause >> (i +16 ))break ; } -return irq_linear_revmap (socrates_fpga_pic_irq_host, +return irq_find_mapping (socrates_fpga_pic_irq_host, (irq_hw_number_t )i); }
arch/powerpc/platforms/8xx/cpm1-ic.c +1 -1
@@ -59,7 +59,7 @@ static int cpm_get_irq(struct irq_desc *desc) cpm_vec =in_be16 (&data->reg->cpic_civr); cpm_vec >>=11 ; -return irq_linear_revmap (data->host, cpm_vec); +return irq_find_mapping (data->host, cpm_vec); }static void cpm_cascade (struct irq_desc *desc)
arch/powerpc/platforms/8xx/pic.c +1 -1
@@ -80,7 +80,7 @@ unsigned int mpc8xx_get_irq(void)if (irq ==PIC_VEC_SPURRIOUS )return 0 ; -return irq_linear_revmap (mpc8xx_pic_host, irq); +return irq_find_mapping (mpc8xx_pic_host, irq); }
arch/powerpc/platforms/cell/interrupt.c +1 -1
@@ -138,7 +138,7 @@ static unsigned int iic_get_irq(void)in_be64 ((u64 __iomem *) &iic->regs->pending_destr);if (!(pending.flags &CBE_IIC_IRQ_VALID ))return 0 ; - virq =irq_linear_revmap (iic_host,iic_pending_to_hwnum (pending)); + virq =irq_find_mapping (iic_host,iic_pending_to_hwnum (pending));if (!virq)return 0 ; iic->eoi_stack[++iic->eoi_ptr] = pending.prio;
arch/powerpc/platforms/embedded6xx/flipper-pic.c +1 -1
@@ -172,7 +172,7 @@ unsigned int flipper_pic_get_irq(void)return 0 ;/* no more IRQs pending */ irq =__ffs (irq_status); -return irq_linear_revmap (flipper_irq_host, irq); +return irq_find_mapping (flipper_irq_host, irq); }/*
arch/powerpc/platforms/embedded6xx/hlwd-pic.c +1 -1
@@ -189,7 +189,7 @@ static struct irq_domain *__init hlwd_pic_init(struct device_node *np)unsigned int hlwd_pic_get_irq (void ) {unsigned int hwirq =__hlwd_pic_get_irq (hlwd_irq_host); -return hwirq ?irq_linear_revmap (hlwd_irq_host, hwirq) :0 ; +return hwirq ?irq_find_mapping (hlwd_irq_host, hwirq) :0 ; }/*
arch/powerpc/platforms/powermac/pic.c +1 -1
@@ -250,7 +250,7 @@ static unsigned int pmac_pic_get_irq(void)raw_spin_unlock_irqrestore (&pmac_pic_lock, flags);if (unlikely (irq <0 ))return 0 ; -return irq_linear_revmap (pmac_pic_host, irq); +return irq_find_mapping (pmac_pic_host, irq); } static int pmac_pic_host_match(struct irq_domain *h, struct device_node *node,
arch/powerpc/sysdev/cpm2_pic.c +1 -1
@@ -207,7 +207,7 @@ unsigned int cpm2_get_irq(void)if (irq ==0 )return (-1 ); -return irq_linear_revmap (cpm2_pic_host, irq); +return irq_find_mapping (cpm2_pic_host, irq); } static int cpm2_pic_host_map(struct irq_domain *h, unsigned int virq,
arch/powerpc/sysdev/ehv_pic.c +1 -1
@@ -175,7 +175,7 @@ unsigned int ehv_pic_get_irq(void)* this will also setup revmap[] in the slow path for the first * time, next calls will always use fast path by indexing revmap */ -return irq_linear_revmap (global_ehv_pic->irqhost, irq); +return irq_find_mapping (global_ehv_pic->irqhost, irq); } static int ehv_pic_host_match(struct irq_domain *h, struct device_node *node,
arch/powerpc/sysdev/ge/ge_pic.c +1 -1
@@ -244,7 +244,7 @@ unsigned int gef_pic_get_irq(void)if (active & (0x1 << hwirq))break ; } - virq =irq_linear_revmap (gef_pic_irq_host, + virq =irq_find_mapping (gef_pic_irq_host, (irq_hw_number_t )hwirq); }
arch/powerpc/sysdev/ipic.c +1 -1
@@ -801,7 +801,7 @@ unsigned int ipic_get_irq(void)if (irq ==0 )/* 0 --> no irq is pending */ return 0 ; -return irq_linear_revmap (primary_ipic->irqhost, irq); +return irq_find_mapping (primary_ipic->irqhost, irq); }#ifdef CONFIG_SUSPEND
arch/powerpc/sysdev/mpic.c +2 -2
@@ -1785,7 +1785,7 @@ static unsigned int _mpic_get_one_irq(struct mpic *mpic, int reg)return 0 ; } -return irq_linear_revmap (mpic->irqhost, src); +return irq_find_mapping (mpic->irqhost, src); }unsigned int mpic_get_one_irq (struct mpic *mpic)
@@ -1823,7 +1823,7 @@ unsigned int mpic_get_coreint_irq(void) return 0; } -return irq_linear_revmap (mpic->irqhost, src); +return irq_find_mapping (mpic->irqhost, src);#else return 0 ;#endif
arch/sh/boards/mach-se/7343/irq.c +1 -1
@@ -70,7 +70,7 @@ static void __init se7343_gc_init(void)struct irq_chip_type *ct;unsigned int irq_base; - irq_base =irq_linear_revmap (se7343_irq_domain,0 ); + irq_base =irq_find_mapping (se7343_irq_domain,0 ); gc =irq_alloc_generic_chip (DRV_NAME ,1 , irq_base, se7343_irq_regs, handle_level_irq);
arch/sh/boards/mach-se/7722/irq.c +1 -1
@@ -69,7 +69,7 @@ static void __init se7722_gc_init(void)struct irq_chip_type *ct;unsigned int irq_base; - irq_base =irq_linear_revmap (se7722_irq_domain,0 ); + irq_base =irq_find_mapping (se7722_irq_domain,0 ); gc =irq_alloc_generic_chip (DRV_NAME ,1 , irq_base, se7722_irq_regs, handle_level_irq);
drivers/gpio/gpio-idt3243x.c +1 -1
@@ -37,7 +37,7 @@ static void idt_gpio_dispatch(struct irq_desc *desc) pending =readl (ctrl->pic +IDT_PIC_IRQ_PEND ); pending &= ~ctrl->mask_cache;for_each_set_bit (bit, &pending, gc->ngpio) { - virq =irq_linear_revmap (gc->irq.domain, bit); + virq =irq_find_mapping (gc->irq.domain, bit);if (virq)generic_handle_irq (virq); }
drivers/gpu/ipu-v3/ipu-common.c +2 -2
@@ -1046,7 +1046,7 @@ int ipu_map_irq(struct ipu_soc *ipu, int irq) {int virq; - virq =irq_linear_revmap (ipu->domain, irq); + virq =irq_find_mapping (ipu->domain, irq);if (!virq) virq =irq_create_mapping (ipu->domain, irq);
@@ -1257,7 +1257,7 @@ static void ipu_irq_exit(struct ipu_soc *ipu)/* TODO: remove irq_domain_generic_chips */ for (i =0 ; i <IPU_NUM_IRQS ; i++) { - irq =irq_linear_revmap (ipu->domain, i); + irq =irq_find_mapping (ipu->domain, i);if (irq)irq_dispose_mapping (irq); }
drivers/i2c/muxes/i2c-mux-pca954x.c +1 -1
@@ -414,7 +414,7 @@ static irqreturn_t pca954x_irq_handler(int irq, void *dev_id) pending = (ret >>PCA954X_IRQ_OFFSET ) & (BIT (data->chip->nchans) -1 );for_each_set_bit (i, &pending, data->chip->nchans) -handle_nested_irq (irq_linear_revmap (data->irq, i)); +handle_nested_irq (irq_find_mapping (data->irq, i));return IRQ_RETVAL (pending); }
drivers/irqchip/irq-armada-370-xp.c +2 -2
@@ -546,7 +546,7 @@ static void mpic_reenable_percpu(struct mpic *mpic) {/* Re-enable per-CPU interrupts that were enabled before suspend */ for (irq_hw_number_t i =0 ; i <MPIC_PER_CPU_IRQS_NR ; i++) { -unsigned int virq =irq_linear_revmap (mpic->domain, i); +unsigned int virq =irq_find_mapping (mpic->domain, i);struct irq_data *d;if (!virq || !irq_percpu_is_enabled (virq))
@@ -740,7 +740,7 @@ static void mpic_resume(void)/* Re-enable interrupts */ for (irq_hw_number_t i =0 ; i < mpic->domain->hwirq_max; i++) { -unsigned int virq =irq_linear_revmap (mpic->domain, i); +unsigned int virq =irq_find_mapping (mpic->domain, i);struct irq_data *d;if (!virq)
drivers/pinctrl/pinctrl-keembay.c +1 -1
@@ -1268,7 +1268,7 @@ static void keembay_gpio_irq_handler(struct irq_desc *desc)for_each_set_clump8 (bit, clump, ®,BITS_PER_TYPE (typeof (reg))) { pin = clump & ~KEEMBAY_GPIO_IRQ_ENABLE ; val =keembay_read_pin (kpc->base0 +KEEMBAY_GPIO_DATA_IN , pin); - kmb_irq =irq_linear_revmap (gc->irq.domain, pin); + kmb_irq =irq_find_mapping (gc->irq.domain, pin);/* Checks if the interrupt is enabled */ if (val && (clump &KEEMBAY_GPIO_IRQ_ENABLE ))
drivers/soc/fsl/qe/qe_ic.c +2 -2
@@ -344,7 +344,7 @@ static unsigned int qe_ic_get_low_irq(struct qe_ic *qe_ic)if (irq ==0 )return 0 ; -return irq_linear_revmap (qe_ic->irqhost, irq); +return irq_find_mapping (qe_ic->irqhost, irq); }/* Return an interrupt vector or 0 if no interrupt is pending. */
@@ -360,7 +360,7 @@ static unsigned int qe_ic_get_high_irq(struct qe_ic *qe_ic)if (irq ==0 )return 0 ; -return irq_linear_revmap (qe_ic->irqhost, irq); +return irq_find_mapping (qe_ic->irqhost, irq); }static void qe_ic_cascade_low (struct irq_desc *desc)
include/linux/irqdomain.h +0 -6
@@ -564,12 +564,6 @@ static inline unsigned int irq_find_mapping(struct irq_domain *domain,return 0 ; } -static inline unsigned int irq_linear_revmap (struct irq_domain *domain, -irq_hw_number_t hwirq) -{ -return irq_find_mapping (domain, hwirq); -} -extern const struct irq_domain_ops irq_domain_simple_ops;/* stock xlate functions */
Signature · 1 line
2.48.0
PATCH 13/18 irqdomain.h: Improve kernel-docs of functions
In reply to Jiri Slaby (SUSE)Many of irqdomain.h's functions are referenced in Documentation/ but are not properly documented. Therefore, document these.
And use "Returns:" tag consistently, so that it is properly generated to the resulting docs.
--- include/linux/irqdomain.h | 62 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 61 insertions(+), 1 deletion(-)
include/linux/irqdomain.h +61 -1
@@ -417,6 +417,26 @@ static inline struct irq_domain *irq_find_host(struct device_node *node)return d; } +/** +* irq_domain_add_simple_of_node() - Register an irq_domain and optionally map a range of irqs +* @of_node: pointer to interrupt controller's device tree node. +* @size: total number of irqs in mapping +* @first_irq: first number of irq block assigned to the domain, +* pass zero to assign irqs on-the-fly. If first_irq is non-zero, then +* pre-map all of the irqs in the domain to virqs starting at first_irq. +* @ops: domain callbacks +* @host_data: Controller private data pointer +* +* Allocates an irq_domain, and optionally if @first_irq is positive then also +* allocate irq_descs and map all of the hwirqs to virqs starting at @first_irq. +* +* This is intended to implement the expected behaviour for most +* interrupt controllers. If device tree is used, then @first_irq will be 0 and +* irqs get mapped dynamically on the fly. However, if the controller requires +* static virq assignments (non-DT boot) then it will set that up correctly. +* +* Returns: Newly created irq_domain +*/ static inline struct irq_domain *irq_domain_add_simple_of_node(struct device_node *of_node, unsigned int size, unsigned int first_irq,
@@ -486,6 +506,15 @@ static inline struct irq_domain *irq_domain_add_tree_of_node(struct device_nodereturn IS_ERR (d) ?NULL : d; } +/** +* irq_domain_add_linear_fwnode() - Allocate and register a linear revmap irq_domain. +* @fwnode: pointer to interrupt controller's FW node. +* @size: Number of interrupts in the domain. +* @ops: map/unmap domain callbacks +* @host_data: Controller private data pointer +* +* Returns: Newly created irq_domain +*/ static inline struct irq_domain *irq_domain_add_linear_fwnode(struct fwnode_handle *fwnode, unsigned int size, const struct irq_domain_ops *ops,
@@ -532,6 +561,18 @@ unsigned int irq_create_mapping_affinity(struct irq_domain *domain,unsigned int irq_create_fwspec_mapping (struct irq_fwspec *fwspec);void irq_dispose_mapping (unsigned int virq); +/** +* irq_create_mapping() - Map a hardware interrupt into linux irq space +* @domain: domain owning this hardware interrupt or NULL for default domain +* @hwirq: hardware irq number in that domain space +* +* Only one mapping per hardware interrupt is permitted. +* +* If the sense/trigger is to be specified, set_irq_type() should be called +* on the number returned from that call. +* +* Returns: Linux irq number or 0 on error +*/ static inline unsigned int irq_create_mapping (struct irq_domain *domain,irq_hw_number_t hwirq) {
@@ -542,6 +583,13 @@ struct irq_desc *__irq_resolve_mapping(struct irq_domain *domain,irq_hw_number_t hwirq, unsigned int *irq); +/** +* irq_resolve_mapping() - Find a linux irq from a hw irq number. +* @domain: domain owning this hardware interrupt +* @hwirq: hardware irq number in that domain space +* +* Returns: Interrupt descriptor +*/ static inline struct irq_desc *irq_resolve_mapping (struct irq_domain *domain,irq_hw_number_t hwirq) {
@@ -552,6 +600,8 @@ static inline struct irq_desc *irq_resolve_mapping(struct irq_domain *domain,* irq_find_mapping() - Find a linux irq from a hw irq number. * @domain: domain owning this hardware interrupt * @hwirq: hardware irq number in that domain space +* +* Returns: Linux irq number or 0 if not found */ static inline unsigned int irq_find_mapping (struct irq_domain *domain,irq_hw_number_t hwirq)
@@ -614,7 +664,8 @@ void irq_domain_reset_irq_data(struct irq_data *irq_data);* * If successful the parent is associated to the new domain and the * domain flags are set. -* Returns pointer to IRQ domain, or NULL on failure. +* +* Returns: A pointer to IRQ domain, or %NULL on failure. */ static inline struct irq_domain *irq_domain_add_hierarchy_fwnode(struct irq_domain *parent, unsigned int flags,
@@ -657,6 +708,15 @@ void irq_domain_free_irqs(unsigned int virq, unsigned int nr_irqs);int irq_domain_activate_irq (struct irq_data *irq_data,bool early);void irq_domain_deactivate_irq (struct irq_data *irq_data); +/** +* irq_domain_alloc_irqs - Allocate IRQs from domain +* @domain: domain to allocate from +* @nr_irqs: number of IRQs to allocate +* @node: NUMA node id for memory allocation +* @arg: domain specific argument +* +* See __irq_domain_alloc_irqs()' documentation. +*/ static inline int irq_domain_alloc_irqs (struct irq_domain *domain,unsigned int nr_irqs,int node,void *arg) {
Signature · 1 line
2.48.0
PATCH 14/18 docs: irq/concepts: Add commas and reflow
In reply to Jiri Slaby (SUSE)For easier reading, it is always desired to add commas at some places in text. Like before adverbs or after fronted sentences.
--- Documentation/core-api/irq/concepts.rst | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-)
Documentation/core-api/irq/concepts.rst +9 -10
@@ -2,23 +2,22 @@ What is an IRQ? =============== -An IRQ is an interrupt request from a device. -Currently they can come in over a pin, or over a packet. -Several devices may be connected to the same pin thus -sharing an IRQ. +An IRQ is an interrupt request from a device. Currently, they can come +in over a pin, or over a packet. Several devices may be connected to +the same pin thus sharing an IRQ. An IRQ number is a kernel identifier used to talk about a hardware -interrupt source. Typically this is an index into the global irq_desc -array, but except for what linux/interrupt.h implements the details +interrupt source. Typically, this is an index into the global irq_desc +array, but except for what linux/interrupt.h implements, the details are architecture specific. An IRQ number is an enumeration of the possible interrupt sources on a -machine. Typically what is enumerated is the number of input pins on -all of the interrupt controller in the system. In the case of ISA +machine. Typically, what is enumerated is the number of input pins on +all of the interrupt controllers in the system. In the case of ISA, what is enumerated are the 16 input pins on the two i8259 interrupt controllers. Architectures can assign additional meaning to the IRQ numbers, and -are encouraged to in the case where there is any manual configuration -of the hardware involved. The ISA IRQs are a classic example of +are encouraged to in the case where there is any manual configuration +of the hardware involved. The ISA IRQs are a classic example of assigning this kind of additional meaning.
Signature · 1 line
2.48.0
PATCH 15/18 docs: irq/concepts: Minor improvements
In reply to Jiri Slaby (SUSE)Just note in the docs:
1) A PCI as an example for shared interrupts,
2) a sparse tree can be used for interrupts too, and
3) two i8259s have 8 pins.
--- Documentation/core-api/irq/concepts.rst | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-)
Documentation/core-api/irq/concepts.rst +7 -5
@@ -4,18 +4,20 @@ What is an IRQ? An IRQ is an interrupt request from a device. Currently, they can come in over a pin, or over a packet. Several devices may be connected to -the same pin thus sharing an IRQ. +the same pin thus sharing an IRQ. Such as on legacy PCI bus: All devices +typically share 4 lanes/pins. Note that each device can request an +interrupt on each of the lanes. An IRQ number is a kernel identifier used to talk about a hardware interrupt source. Typically, this is an index into the global irq_desc -array, but except for what linux/interrupt.h implements, the details -are architecture specific. +array or sparse_irqs tree. But except for what linux/interrupt.h +implements, the details are architecture specific. An IRQ number is an enumeration of the possible interrupt sources on a machine. Typically, what is enumerated is the number of input pins on all of the interrupt controllers in the system. In the case of ISA, -what is enumerated are the 16 input pins on the two i8259 interrupt -controllers. +what is enumerated are the 8 input pins on each of the two i8259 +interrupt controllers. Architectures can assign additional meaning to the IRQ numbers, and are encouraged to in the case where there is any manual configuration
Signature · 1 line
2.48.0
PATCH 16/18 docs: irq-domain.rst: Simple improvements
In reply to Jiri Slaby (SUSE)The improvements include:
* Capitals in headlines.
* Added commas: for easier reading, it is always desired to add commas at some places in text. Like before adverbs or after fronted sentences.
* 3rd person -> add 's' to verbs.
* End some sentences with period and start a new one. Avoid thus heavy sentences.
--- Documentation/core-api/irq/irq-domain.rst | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-)
Documentation/core-api/irq/irq-domain.rst +11 -11
@@ -1,19 +1,19 @@ =============================================== -The irq_domain interrupt number mapping library +The irq_domain Interrupt Number Mapping Library =============================================== The current design of the Linux kernel uses a single large number space where each separate IRQ source is assigned a different number. This is simple when there is only one interrupt controller, but in -systems with multiple interrupt controllers the kernel must ensure +systems with multiple interrupt controllers, the kernel must ensure that each one gets assigned non-overlapping allocations of Linux IRQ numbers. The number of interrupt controllers registered as unique irqchips -show a rising tendency: for example subdrivers of different kinds +shows a rising tendency. For example, subdrivers of different kinds such as GPIO controllers avoid reimplementing identical callback mechanisms as the IRQ core system by modelling their interrupt -handlers as irqchips, i.e. in effect cascading interrupt controllers. +handlers as irqchips. I.e. in effect cascading interrupt controllers. Here the interrupt number loose all kind of correspondence to hardware interrupt numbers: whereas in the past, IRQ numbers could
@@ -21,15 +21,15 @@ be chosen so they matched the hardware IRQ line into the root interrupt controller (i.e. the component actually fireing the interrupt line to the CPU) nowadays this number is just a number. -For this reason we need a mechanism to separate controller-local -interrupt numbers, called hardware irq's, from Linux IRQ numbers. +For this reason, we need a mechanism to separate controller-local +interrupt numbers, called hardware IRQs, from Linux IRQ numbers. The irq_alloc_desc*() and irq_free_desc*() APIs provide allocation of irq numbers, but they don't provide any support for reverse mapping of the controller-local IRQ (hwirq) number into the Linux IRQ number space. -The irq_domain library adds mapping between hwirq and IRQ numbers on +The irq_domain library adds a mapping between hwirq and IRQ numbers on top of the irq_alloc_desc*() API. An irq_domain to manage mapping is preferred over interrupt controller drivers open coding their own reverse mapping scheme.
@@ -38,7 +38,7 @@ irq_domain also implements translation from an abstract irq_fwspec structure to hwirq numbers (Device Tree and ACPI GSI so far), and can be easily extended to support other IRQ topology data sources. -irq_domain usage +irq_domain Usage ================ An interrupt controller driver creates and registers an irq_domain by
@@ -78,7 +78,7 @@ If the driver has the Linux IRQ number or the irq_data pointer, and needs to know the associated hwirq number (such as in the irq_chip callbacks) then it can be directly obtained from irq_data->hwirq. -Types of irq_domain mappings +Types of irq_domain Mappings ============================ There are several mechanisms available for reverse mapping from hwirq
@@ -110,7 +110,7 @@ the former accepts an Open Firmware specific 'struct device_node', while the latter accepts a more general abstraction 'struct fwnode_handle'. -The majority of drivers should use the linear map. +The majority of drivers should use the Linear map. Tree ----
@@ -216,7 +216,7 @@ the first argument is different - the former accepts an Open Firmware specific 'struct device_node', while the latter accepts a more general abstraction 'struct fwnode_handle'. -Hierarchy IRQ domain +Hierarchy IRQ Domain -------------------- On some architectures, there may be multiple interrupt controllers
Signature · 1 line
2.48.0
PATCH 17/18 docs: irqdomain: Update
In reply to Jiri Slaby (SUSE)The irqdomain documentaion became obsolete over time. Update and extend it a bit with respect to the current code and HW.
Most notably the doubled documentation of irq_domain (from .rst and .h) was unified and let only in .rst. A reference link was added to .h.
Furthermore:
* Some 'struct' keywords added, so that the respective structs are hyperlinked.
* :c:member: used where appropriate to mark a member of a struct.
* Some wording rephrased to improve readability/understanding.
--- Documentation/core-api/irq/irq-domain.rst | 123 +++++++++++++--------- include/linux/irqdomain.h | 26 +---- 2 files changed, 76 insertions(+), 73 deletions(-)
Documentation/core-api/irq/irq-domain.rst +74 -49
@@ -3,8 +3,8 @@ The irq_domain Interrupt Number Mapping Library =============================================== The current design of the Linux kernel uses a single large number -space where each separate IRQ source is assigned a different number. -This is simple when there is only one interrupt controller, but in +space where each separate IRQ source is assigned a unique number. +This is simple when there is only one interrupt controller. But in systems with multiple interrupt controllers, the kernel must ensure that each one gets assigned non-overlapping allocations of Linux IRQ numbers.
@@ -15,46 +15,64 @@ such as GPIO controllers avoid reimplementing identical callback mechanisms as the IRQ core system by modelling their interrupt handlers as irqchips. I.e. in effect cascading interrupt controllers. -Here the interrupt number loose all kind of correspondence to -hardware interrupt numbers: whereas in the past, IRQ numbers could -be chosen so they matched the hardware IRQ line into the root -interrupt controller (i.e. the component actually fireing the -interrupt line to the CPU) nowadays this number is just a number. +So in the past, IRQ numbers could be chosen so that they match the +hardware IRQ line into the root interrupt controller (i.e. the +component actually firing the interrupt line to the CPU). Nowadays, +this number is just a number and the number loose all kind of +correspondence to hardware interrupt numbers. For this reason, we need a mechanism to separate controller-local interrupt numbers, called hardware IRQs, from Linux IRQ numbers. The irq_alloc_desc*() and irq_free_desc*() APIs provide allocation of -irq numbers, but they don't provide any support for reverse mapping of +IRQ numbers, but they don't provide any support for reverse mapping of the controller-local IRQ (hwirq) number into the Linux IRQ number space. The irq_domain library adds a mapping between hwirq and IRQ numbers on -top of the irq_alloc_desc*() API. An irq_domain to manage mapping is -preferred over interrupt controller drivers open coding their own +top of the irq_alloc_desc*() API. An irq_domain to manage the mapping +is preferred over interrupt controller drivers open coding their own reverse mapping scheme. -irq_domain also implements translation from an abstract irq_fwspec -structure to hwirq numbers (Device Tree and ACPI GSI so far), and can -be easily extended to support other IRQ topology data sources. +irq_domain also implements a translation from an abstract struct +irq_fwspec to hwirq numbers (Device Tree, non-DT firmware node, ACPI +GSI, and software node so far), and can be easily extended to support +other IRQ topology data sources. The implementation is performed +without any extra platform support code. irq_domain Usage ================ -An interrupt controller driver creates and registers an irq_domain by -calling one of the irq_domain_add_*_of_node() or -irq_domain_add_*_fwnode() functions (each mapping method has a -different allocator function, more on that later). The function will -return a pointer to the irq_domain on success. The caller must provide -the allocator function with an irq_domain_ops structure. +struct irq_domain could be defined as an irq domain controller. That +is, it handles the mapping between hardware and virtual interrupt +numbers for a given interrupt domain. The domain structure is +generally created by the PIC code for a given PIC instance (though a +domain can cover more than one PIC if they have a flat number model). +It is the domain callbacks that are responsible for setting the +irq_chip on a given irq_desc after it has been mapped. + +The host code and data structures use a fwnode_handle pointer to +identify the domain. In some cases, and in order to preserve source +code compatibility, this fwnode pointer is "upgraded" to a DT +device_node. For those firmware infrastructures that do not provide a +unique identifier for an interrupt controller, the irq_domain code +offers a fwnode allocator. + +An interrupt controller driver creates and registers a struct +irq_domain by calling one of the irq_domain_add_*_of_node() or +irq_domain_add_*_fwnode() functions (each mapping method has a different +allocator function, more on that later). The function will return a +pointer to the struct irq_domain on success. The caller must provide +the allocator function with a struct irq_domain_ops pointer. In most cases, the irq_domain will begin empty without any mappings between hwirq and IRQ numbers. Mappings are added to the irq_domain by calling irq_create_mapping() which accepts the irq_domain and a -hwirq number as arguments. If a mapping for the hwirq doesn't already -exist then it will allocate a new Linux irq_desc, associate it with -the hwirq, and call the .map() callback so the driver can perform any -required hardware setup. +hwirq number as arguments. If a mapping for the hwirq doesn't already +exist, irq_create_mapping() allocates a new Linux irq_desc, associates +it with the hwirq, and calls the :c:member:`irq_domain_ops.map()` +callback. In there, the driver can perform any required hardware +setup. Once a mapping has been established, it can be retrieved or used via a variety of methods:
@@ -76,7 +94,8 @@ be allocated. If the driver has the Linux IRQ number or the irq_data pointer, and needs to know the associated hwirq number (such as in the irq_chip -callbacks) then it can be directly obtained from irq_data->hwirq. +callbacks) then it can be directly obtained from +:c:member:`irq_data.hwirq`. Types of irq_domain Mappings ============================
@@ -257,20 +276,40 @@ There are four major interfaces to use hierarchy irq_domain: 4) irq_domain_deactivate_irq(): deactivate interrupt controller hardware to stop delivering the interrupt. -Following changes are needed to support hierarchy irq_domain: +The following is needed to support hierarchy irq_domain: -1) a new field 'parent' is added to struct irq_domain; it's used to +1) The :c:member:`parent` field in struct irq_domain is used to maintain irq_domain hierarchy information. -2) a new field 'parent_data' is added to struct irq_data; it's used to - build hierarchy irq_data to match hierarchy irq_domains. The irq_data - is used to store irq_domain pointer and hardware irq number. -3) new callbacks are added to struct irq_domain_ops to support hierarchy - irq_domain operations. - -With support of hierarchy irq_domain and hierarchy irq_data ready, an -irq_domain structure is built for each interrupt controller, and an +2) The :c:member:`parent_data` field in struct irq_data is used to + build hierarchy irq_data to match hierarchy irq_domains. The + irq_data is used to store irq_domain pointer and hardware irq + number. +3) The :c:member:`alloc()`, :c:member:`free()`, and other callbacks in + struct irq_domain_ops to support hierarchy irq_domain operations. + +With the support of hierarchy irq_domain and hierarchy irq_data ready, +an irq_domain structure is built for each interrupt controller, and an irq_data structure is allocated for each irq_domain associated with an -IRQ. Now we could go one step further to support stacked(hierarchy) +IRQ. + +For an interrupt controller driver to support hierarchy irq_domain, it +needs to: + +1) Implement irq_domain_ops.alloc() and irq_domain_ops.free() +2) Optionally, implement irq_domain_ops.activate() and + irq_domain_ops.deactivate(). +3) Optionally, implement an irq_chip to manage the interrupt controller + hardware. +4) There is no need to implement irq_domain_ops.map() and + irq_domain_ops.unmap(). They are unused with hierarchy irq_domain. + +Note the hierarchy irq_domain is in no way x86-specific, and is +heavily used to support other architectures, such as ARM, ARM64 etc. + +Stacked irq_chip +~~~~~~~~~~~~~~~~ + +Now, we could go one step further to support stacked (hierarchy) irq_chip. That is, an irq_chip is associated with each irq_data along the hierarchy. A child irq_chip may implement a required action by itself or by cooperating with its parent irq_chip.
@@ -280,20 +319,6 @@ with the hardware managed by itself and may ask for services from its parent irq_chip when needed. So we could achieve a much cleaner software architecture. -For an interrupt controller driver to support hierarchy irq_domain, it -needs to: - -1) Implement irq_domain_ops.alloc and irq_domain_ops.free -2) Optionally implement irq_domain_ops.activate and - irq_domain_ops.deactivate. -3) Optionally implement an irq_chip to manage the interrupt controller - hardware. -4) No need to implement irq_domain_ops.map and irq_domain_ops.unmap, - they are unused with hierarchy irq_domain. - -Hierarchy irq_domain is in no way x86 specific, and is heavily used to -support other architectures, such as ARM, ARM64 etc. - Debugging =========
include/linux/irqdomain.h +2 -24
@@ -1,30 +1,8 @@/* SPDX-License-Identifier: GPL-2.0 */ /* -* irq_domain - IRQ translation domains +* irq_domain - IRQ Translation Domains * -* Translation infrastructure between hw and linux irq numbers. This is -* helpful for interrupt controllers to implement mapping between hardware -* irq numbers and the Linux irq number space. -* -* irq_domains also have hooks for translating device tree or other -* firmware interrupt representations into a hardware irq number that -* can be mapped back to a Linux irq number without any extra platform -* support code. -* -* Interrupt controller "domain" data structure. This could be defined as a -* irq domain controller. That is, it handles the mapping between hardware -* and virtual interrupt numbers for a given interrupt domain. The domain -* structure is generally created by the PIC code for a given PIC instance -* (though a domain can cover more than one PIC if they have a flat number -* model). It's the domain callbacks that are responsible for setting the -* irq_chip on a given irq_desc after it's been mapped. -* -* The host code and data structures use a fwnode_handle pointer to -* identify the domain. In some cases, and in order to preserve source -* code compatibility, this fwnode pointer is "upgraded" to a DT -* device_node. For those firmware infrastructures that do not provide -* a unique identifier for an interrupt controller, the irq_domain -* code offers a fwnode allocator. +* See Documentation/core-api/irq/irq-domain.rst for the details. */ #ifndef _LINUX_IRQDOMAIN_H
Signature · 1 line
2.48.0
PATCH 18/18 irqdomain.c: Fix kernel-doc and add it to Documentation
In reply to Jiri Slaby (SUSE)irqdomain.c's kernel-doc exists in that file, but is not plugged into Documentation/ yet.
Before plugging it in, fix it first: irq_domain_get_irq_data() and irq_domain_set_info() were documented twice. Identically, by both definitions for CONFIG_IRQ_DOMAIN_HIERARCHY and !CONFIG_IRQ_DOMAIN_HIERARCHY. Therefore, switch the second kernel-doc into an ordinary comment -- change "/**" to simple "/*". This avoids sphinx's:
WARNING: Duplicate C declaration
Next, in commit b7b377332b96 ("irqdomain: Fix the kernel-doc and plug it into Documentation"), I added irqdomain.h's (header) kernel-doc into core-api/genericirq.rst. But given the amount of irqdomain functions and structures, move all these to core-api/irq/irq-domain.rst now.
Finally, add these newly fixed irqdomain.c's (source) docs there as well.
--- Documentation/core-api/genericirq.rst | 2 -- Documentation/core-api/irq/irq-domain.rst | 20 ++++++++++++++++++++ kernel/irq/irqdomain.c | 4 ++-- 3 files changed, 22 insertions(+), 4 deletions(-)
Documentation/core-api/genericirq.rst +0 -2
@@ -410,8 +410,6 @@ which are used in the generic IRQ layer. .. kernel-doc:: include/linux/interrupt.h :internal: -.. kernel-doc:: include/linux/irqdomain.h - Public Functions Provided =========================
Documentation/core-api/irq/irq-domain.rst +20 -0
@@ -324,3 +324,23 @@ Debugging Most of the internals of the IRQ subsystem are exposed in debugfs by turning CONFIG_GENERIC_IRQ_DEBUGFS on. + +Structures and Public Functions Provided +======================================== + +This chapter contains the autogenerated documentation of the structures +and exported kernel API functions which are used for IRQ domains. + +.. kernel-doc:: include/linux/irqdomain.h + +.. kernel-doc:: kernel/irq/irqdomain.c + :export: + +Internal Functions Provided +=========================== + +This chapter contains the autogenerated documentation of the internal +functions. + +.. kernel-doc:: kernel/irq/irqdomain.c + :internal:
kernel/irq/irqdomain.c +2 -2
@@ -1941,7 +1941,7 @@ static void irq_domain_check_hierarchy(struct irq_domain *domain) domain->flags |= IRQ_DOMAIN_FLAG_HIERARCHY; }#else /* CONFIG_IRQ_DOMAIN_HIERARCHY */ -/** +/* * irq_domain_get_irq_data - Get irq_data associated with @virq and @domain * @domain: domain to match * @virq: IRQ number to get irq_data
@@ -1955,7 +1955,7 @@ struct irq_data *irq_domain_get_irq_data(struct irq_domain *domain, }EXPORT_SYMBOL_GPL (irq_domain_get_irq_data); -/** +/* * irq_domain_set_info - Set the complete data for a @virq in @domain * @domain: Interrupt domain to match * @virq: IRQ number
Signature · 1 line
2.48.0
Re: [PATCH 09/18] irqdomain: Rename _add functions to _add_*_of_node
In reply to Jiri Slaby (SUSE)Jiri!
Quoted 15 lines · Jiri Slaby (SUSE)
For readers, it is very confusing that:
* irq_domain_add_*() functions are dedicated toof_nodes,
* irq_domain_create_*() ones to fwnodes, and
*irq_domain_instantiate()to the universal structirq_domain_info.Neither
_create, nor_adddesignate any of those nodes. Despite the naming, the functionality of them is the same: add an irq domain (by genericirq_domain_instantiate()). So the source of the confusion is the naming proper -- making the distinction based on_create,_add, and_instantiate.Therefore, here an "
_of_node" suffix is added to all "_add" functions (of_nodeones). In the next patch, "_create" (fwnode ones) are switched to "_add_fwnode". And finally, "_instantiate" is renamed to "_add".
Quoted 5 lines
So when all are applied, the interface is much easier to follow:
* dom =irq_domain_add_linear_of_node(of_node, ...)
* dom =irq_domain_add_linear_fwnode(fwnode, ...)
* dom =irq_domain_add(info)
*irq_domain_remove(dom)
I'm not convinced that this _of_node() _fwnode() churn is actually valuable. I rather go and consolidate the code so that the core functions take a fwnode argument, i.e.
- irq_domain_add_xxx(node, ...)
+ irq_domain_add_xxx(of_fwnode_handle(node), ....)
It's not asked too much from the developer to use of_fwnode_handle() at the call site and the resulting treewide churn is pretty much the same as in any case all call sites need to be touched.
But that brings me to the question of logistics for this overhaul. As this is a treewide change, there is quite some potential to create conflicts all over the place.
So the obvious solution is to consolidate on the existing irq_domain_create_*() API, which is not the worst naming once everything is unified, i.e.
- irq_domain_add_xxx(node, ...)
+ irq_domain_create_xxx(of_fwnode_handle(node), ....)
It allows to distribute these changes (except for the _nomap() oddity, which is OF only) right now to the relevant subsystems and I can collect the ignored changes in the irq tree. The final removal of the _add*() interfaces can then be done towards the end of the merge window.
Thoughts?
Thanks,
tglx
Re: [PATCH 09/18] irqdomain: Rename _add functions to _add_*_of_node
Thomas,
sorry for the delay, I drowned in tty.
Quoted 26 lines · tglx
Quoted 15 lines · Jiri Slaby (SUSE)
For readers, it is very confusing that:
* irq_domain_add_*() functions are dedicated toof_nodes,
* irq_domain_create_*() ones to fwnodes, and
*irq_domain_instantiate()to the universal structirq_domain_info.Neither
_create, nor_adddesignate any of those nodes. Despite the naming, the functionality of them is the same: add an irq domain (by genericirq_domain_instantiate()). So the source of the confusion is the naming proper -- making the distinction based on_create,_add, and_instantiate.Therefore, here an "
_of_node" suffix is added to all "_add" functions (of_nodeones). In the next patch, "_create" (fwnode ones) are switched to "_add_fwnode". And finally, "_instantiate" is renamed to "_add".Quoted 5 lines
So when all are applied, the interface is much easier to follow:
* dom =irq_domain_add_linear_of_node(of_node, ...)
* dom =irq_domain_add_linear_fwnode(fwnode, ...)
* dom =irq_domain_add(info)
*irq_domain_remove(dom)I'm not convinced that this
_of_node()_fwnode()churn is actually valuable. I rather go and consolidate the code so that the core functions take a fwnode argument, i.e.
Quoted 6 lines
-
irq_domain_add_xxx(node, ...)
+irq_domain_add_xxx(of_fwnode_handle(node), ....)It's not asked too much from the developer to use
of_fwnode_handle()at the call site and the resulting treewide churn is pretty much the same as in any case all call sites need to be touched.
OK, NP. I am only confused by your "I rather go". Does it mean you are already on it? Or should I translate that as "I'd rather go", ie. /me doing the work -- I expect this case and can indeed do the job. I just don't want to duplicate the work.
Quoted 11 lines
But that brings me to the question of logistics for this overhaul. As this is a treewide change, there is quite some potential to create conflicts all over the place.
So the obvious solution is to consolidate on the existing irq_domain_create_*() API, which is not the worst naming once everything is unified, i.e.
-
irq_domain_add_xxx(node, ...)
+irq_domain_create_xxx(of_fwnode_handle(node), ....)
Quoted 6 lines
It allows to distribute these changes (except for the
_nomap()oddity, which is OF only) right now to the relevant subsystems and I can collect the ignored changes in the irq tree. The final removal of the _add*() interfaces can then be done towards the end of the merge window.Thoughts?
Sounds good to me.
thanks,
Signature · 2 lines
js suse labs
Re: [PATCH 09/18] irqdomain: Rename _add functions to _add_*_of_node
Jiri!
Quoted 1 line · Jiri Slaby
sorry for the delay, I drowned in tty.
I'm sorry for you :)
Quoted 8 lines · tglx
Quoted 7 lines
I'm not convinced that this
_of_node()_fwnode()churn is actually valuable. I rather go and consolidate the code so that the core functions take a fwnode argument, i.e.-
irq_domain_add_xxx(node, ...)
+irq_domain_add_xxx(of_fwnode_handle(node), ....)
Quoted 8 lines
Quoted 3 lines
It's not asked too much from the developer to use
of_fwnode_handle()at the call site and the resulting treewide churn is pretty much the same as in any case all call sites need to be touched.OK, NP. I am only confused by your "I rather go". Does it mean you are already on it? Or should I translate that as "I'd rather go", ie. /me doing the work -- I expect this case and can indeed do the job. I just don't want to duplicate the work.
I meant to write "I'd" and was obviously expecting you doing this :)
Thanks,
tglx
[tip: irq/core] irqdomain: Remove extern from function declarations
In reply to Jiri Slaby (SUSE)The following commit has been merged into the irq/core branch of tip:
The following commit has been merged into the irq/core branch of tip:
Commit-ID: aa4a1d5b198314e9ef02844d0f9426efd5127f74 Gitweb: https://git.kernel.org/tip/aa4a1d5b198314e9ef02844d0f9426efd5127f74 Author: Jiri Slaby (SUSE) <[email protected]> AuthorDate: Wed, 15 Jan 2025 09:53:50 +01:00 Committer: Thomas Gleixner <[email protected]> CommitterDate: Mon, 10 Mar 2025 10:01:20 +01:00
irqdomain: Remove extern from function declarations
'extern' is not needed for function declarations. So remove it from irqdomain.h. Note that the declarations are now unified as some had 'extern' and some did not.
--- include/linux/irqdomain.h | 140 ++++++++++++++++++------------------- 1 file changed, 71 insertions(+), 69 deletions(-)
include/linux/irqdomain.h +71 -69
@@ -350,13 +350,13 @@ struct irq_domain *irq_domain_create_legacy(struct fwnode_handle *fwnode,irq_hw_number_t first_hwirq, const struct irq_domain_ops *ops, void *host_data); -extern struct irq_domain *irq_find_matching_fwspec (struct irq_fwspec *fwspec, -enum irq_domain_bus_token bus_token); -extern void irq_set_default_host (struct irq_domain *host); -extern struct irq_domain *irq_get_default_host (void ); -extern int irq_domain_alloc_descs (int virq,unsigned int nr_irqs, -irq_hw_number_t hwirq,int node, -const struct irq_affinity_desc *affinity); +struct irq_domain *irq_find_matching_fwspec (struct irq_fwspec *fwspec, +enum irq_domain_bus_token bus_token); +void irq_set_default_host (struct irq_domain *host); +struct irq_domain *irq_get_default_host (void ); +int irq_domain_alloc_descs (int virq,unsigned int nr_irqs, +irq_hw_number_t hwirq,int node, +const struct irq_affinity_desc *affinity);static inline struct fwnode_handle *of_node_to_fwnode (struct device_node *node) {
@@ -370,8 +370,8 @@ static inline bool is_fwnode_irqchip(const struct fwnode_handle *fwnode)return fwnode && fwnode->ops == &irqchip_fwnode_ops; } -extern void irq_domain_update_bus_token (struct irq_domain *domain, -enum irq_domain_bus_token bus_token); +void irq_domain_update_bus_token (struct irq_domain *domain, +enum irq_domain_bus_token bus_token);static inline struct irq_domain *irq_find_matching_fwnode(struct fwnode_handle *fwnode,
@@ -454,7 +454,7 @@ static inline struct irq_domain *irq_domain_add_nomap(struct device_node *of_nodreturn IS_ERR (d) ?NULL : d; } -extern unsigned int irq_create_direct_mapping (struct irq_domain *host); +unsigned int irq_create_direct_mapping (struct irq_domain *host);#endif static inline struct irq_domain *irq_domain_add_tree(struct device_node *of_node,
@@ -507,19 +507,19 @@ static inline struct irq_domain *irq_domain_create_tree(struct fwnode_handle *fwreturn IS_ERR (d) ?NULL : d; } -extern void irq_domain_remove (struct irq_domain *host); +void irq_domain_remove (struct irq_domain *host); -extern int irq_domain_associate (struct irq_domain *domain,unsigned int irq, -irq_hw_number_t hwirq); -extern void irq_domain_associate_many (struct irq_domain *domain, -unsigned int irq_base, -irq_hw_number_t hwirq_base,int count); +int irq_domain_associate (struct irq_domain *domain,unsigned int irq, +irq_hw_number_t hwirq); +void irq_domain_associate_many (struct irq_domain *domain, +unsigned int irq_base, +irq_hw_number_t hwirq_base,int count); -extern unsigned int irq_create_mapping_affinity (struct irq_domain *host, -irq_hw_number_t hwirq, -const struct irq_affinity_desc *affinity); -extern unsigned int irq_create_fwspec_mapping (struct irq_fwspec *fwspec); -extern void irq_dispose_mapping (unsigned int virq); +unsigned int irq_create_mapping_affinity (struct irq_domain *host, +irq_hw_number_t hwirq, +const struct irq_affinity_desc *affinity); +unsigned int irq_create_fwspec_mapping (struct irq_fwspec *fwspec); +void irq_dispose_mapping (unsigned int virq);static inline unsigned int irq_create_mapping (struct irq_domain *host,irq_hw_number_t hwirq)
@@ -527,9 +527,9 @@ static inline unsigned int irq_create_mapping(struct irq_domain *host,return irq_create_mapping_affinity (host, hwirq,NULL ); } -extern struct irq_desc *__irq_resolve_mapping (struct irq_domain *domain, -irq_hw_number_t hwirq, -unsigned int *irq); +struct irq_desc *__irq_resolve_mapping (struct irq_domain *domain, +irq_hw_number_t hwirq, +unsigned int *irq);static inline struct irq_desc *irq_resolve_mapping (struct irq_domain *domain,irq_hw_number_t hwirq)
@@ -587,19 +587,21 @@ int irq_reserve_ipi(struct irq_domain *domain, const struct cpumask *dest);int irq_destroy_ipi (unsigned int irq,const struct cpumask *dest);/* V2 interfaces to support hierarchy IRQ domains. */ -extern struct irq_data *irq_domain_get_irq_data (struct irq_domain *domain, -unsigned int virq); -extern void irq_domain_set_info (struct irq_domain *domain,unsigned int virq, -irq_hw_number_t hwirq, -const struct irq_chip *chip, -void *chip_data,irq_flow_handler_t handler, -void *handler_data,const char *handler_name); -extern void irq_domain_reset_irq_data (struct irq_data *irq_data); +struct irq_data *irq_domain_get_irq_data (struct irq_domain *domain, +unsigned int virq); +void irq_domain_set_info (struct irq_domain *domain,unsigned int virq, +irq_hw_number_t hwirq, +const struct irq_chip *chip, +void *chip_data,irq_flow_handler_t handler, +void *handler_data,const char *handler_name); +void irq_domain_reset_irq_data (struct irq_data *irq_data);#ifdef CONFIG_IRQ_DOMAIN_HIERARCHY -extern struct irq_domain *irq_domain_create_hierarchy (struct irq_domain *parent, -unsigned int flags,unsigned int size, -struct fwnode_handle *fwnode, -const struct irq_domain_ops *ops,void *host_data); +struct irq_domain *irq_domain_create_hierarchy (struct irq_domain *parent, +unsigned int flags, +unsigned int size, +struct fwnode_handle *fwnode, +const struct irq_domain_ops *ops, +void *host_data); static inline struct irq_domain *irq_domain_add_hierarchy(struct irq_domain *parent, unsigned int flags,
@@ -613,13 +615,13 @@ static inline struct irq_domain *irq_domain_add_hierarchy(struct irq_domain *par ops, host_data); } -extern int __irq_domain_alloc_irqs (struct irq_domain *domain,int irq_base, -unsigned int nr_irqs,int node,void *arg, -bool realloc, -const struct irq_affinity_desc *affinity); -extern void irq_domain_free_irqs (unsigned int virq,unsigned int nr_irqs); -extern int irq_domain_activate_irq (struct irq_data *irq_data,bool early); -extern void irq_domain_deactivate_irq (struct irq_data *irq_data); +int __irq_domain_alloc_irqs (struct irq_domain *domain,int irq_base, +unsigned int nr_irqs,int node,void *arg, +bool realloc, +const struct irq_affinity_desc *affinity); +void irq_domain_free_irqs (unsigned int virq,unsigned int nr_irqs); +int irq_domain_activate_irq (struct irq_data *irq_data,bool early); +void irq_domain_deactivate_irq (struct irq_data *irq_data);static inline int irq_domain_alloc_irqs (struct irq_domain *domain,unsigned int nr_irqs,int node,void *arg)
@@ -628,32 +630,32 @@ static inline int irq_domain_alloc_irqs(struct irq_domain *domain, NULL); } -extern int irq_domain_alloc_irqs_hierarchy (struct irq_domain *domain, -unsigned int irq_base, -unsigned int nr_irqs,void *arg); -extern int irq_domain_set_hwirq_and_chip (struct irq_domain *domain, -unsigned int virq, -irq_hw_number_t hwirq, -const struct irq_chip *chip, -void *chip_data); -extern void irq_domain_free_irqs_common (struct irq_domain *domain, -unsigned int virq, -unsigned int nr_irqs); -extern void irq_domain_free_irqs_top (struct irq_domain *domain, -unsigned int virq,unsigned int nr_irqs); - -extern int irq_domain_push_irq (struct irq_domain *domain,int virq,void *arg); -extern int irq_domain_pop_irq (struct irq_domain *domain,int virq); - -extern int irq_domain_alloc_irqs_parent (struct irq_domain *domain, -unsigned int irq_base, -unsigned int nr_irqs,void *arg); - -extern void irq_domain_free_irqs_parent (struct irq_domain *domain, -unsigned int irq_base, -unsigned int nr_irqs); - -extern int irq_domain_disconnect_hierarchy (struct irq_domain *domain, +int irq_domain_alloc_irqs_hierarchy (struct irq_domain *domain, +unsigned int irq_base, +unsigned int nr_irqs,void *arg); +int irq_domain_set_hwirq_and_chip (struct irq_domain *domain, +unsigned int virq, +irq_hw_number_t hwirq, +const struct irq_chip *chip, +void *chip_data); +void irq_domain_free_irqs_common (struct irq_domain *domain, +unsigned int virq, +unsigned int nr_irqs); +void irq_domain_free_irqs_top (struct irq_domain *domain, +unsigned int virq,unsigned int nr_irqs); + +int irq_domain_push_irq (struct irq_domain *domain,int virq,void *arg); +int irq_domain_pop_irq (struct irq_domain *domain,int virq); + +int irq_domain_alloc_irqs_parent (struct irq_domain *domain, +unsigned int irq_base, +unsigned int nr_irqs,void *arg); + +void irq_domain_free_irqs_parent (struct irq_domain *domain, +unsigned int irq_base, +unsigned int nr_irqs); + +int irq_domain_disconnect_hierarchy (struct irq_domain *domain,unsigned int virq);static inline bool irq_domain_is_hierarchy (struct irq_domain *domain)