Thread (44 messages) 44 messages, 10 authors, 2026-03-31
STALE80d
Revisions (3)
  1. v8 current
  2. v1 [diff vs current]
  3. v9 [diff vs current]

[PATCH v8 07/10] pinctrl: s32cc: skip syscon child nodes when parsing funcs and groups

From: Khristine Andreea Barbulescu <hidden>
Date: 2026-01-20 11:59:51
Also in: imx, linux-devicetree, linux-gpio, lkml
Subsystem: arm/nxp s32g architecture, pin control subsystem, pin controller - freescale, the rest · Maintainers: Linus Walleij, Dong Aisheng, Fabio Estevam, Frank Li, Jacky Bai, Linus Torvalds

The SIUL2 node contains child nodes for syscon
instances (SIUL2_0 and SIUL2_1) to expose register
ranges for SoC information. These nodes are not
part of the pinctrl configuration and should not
be treated as pinctrl functions or groups.

Signed-off-by: Khristine Andreea Barbulescu <redacted>
---
 drivers/pinctrl/nxp/pinctrl-s32cc.c | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/drivers/pinctrl/nxp/pinctrl-s32cc.c b/drivers/pinctrl/nxp/pinctrl-s32cc.c
index cdd3a1cd4fe5..50d5a01107eb 100644
--- a/drivers/pinctrl/nxp/pinctrl-s32cc.c
+++ b/drivers/pinctrl/nxp/pinctrl-s32cc.c
@@ -2,7 +2,7 @@
 /*
  * Core driver for the S32 CC (Common Chassis) pin controller
  *
- * Copyright 2017-2022,2024-2025 NXP
+ * Copyright 2017-2022,2024-2025-2026 NXP
  * Copyright (C) 2022 SUSE LLC
  * Copyright 2015-2016 Freescale Semiconductor, Inc.
  */
@@ -832,6 +832,9 @@ static int s32_pinctrl_parse_functions(struct device_node *np,
 
 	dev_dbg(info->dev, "parse function(%u): %pOFn\n", index, np);
 
+	if (of_device_is_compatible(np, "syscon"))
+		return 0;
+
 	func = &info->functions[index];
 
 	/* Initialise function */
@@ -941,7 +944,8 @@ static int s32_pinctrl_probe_dt(struct platform_device *pdev,
 		return -ENODEV;
 
 	for_each_child_of_node_scoped(np, child)
-		++nfuncs;
+		if (!of_device_is_compatible(child, "syscon"))
+			++nfuncs;
 	if (nfuncs <= 0)
 		return dev_err_probe(&pdev->dev, -EINVAL,
 				     "No functions defined\n");
@@ -962,6 +966,9 @@ static int s32_pinctrl_probe_dt(struct platform_device *pdev,
 		return -ENOMEM;
 
 	for_each_child_of_node_scoped(np, child) {
+		if (of_device_is_compatible(child, "syscon"))
+			continue;
+
 		ret = s32_pinctrl_parse_functions(child, info, i++);
 		if (ret)
 			return ret;
-- 
2.50.1

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help