pinctrl: eswin: Fix Handling of PIN_CONFIG_PERSIST_STATE

The EIC7700 pinctrl driver does not handle PIN_CONFIG_PERSIST_STATE
specifically, and returns -EOPNOTSUPP from the default case.

Since all pins on the EIC7700 SoC are persistent over suspend, the
correct behaviour is to accept this parameter and return success.

Add an explicit case for PIN_CONFIG_PERSIST_STATE that returns 0 to
prevent errors when this parameter is set.

Signed-off-by: Yulin Lu <luyulin@eswincomputing.com>
Fixes: 5b797bcc00 ("pinctrl: eswin: Add EIC7700 pinctrl driver")
Signed-off-by: Linus Walleij <linusw@kernel.org>
This commit is contained in:
Yulin Lu 2026-07-28 15:29:06 +08:00 committed by Linus Walleij
parent 04b3818c3b
commit f9af1329b9

View File

@ -423,6 +423,9 @@ static int eic7700_pin_config_set(struct pinctrl_dev *pctldev, unsigned int pin,
else
value &= ~EIC7700_ST;
break;
/* All pins are persistent over suspend */
case PIN_CONFIG_PERSIST_STATE:
return 0;
default:
return -EOPNOTSUPP;
}