Skip to content

Commit 437b883

Browse files
LorenzoBianconigregkh
authored andcommitted
pinctrl: airoha: Fix return value in pinconf callbacks
[ Upstream commit 563fcd6 ] Pinctrl stack requires ENOTSUPP error code if the parameter is not supported by the pinctrl driver. Fix the returned error code in pinconf callbacks if the operation is not supported. Fixes: 1c8ace2 ("pinctrl: airoha: Add support for EN7581 SoC") Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org> Link: https://lore.kernel.org/20250822-airoha-pinconf-err-val-fix-v1-1-87b4f264ced2@kernel.org Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent 5489985 commit 437b883

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

drivers/pinctrl/mediatek/pinctrl-airoha.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2696,7 +2696,7 @@ static int airoha_pinconf_get(struct pinctrl_dev *pctrl_dev,
26962696
arg = 1;
26972697
break;
26982698
default:
2699-
return -EOPNOTSUPP;
2699+
return -ENOTSUPP;
27002700
}
27012701

27022702
*config = pinconf_to_config_packed(param, arg);
@@ -2788,7 +2788,7 @@ static int airoha_pinconf_set(struct pinctrl_dev *pctrl_dev,
27882788
break;
27892789
}
27902790
default:
2791-
return -EOPNOTSUPP;
2791+
return -ENOTSUPP;
27922792
}
27932793
}
27942794

@@ -2805,10 +2805,10 @@ static int airoha_pinconf_group_get(struct pinctrl_dev *pctrl_dev,
28052805
if (airoha_pinconf_get(pctrl_dev,
28062806
airoha_pinctrl_groups[group].pins[i],
28072807
config))
2808-
return -EOPNOTSUPP;
2808+
return -ENOTSUPP;
28092809

28102810
if (i && cur_config != *config)
2811-
return -EOPNOTSUPP;
2811+
return -ENOTSUPP;
28122812

28132813
cur_config = *config;
28142814
}

0 commit comments

Comments
 (0)