Files
openwrt/target/linux/airoha/patches-6.12/112-v6.19-pinctrl-airoha-fix-pinctrl-function-mismatch-issue.patch
T
Chukun Pan 69f0ee5baf airoha: backport and fix pinctrl driver
Backport changes to the pinctrl driver to bring it closer to
the upstream version. Also fix the bug in the pinctrl driver:

pinctrl-airoha ...pinctrl: invalid function mdio in map table

Fixes: bd7f5b3 ("airoha: replace AN7583 pinctrl patch with upstream version")
Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
Link: https://github.com/openwrt/openwrt/pull/20770
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-11-20 23:00:13 +01:00

39 lines
1.4 KiB
Diff

From f2bd5a0f59d052d16749bccf637690e51947a5d6 Mon Sep 17 00:00:00 2001
From: Chukun Pan <amadeus@jmu.edu.cn>
Date: Sat, 15 Nov 2025 18:00:00 +0800
Subject: [PATCH] pinctrl: airoha: fix pinctrl function mismatch issue
The blamed commit made the following changes:
-#define PINCTRL_FUNC_DESC(id)...
- .desc = PINCTRL_PINFUNCTION(#id, ...
+#define PINCTRL_FUNC_DESC(id, table)...
+ .desc = PINCTRL_PINFUNCTION(#id, ...
- PINCTRL_FUNC_DESC(pon)...
+ PINCTRL_FUNC_DESC("pon", pon)...
It's clear that the id of funcs doesn't match the definition.
Remove redundant #string from the definition to fix this issue:
pinctrl-airoha ...: invalid function mdio in map table
Fixes: 4043b0c45f85 ("pinctrl: airoha: generalize pins/group/function/confs handling")
Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
Acked-by: Christian Marangi <ansuelsmth@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
drivers/pinctrl/mediatek/pinctrl-airoha.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/drivers/pinctrl/mediatek/pinctrl-airoha.c
+++ b/drivers/pinctrl/mediatek/pinctrl-airoha.c
@@ -35,7 +35,7 @@
#define PINCTRL_FUNC_DESC(id, table) \
{ \
- .desc = PINCTRL_PINFUNCTION(#id, table##_groups, \
+ .desc = PINCTRL_PINFUNCTION(id, table##_groups, \
ARRAY_SIZE(table##_groups)),\
.groups = table##_func_group, \
.group_size = ARRAY_SIZE(table##_func_group), \