[Skiboot] [PATCH] interrupts: Declare xive2 DT node as an interrupt-controller

Frederic Barrat fbarrat at linux.ibm.com
Wed Oct 20 21:28:26 AEDT 2021


This patch fixes errors seen when linux looks for the interrupt to use
for a device LSI:

     pci X:Y:Z of_irq_parse_pci: failed with rc=-22

The of/irq parsing code requires those new properties to be able to
map the interrupt specifier correctly. It was not needed before
comitting cd12ea6d8e1 ("interrupts: Do not advertise XICS support on
P10"), because the LSI mapping code was defaulting to the XICS
interrupt controller node, which is now removed (and had those
properties).

Fixes: cd12ea6d8e1 ("interrupts: Do not advertise XICS support on P10")
Signed-off-by: Frederic Barrat <fbarrat at linux.ibm.com>
---
 hw/xive2.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/hw/xive2.c b/hw/xive2.c
index 0254175a..30293cdf 100644
--- a/hw/xive2.c
+++ b/hw/xive2.c
@@ -1955,7 +1955,12 @@ static void xive_create_mmio_dt_node(struct xive *x)
 			     tb + 3 * stride, stride);
 
 	dt_add_property_strings(xive_dt_node, "compatible",
-				"ibm,opal-xive-pe", "ibm,opal-intc");
+				"ibm,opal-xive-pe", "ibm,opal-xive-vc",
+				"ibm,opal-intc");
+
+	dt_add_property(xive_dt_node, "interrupt-controller", NULL, 0);
+	dt_add_property_cells(xive_dt_node, "#address-cells", 0);
+	dt_add_property_cells(xive_dt_node, "#interrupt-cells", 2);
 
 	dt_add_property_cells(xive_dt_node, "ibm,xive-eq-sizes",
 			      12, 16, 21, 24);
-- 
2.31.1



More information about the Skiboot mailing list