aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pinctrl
diff options
context:
space:
mode:
authorBartosz Golaszewski <bartosz.golaszewski@linaro.org>2025-09-02 13:59:14 +0200
committerLinus Walleij <linus.walleij@linaro.org>2025-09-08 14:21:50 +0200
commit7a24f1f5b2147f99d2ffa40dfe137c040cab1fb8 (patch)
tree9574cfe39a773ea2602cd14be761bf88f84b4790 /drivers/pinctrl
parentpinctrl: airoha: replace struct function_desc with struct pinfunction (diff)
downloadlinux-7a24f1f5b2147f99d2ffa40dfe137c040cab1fb8.tar.gz
linux-7a24f1f5b2147f99d2ffa40dfe137c040cab1fb8.zip
pinctrl: mediatek: mt7988: use PINCTRL_PIN_FUNCTION()
We have a dedicated initializer macro for defining pin functions for mediatek drivers so use it here. Reviewed-by: Chen-Yu Tsai <wenst@chromium.org> Reviewed-by: Andy Shevchenko <andy@kernel.org> Tested-by: Neil Armstrong <neil.armstrong@linaro.org> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl')
-rw-r--r--drivers/pinctrl/mediatek/pinctrl-mt7988.c42
1 files changed, 16 insertions, 26 deletions
diff --git a/drivers/pinctrl/mediatek/pinctrl-mt7988.c b/drivers/pinctrl/mediatek/pinctrl-mt7988.c
index 68b4097792b8..55c8674d8d66 100644
--- a/drivers/pinctrl/mediatek/pinctrl-mt7988.c
+++ b/drivers/pinctrl/mediatek/pinctrl-mt7988.c
@@ -1465,32 +1465,22 @@ static const char * const mt7988_usb_groups[] = {
};
static const struct function_desc mt7988_functions[] = {
- { { "audio", mt7988_audio_groups, ARRAY_SIZE(mt7988_audio_groups) },
- NULL },
- { { "jtag", mt7988_jtag_groups, ARRAY_SIZE(mt7988_jtag_groups) },
- NULL },
- { { "int_usxgmii", mt7988_int_usxgmii_groups,
- ARRAY_SIZE(mt7988_int_usxgmii_groups) },
- NULL },
- { { "pwm", mt7988_pwm_groups, ARRAY_SIZE(mt7988_pwm_groups) }, NULL },
- { { "dfd", mt7988_dfd_groups, ARRAY_SIZE(mt7988_dfd_groups) }, NULL },
- { { "i2c", mt7988_i2c_groups, ARRAY_SIZE(mt7988_i2c_groups) }, NULL },
- { { "eth", mt7988_ethernet_groups, ARRAY_SIZE(mt7988_ethernet_groups) },
- NULL },
- { { "pcie", mt7988_pcie_groups, ARRAY_SIZE(mt7988_pcie_groups) },
- NULL },
- { { "pmic", mt7988_pmic_groups, ARRAY_SIZE(mt7988_pmic_groups) },
- NULL },
- { { "watchdog", mt7988_wdt_groups, ARRAY_SIZE(mt7988_wdt_groups) },
- NULL },
- { { "spi", mt7988_spi_groups, ARRAY_SIZE(mt7988_spi_groups) }, NULL },
- { { "flash", mt7988_flash_groups, ARRAY_SIZE(mt7988_flash_groups) },
- NULL },
- { { "uart", mt7988_uart_groups, ARRAY_SIZE(mt7988_uart_groups) },
- NULL },
- { { "udi", mt7988_udi_groups, ARRAY_SIZE(mt7988_udi_groups) }, NULL },
- { { "usb", mt7988_usb_groups, ARRAY_SIZE(mt7988_usb_groups) }, NULL },
- { { "led", mt7988_led_groups, ARRAY_SIZE(mt7988_led_groups) }, NULL },
+ PINCTRL_PIN_FUNCTION("audio", mt7988_audio),
+ PINCTRL_PIN_FUNCTION("jtag", mt7988_jtag),
+ PINCTRL_PIN_FUNCTION("int_usxgmii", mt7988_int_usxgmii),
+ PINCTRL_PIN_FUNCTION("pwm", mt7988_pwm),
+ PINCTRL_PIN_FUNCTION("dfd", mt7988_dfd),
+ PINCTRL_PIN_FUNCTION("i2c", mt7988_i2c),
+ PINCTRL_PIN_FUNCTION("eth", mt7988_ethernet),
+ PINCTRL_PIN_FUNCTION("pcie", mt7988_pcie),
+ PINCTRL_PIN_FUNCTION("pmic", mt7988_pmic),
+ PINCTRL_PIN_FUNCTION("watchdog", mt7988_wdt),
+ PINCTRL_PIN_FUNCTION("spi", mt7988_spi),
+ PINCTRL_PIN_FUNCTION("flash", mt7988_flash),
+ PINCTRL_PIN_FUNCTION("uart", mt7988_uart),
+ PINCTRL_PIN_FUNCTION("udi", mt7988_udi),
+ PINCTRL_PIN_FUNCTION("usb", mt7988_usb),
+ PINCTRL_PIN_FUNCTION("led", mt7988_led),
};
static const struct mtk_eint_hw mt7988_eint_hw = {