pinctrl: pinctrl-generic-mux: use mux_state_try_select()

Use mux_state_try_select() instead of mux_state_select() so that the
consumer driver does not block during probe when the mux state has
already been selected.

mux_state_try_select() returns -EBUSY if the requested state is already
selected, allowing the driver to handle the condition without waiting.

Signed-off-by: Frank Li <Frank.Li@nxp.com>
Signed-off-by: Linus Walleij <linusw@kernel.org>
This commit is contained in:
Frank Li 2026-07-15 15:35:45 -04:00 committed by Linus Walleij
parent 602ee6c944
commit 15532f9cbb

View File

@ -93,7 +93,7 @@ static int mux_pinmux_set_mux(struct pinctrl_dev *pctldev,
function = pinmux_generic_get_function(pctldev, func_selector);
func = function->data;
ret = mux_state_select(func->mux_state);
ret = mux_state_try_select(func->mux_state);
if (ret)
return ret;