[PATCH 23/23] MAINTAINERS: Add the Microchip LAN966x OIC driver entry

2024-06-14 Thread Herve Codina
After contributing the driver, add myself as the maintainer for the Microchip LAN966x OIC driver. Signed-off-by: Herve Codina --- MAINTAINERS | 6 ++ 1 file changed, 6 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index d6c90161c7bf..baeb307344cd 100644 --- a/MAINTAINERS +++ b

[PATCH 19/23] um: virt-pci: Use irq_domain_instantiate()

2024-06-14 Thread Herve Codina
um_pci_init() uses __irq_domain_add(). With the introduction of irq_domain_instantiate(), __irq_domain_add() becomes obsolete. In order to fully remove __irq_domain_add(), use directly irq_domain_instantiate(). Signed-off-by: Herve Codina --- arch/um/drivers/virt-pci.c | 16 ++-- 1

[PATCH 20/23] irqdomain: Remove __irq_domain_add()

2024-06-14 Thread Herve Codina
__irq_domain_add() has been replaced by irq_domain_instanciate() and so, it is no more used. Simply remove it. Signed-off-by: Herve Codina --- include/linux/irqdomain.h | 6 +- kernel/irq/irqdomain.c| 33 - 2 files changed, 1 insertion(+), 38 deletions

[PATCH 22/23] irqchip: Add support for LAN966x OIC

2024-06-14 Thread Herve Codina
The Microchip LAN966x outband interrupt controller (OIC) maps the internal interrupt sources of the LAN966x device to an external interrupt. When the LAN966x device is used as a PCI device, the external interrupt is routed to the PCI interrupt. Signed-off-by: Herve Codina --- drivers/irqchip

[PATCH 21/23] dt-bindings: interrupt-controller: Add support for Microchip LAN966x OIC

2024-06-14 Thread Herve Codina
The Microchip LAN966x outband interrupt controller (OIC) maps the internal interrupt sources of the LAN966x device to an external interrupt. When the LAN966x device is used as a PCI device, the external interrupt is routed to the PCI interrupt. Signed-off-by: Herve Codina Reviewed-by: Rob

[PATCH 18/23] irqdomain: Convert domain creation functions to irq_domain_instantiate()

2024-06-14 Thread Herve Codina
Domain creation functions use __irq_domain_add(). With the introduction of irq_domain_instantiate(), __irq_domain_add() becomes obsolete. In order to fully remove __irq_domain_add(), convert domain creation function to irq_domain_instantiate() Signed-off-by: Herve Codina --- kernel/irq

[PATCH 15/23] irqdomain: Add support for generic irq chips creation before publishing a domain

2024-06-14 Thread Herve Codina
, handle the generic chip creation (i.e the irq_domain_alloc_generic_chips() call) before the domain is published. Suggested-by: Thomas Gleixner Signed-off-by: Herve Codina --- include/linux/irqdomain.h | 9 + kernel/irq/irqdomain.c| 14 +- 2 files changed, 22 insertions

[PATCH 17/23] irqdomain: Convert __irq_domain_add() wrappers to irq_domain_instantiate()

2024-06-14 Thread Herve Codina
__irq_domain_add() wrappers use directly __irq_domain_add(). With the introduction of irq_domain_instantiate(), __irq_domain_add() becomes obsolete. In order to fully remove __irq_domain_add(), convert wrappers to irq_domain_instantiate() Signed-off-by: Herve Codina --- include/linux

[PATCH 16/23] irqdomain: Add a resource managed version of irq_domain_instantiate()

2024-06-14 Thread Herve Codina
Add a devres version of irq_domain_instantiate(). Signed-off-by: Herve Codina --- include/linux/irqdomain.h | 2 ++ kernel/irq/devres.c | 41 +++ 2 files changed, 43 insertions(+) diff --git a/include/linux/irqdomain.h b/include/linux/irqdomain.h

[PATCH 14/23] genirq/generic_chip: Introduce init() and exit() hooks

2024-06-14 Thread Herve Codina
. Introduce the init() hook to perform these initializations at the right place just after the generic chip creation. Also introduce the exit() hook to allow reververting operations done by the init() hook just before the generic chip is destroyed. Suggested-by: Thomas Gleixner Signed-off-by: Herve

[PATCH 12/23] irqdomain: Introduce init() and exit() hooks

2024-06-14 Thread Herve Codina
plublishing the domain. Also introduce the exit() hook to revert operations done in init() on domain removal. Suggested-by: Thomas Gleixner Signed-off-by: Herve Codina --- include/linux/irqdomain.h | 8 kernel/irq/irqdomain.c| 15 +++ 2 files changed, 23 insertions(+) diff

[PATCH 13/23] genirq/generic_chip: Introduce irq_domain_{alloc,remove}_generic_chips()

2024-06-14 Thread Herve Codina
irq_domain_alloc_generic_chips(). Suggested-by: Thomas Gleixner Signed-off-by: Herve Codina --- include/linux/irq.h | 25 +++ kernel/irq/generic-chip.c | 91 +-- 2 files changed, 93 insertions(+), 23 deletions(-) diff --git a/include/linux/irq.h b

[PATCH 11/23] irqdomain: Handle domain bus token in irq_domain_create()

2024-06-14 Thread Herve Codina
/redo sequence, take into account the domain bus token during the domain creation. Suggested-by: Thomas Gleixner Signed-off-by: Herve Codina --- include/linux/irqdomain.h | 2 ++ kernel/irq/irqdomain.c| 30 -- 2 files changed, 26 insertions(+), 6 deletions(-) diff

[PATCH 08/23] irqdomain: Handle domain hierarchy parent in irq_domain_instantiate()

2024-06-14 Thread Herve Codina
To use irq_domain_instantiate() from irq_domain_create_hierarchy(), irq_domain_instantiate() needs to handle the domain hierarchy parent. Handle this parent. Signed-off-by: Herve Codina --- include/linux/irqdomain.h | 6 ++ kernel/irq/irqdomain.c| 7 +++ 2 files changed, 13

[PATCH 10/23] irqdomain: Make __irq_domain_create() return an error code

2024-06-14 Thread Herve Codina
code. Rather than using this arbitrary error value, make __irq_domain_create() return is own error code and use that one. Signed-off-by: Herve Codina --- kernel/irq/irqdomain.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/kernel/irq/irqdomain.c b/kernel/irq

[PATCH 09/23] irqdomain: Use irq_domain_instantiate() for hierarchy domain creation

2024-06-14 Thread Herve Codina
irq_domain_instantiate() handles all needs to be used in irq_domain_create_hierarchy() Avoid code duplication and use directly irq_domain_instantiate() for hierarchy domain creation. Signed-off-by: Herve Codina --- kernel/irq/irqdomain.c | 17 + 1 file changed, 5 insertions

[PATCH 07/23] irqdomain: Handle additional domain flags in irq_domain_instantiate()

2024-06-14 Thread Herve Codina
In order to use irq_domain_instantiate() from several places such as irq_domain_create_hierarchy(), irq_domain_instantiate() needs to handle additional domain flags. Handle these additional flags. Suggested-by: Thomas Gleixner Signed-off-by: Herve Codina --- include/linux/irqdomain.h | 2

[PATCH 00/23] Introduce irq_domain_instanciate()

2024-06-14 Thread Herve Codina
sacco...@gmail.com/ Best regards, Hervé Herve Codina (23): irqdomain: Introduce irq_domain_free() irqdomain: Introduce irq_domain_instantiate() irqdomain: Fixed unbalanced fwnode get and put irqdomain: Constify parameter in is_fwnode_irqchip() irqdomain: Use a dedicated function to set the d

[PATCH 06/23] irqdomain: Convert __irq_domain_create() to use struct irq_domain_info

2024-06-14 Thread Herve Codina
in a simple way without the need to change the __irq_domain_create() prototype. Convert __irq_domain_create() to use the information structure. Suggested-by: Thomas Gleixner Signed-off-by: Herve Codina --- kernel/irq/irqdomain.c | 48 +- 1 file changed

[PATCH 05/23] irqdomain: Use a dedicated function to set the domain name

2024-06-14 Thread Herve Codina
. Signed-off-by: Herve Codina --- kernel/irq/irqdomain.c | 69 +++--- 1 file changed, 38 insertions(+), 31 deletions(-) diff --git a/kernel/irq/irqdomain.c b/kernel/irq/irqdomain.c index 31277488ed42..0b152061e63a 100644 --- a/kernel/irq/irqdomain.c +++ b/kernel

[PATCH 04/23] irqdomain: Constify parameter in is_fwnode_irqchip()

2024-06-14 Thread Herve Codina
the fwnode parameter. Signed-off-by: Herve Codina --- include/linux/irqdomain.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/irqdomain.h b/include/linux/irqdomain.h index ab8939c8724d..a3b43e357009 100644 --- a/include/linux/irqdomain.h +++ b/include/linux

[PATCH 03/23] irqdomain: Fixed unbalanced fwnode get and put

2024-06-14 Thread Herve Codina
t will never be put. To avoid the unbalanced get and put, set domain->fwnode unconditionally. Fixes: d59f6617eef0 ("genirq: Allow fwnode to carry name information only") Cc: sta...@vger.kernel.org Signed-off-by: Herve Codina --- kernel/irq/irqdomain.c | 7 ++- 1 file changed,

[PATCH 01/23] irqdomain: Introduce irq_domain_free()

2024-06-14 Thread Herve Codina
: Thomas Gleixner Signed-off-by: Herve Codina --- kernel/irq/irqdomain.c | 16 ++-- 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/kernel/irq/irqdomain.c b/kernel/irq/irqdomain.c index 86f8b91b0d3a..95eda206367f 100644 --- a/kernel/irq/irqdomain.c +++ b/kernel/irq

[PATCH 02/23] irqdomain: Introduce irq_domain_instantiate()

2024-06-14 Thread Herve Codina
operation as the one done by __irq_domain_add(). For compatibility reason with existing code, keep __irq_domain_add() but convert it to irq_domain_instantiate(). Suggested-by: Thomas Gleixner Signed-off-by: Herve Codina --- include/linux/irqdomain.h | 21 + kernel/irq

Re: [PATCH v4 5/7] arm64: Unconditionally call unflatten_device_tree()

2024-03-07 Thread Herve Codina
solution. The > scope of what's possible is contained enough to avoid issues. > I tested on a x86 system. My use case is 'SoCs which expose their peripherals via a PCI endpoint' described by Rob. Indeed, I have a Microchip Lan9662 board (the one mentioned by Rob in his P