From: Bhargav Joshi <j.bhargav.u@gmail.com>
To: Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Thomas Gleixner <tglx@kernel.org>,
Sricharan R <r.sricharan@ti.com>,
Aaro Koskinen <aaro.koskinen@iki.fi>,
Andreas Kemnade <andreas@kemnade.info>,
Kevin Hilman <khilman@baylibre.com>,
Roger Quadros <rogerq@kernel.org>,
Tony Lindgren <tony@atomide.com>
Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-omap@vger.kernel.org, goledhruva@gmail.com,
m-chawdhry@ti.com, daniel.baluta@gmail.com,
simona.toaca@nxp.com, j.bhargav.u@gmail.com
Subject: [PATCH 2/3] irqchip: irq-crossbar: Handle renamed irqs-reserved property
Date: Sat, 06 Jun 2026 02:26:11 +0530 [thread overview]
Message-ID: <20260606-crossbar-v1-2-f67f7cb9ee50@gmail.com> (raw)
In-Reply-To: <20260606-crossbar-v1-0-f67f7cb9ee50@gmail.com>
The DT binding for the TI IRQ Crossbar has been converted from text to
YAML schema. As part of that conversion, 'ti,irqs-reserved' was renamed
to 'ti,crossbar-irqs-reserved' to avoid a property name collision with
ti,pruss-intc.yaml
Update the driver to try the new property name first and fall back to
the old name ensuring compatibility with older device trees.
Signed-off-by: Bhargav Joshi <j.bhargav.u@gmail.com>
---
drivers/irqchip/irq-crossbar.c | 15 ++++++++++++---
1 file changed, 12 insertions(+), 3 deletions(-)
diff --git a/drivers/irqchip/irq-crossbar.c b/drivers/irqchip/irq-crossbar.c
index cd1134101ace..64b042ce11a9 100644
--- a/drivers/irqchip/irq-crossbar.c
+++ b/drivers/irqchip/irq-crossbar.c
@@ -5,6 +5,7 @@
* Copyright (C) 2013 Texas Instruments Incorporated - http://www.ti.com
* Author: Sricharan R <r.sricharan@ti.com>
*/
+#include "linux/of.h"
#include <linux/err.h>
#include <linux/io.h>
#include <linux/irqchip.h>
@@ -197,6 +198,7 @@ static int __init crossbar_of_init(struct device_node *node)
u32 max = 0, entry, reg_size;
int i, size, reserved = 0;
const __be32 *irqsr;
+ const char *pname;
int ret = -ENOMEM;
cb = kzalloc_obj(*cb);
@@ -231,14 +233,21 @@ static int __init crossbar_of_init(struct device_node *node)
for (i = 0; i < max; i++)
cb->irq_map[i] = IRQ_FREE;
- /* Get and mark reserved irqs */
- irqsr = of_get_property(node, "ti,irqs-reserved", &size);
+ /*
+ * Get and mark reserved irqs
+ * try new property name first, fall back to old name for compatibility
+ * on older device trees.
+ */
+ pname = of_property_present(node, "ti,crossbar-irqs-reserved") ?
+ "ti,crossbar-irqs-reserved" : "ti,irqs-reserved";
+
+ irqsr = of_get_property(node, pname, &size);
if (irqsr) {
size /= sizeof(__be32);
for (i = 0; i < size; i++) {
of_property_read_u32_index(node,
- "ti,irqs-reserved",
+ pname,
i, &entry);
if (entry >= max) {
pr_err("Invalid reserved entry\n");
--
2.54.0
next prev parent reply other threads:[~2026-06-05 20:56 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-05 20:56 [PATCH 0/3] Convert ti,irq-crossbar binding to DT schema Bhargav Joshi
2026-06-05 20:56 ` [PATCH 1/3] dt-bindings: interrupt-controller: ti,irq-crossbar: Convert " Bhargav Joshi
2026-06-10 19:56 ` Rob Herring
2026-06-10 21:12 ` Bhargav Joshi
2026-06-10 23:01 ` Rob Herring
2026-06-11 7:39 ` Bhargav Joshi
2026-06-05 20:56 ` Bhargav Joshi [this message]
2026-06-05 20:56 ` [PATCH 3/3] ARM: dts: omap: dra7: Use new property name ti,crossbar-irqs-reserved Bhargav Joshi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260606-crossbar-v1-2-f67f7cb9ee50@gmail.com \
--to=j.bhargav.u@gmail.com \
--cc=aaro.koskinen@iki.fi \
--cc=andreas@kemnade.info \
--cc=conor+dt@kernel.org \
--cc=daniel.baluta@gmail.com \
--cc=devicetree@vger.kernel.org \
--cc=goledhruva@gmail.com \
--cc=khilman@baylibre.com \
--cc=krzk+dt@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=m-chawdhry@ti.com \
--cc=r.sricharan@ti.com \
--cc=robh@kernel.org \
--cc=rogerq@kernel.org \
--cc=simona.toaca@nxp.com \
--cc=tglx@kernel.org \
--cc=tony@atomide.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®