]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
pinctrl: spacemit: return -ENOTSUPP for unsupported pin configurations
authorJunhui Liu <junhui.liu@pigmoral.tech>
Thu, 12 Mar 2026 08:42:42 +0000 (16:42 +0800)
committerLinus Walleij <linusw@kernel.org>
Thu, 19 Mar 2026 12:52:56 +0000 (13:52 +0100)
commitc3b0c06b73974d75c640a4ebc8678f8538654e5a
tree01853be4bfa36b7e452db4b0636fc5a6b8ea15a0
parent9ba4ef6847ba53dea92efce47c9e044fbf6d6dcf
pinctrl: spacemit: return -ENOTSUPP for unsupported pin configurations

Return -ENOTSUPP instead of -EINVAL when encountering unsupported pin
configuration parameters. This is more logical and allows the GPIO
subsystem to gracefully handle unsupported parameters via functions like
gpio_set_config_with_argument_optional(), which specifically ignores
-ENOTSUPP but treats others as failure.

Signed-off-by: Junhui Liu <junhui.liu@pigmoral.tech>
Reviewed-by: Anand Moon <linux.amoon@gmail.com>
Reviewed-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
Reviewed-by: Yixun Lan <dlan@kernel.org>
Signed-off-by: Linus Walleij <linusw@kernel.org>
drivers/pinctrl/spacemit/pinctrl-k1.c