Skip to content

Commit 8f8fe52

Browse files
Bartosz GolaszewskiLinus Walleij
authored andcommitted
pinctrl: mediatek: moore: use pinmux_generic_add_pinfunction()
Instead of passing individual fields of struct pinfunction to pinmux_generic_add_function(), use pinmux_generic_add_pinfunction() and pass the entire structure directly. Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> Link: https://lore.kernel.org/20250709-pinctrl-gpio-pinfuncs-v2-5-b6135149c0d9@linaro.org Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
1 parent 7d7883d commit 8f8fe52

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

drivers/pinctrl/mediatek/pinctrl-moore.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -625,9 +625,8 @@ static int mtk_build_functions(struct mtk_pinctrl *hw)
625625
const struct function_desc *function = hw->soc->funcs + i;
626626
const struct pinfunction *func = &function->func;
627627

628-
err = pinmux_generic_add_function(hw->pctrl, func->name,
629-
func->groups, func->ngroups,
630-
function->data);
628+
err = pinmux_generic_add_pinfunction(hw->pctrl, func,
629+
function->data);
631630
if (err < 0) {
632631
dev_err(hw->dev, "Failed to register function %s\n",
633632
func->name);

0 commit comments

Comments
 (0)