162306a36Sopenharmony_ci// SPDX-License-Identifier: GPL-2.0
262306a36Sopenharmony_ci/*
362306a36Sopenharmony_ci * Copyright 2021 NXP
462306a36Sopenharmony_ci */
562306a36Sopenharmony_ci
662306a36Sopenharmony_ci#include <linux/err.h>
762306a36Sopenharmony_ci#include <linux/init.h>
862306a36Sopenharmony_ci#include <linux/io.h>
962306a36Sopenharmony_ci#include <linux/mod_devicetable.h>
1062306a36Sopenharmony_ci#include <linux/module.h>
1162306a36Sopenharmony_ci#include <linux/pinctrl/pinctrl.h>
1262306a36Sopenharmony_ci#include <linux/platform_device.h>
1362306a36Sopenharmony_ci
1462306a36Sopenharmony_ci#include "pinctrl-imx.h"
1562306a36Sopenharmony_ci
1662306a36Sopenharmony_cienum imx93_pads {
1762306a36Sopenharmony_ci	IMX93_IOMUXC_DAP_TDI = 0,
1862306a36Sopenharmony_ci	IMX93_IOMUXC_DAP_TMS_SWDIO = 1,
1962306a36Sopenharmony_ci	IMX93_IOMUXC_DAP_TCLK_SWCLK = 2,
2062306a36Sopenharmony_ci	IMX93_IOMUXC_DAP_TDO_TRACESWO = 3,
2162306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO00 = 4,
2262306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO01 = 5,
2362306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO02 = 6,
2462306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO03 = 7,
2562306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO04 = 8,
2662306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO05 = 9,
2762306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO06 = 10,
2862306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO07 = 11,
2962306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO08 = 12,
3062306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO09 = 13,
3162306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO10 = 14,
3262306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO11 = 15,
3362306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO12 = 16,
3462306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO13 = 17,
3562306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO14 = 18,
3662306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO15 = 19,
3762306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO16 = 20,
3862306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO17 = 21,
3962306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO18 = 22,
4062306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO19 = 23,
4162306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO20 = 24,
4262306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO21 = 25,
4362306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO22 = 26,
4462306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO23 = 27,
4562306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO24 = 28,
4662306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO25 = 29,
4762306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO26 = 30,
4862306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO27 = 31,
4962306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO28 = 32,
5062306a36Sopenharmony_ci	IMX93_IOMUXC_GPIO_IO29 = 33,
5162306a36Sopenharmony_ci	IMX93_IOMUXC_CCM_CLKO1 = 34,
5262306a36Sopenharmony_ci	IMX93_IOMUXC_CCM_CLKO2 = 35,
5362306a36Sopenharmony_ci	IMX93_IOMUXC_CCM_CLKO3 = 36,
5462306a36Sopenharmony_ci	IMX93_IOMUXC_CCM_CLKO4 = 37,
5562306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_MDC = 38,
5662306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_MDIO = 39,
5762306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_TD3 = 40,
5862306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_TD2 = 41,
5962306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_TD1 = 42,
6062306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_TD0 = 43,
6162306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_TX_CTL = 44,
6262306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_TXC = 45,
6362306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_RX_CTL = 46,
6462306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_RXC = 47,
6562306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_RD0 = 48,
6662306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_RD1 = 49,
6762306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_RD2 = 50,
6862306a36Sopenharmony_ci	IMX93_IOMUXC_ENET1_RD3 = 51,
6962306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_MDC = 52,
7062306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_MDIO = 53,
7162306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_TD3 = 54,
7262306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_TD2 = 55,
7362306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_TD1 = 56,
7462306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_TD0 = 57,
7562306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_TX_CTL = 58,
7662306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_TXC = 59,
7762306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_RX_CTL = 60,
7862306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_RXC = 61,
7962306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_RD0 = 62,
8062306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_RD1 = 63,
8162306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_RD2 = 64,
8262306a36Sopenharmony_ci	IMX93_IOMUXC_ENET2_RD3 = 65,
8362306a36Sopenharmony_ci	IMX93_IOMUXC_SD1_CLK = 66,
8462306a36Sopenharmony_ci	IMX93_IOMUXC_SD1_CMD = 67,
8562306a36Sopenharmony_ci	IMX93_IOMUXC_SD1_DATA0 = 68,
8662306a36Sopenharmony_ci	IMX93_IOMUXC_SD1_DATA1 = 69,
8762306a36Sopenharmony_ci	IMX93_IOMUXC_SD1_DATA2 = 70,
8862306a36Sopenharmony_ci	IMX93_IOMUXC_SD1_DATA3 = 71,
8962306a36Sopenharmony_ci	IMX93_IOMUXC_SD1_DATA4 = 72,
9062306a36Sopenharmony_ci	IMX93_IOMUXC_SD1_DATA5 = 73,
9162306a36Sopenharmony_ci	IMX93_IOMUXC_SD1_DATA6 = 74,
9262306a36Sopenharmony_ci	IMX93_IOMUXC_SD1_DATA7 = 75,
9362306a36Sopenharmony_ci	IMX93_IOMUXC_SD1_STROBE = 76,
9462306a36Sopenharmony_ci	IMX93_IOMUXC_SD2_VSELECT = 77,
9562306a36Sopenharmony_ci	IMX93_IOMUXC_SD3_CLK = 78,
9662306a36Sopenharmony_ci	IMX93_IOMUXC_SD3_CMD = 79,
9762306a36Sopenharmony_ci	IMX93_IOMUXC_SD3_DATA0 = 80,
9862306a36Sopenharmony_ci	IMX93_IOMUXC_SD3_DATA1 = 81,
9962306a36Sopenharmony_ci	IMX93_IOMUXC_SD3_DATA2 = 82,
10062306a36Sopenharmony_ci	IMX93_IOMUXC_SD3_DATA3 = 83,
10162306a36Sopenharmony_ci	IMX93_IOMUXC_SD2_CD_B = 84,
10262306a36Sopenharmony_ci	IMX93_IOMUXC_SD2_CLK = 85,
10362306a36Sopenharmony_ci	IMX93_IOMUXC_SD2_CMD = 86,
10462306a36Sopenharmony_ci	IMX93_IOMUXC_SD2_DATA0 = 87,
10562306a36Sopenharmony_ci	IMX93_IOMUXC_SD2_DATA1 = 88,
10662306a36Sopenharmony_ci	IMX93_IOMUXC_SD2_DATA2 = 89,
10762306a36Sopenharmony_ci	IMX93_IOMUXC_SD2_DATA3 = 90,
10862306a36Sopenharmony_ci	IMX93_IOMUXC_SD2_RESET_B = 91,
10962306a36Sopenharmony_ci	IMX93_IOMUXC_I2C1_SCL = 92,
11062306a36Sopenharmony_ci	IMX93_IOMUXC_I2C1_SDA = 93,
11162306a36Sopenharmony_ci	IMX93_IOMUXC_I2C2_SCL = 94,
11262306a36Sopenharmony_ci	IMX93_IOMUXC_I2C2_SDA = 95,
11362306a36Sopenharmony_ci	IMX93_IOMUXC_UART1_RXD = 96,
11462306a36Sopenharmony_ci	IMX93_IOMUXC_UART1_TXD = 97,
11562306a36Sopenharmony_ci	IMX93_IOMUXC_UART2_RXD = 98,
11662306a36Sopenharmony_ci	IMX93_IOMUXC_UART2_TXD = 99,
11762306a36Sopenharmony_ci	IMX93_IOMUXC_PDM_CLK = 100,
11862306a36Sopenharmony_ci	IMX93_IOMUXC_PDM_BIT_STREAM0 = 101,
11962306a36Sopenharmony_ci	IMX93_IOMUXC_PDM_BIT_STREAM1 = 102,
12062306a36Sopenharmony_ci	IMX93_IOMUXC_SAI1_TXFS = 103,
12162306a36Sopenharmony_ci	IMX93_IOMUXC_SAI1_TXC = 104,
12262306a36Sopenharmony_ci	IMX93_IOMUXC_SAI1_TXD0 = 105,
12362306a36Sopenharmony_ci	IMX93_IOMUXC_SAI1_RXD0 = 106,
12462306a36Sopenharmony_ci	IMX93_IOMUXC_WDOG_ANY  = 107,
12562306a36Sopenharmony_ci};
12662306a36Sopenharmony_ci
12762306a36Sopenharmony_ci/* Pad names for the pinmux subsystem */
12862306a36Sopenharmony_cistatic const struct pinctrl_pin_desc imx93_pinctrl_pads[] = {
12962306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_DAP_TDI),
13062306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_DAP_TMS_SWDIO),
13162306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_DAP_TCLK_SWCLK),
13262306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_DAP_TDO_TRACESWO),
13362306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO00),
13462306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO01),
13562306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO02),
13662306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO03),
13762306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO04),
13862306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO05),
13962306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO06),
14062306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO07),
14162306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO08),
14262306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO09),
14362306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO10),
14462306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO11),
14562306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO12),
14662306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO13),
14762306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO14),
14862306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO15),
14962306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO16),
15062306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO17),
15162306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO18),
15262306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO19),
15362306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO20),
15462306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO21),
15562306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO22),
15662306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO23),
15762306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO24),
15862306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO25),
15962306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO26),
16062306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO27),
16162306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO28),
16262306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_GPIO_IO29),
16362306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_CCM_CLKO1),
16462306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_CCM_CLKO2),
16562306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_CCM_CLKO3),
16662306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_CCM_CLKO4),
16762306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_MDC),
16862306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_MDIO),
16962306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_TD3),
17062306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_TD2),
17162306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_TD1),
17262306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_TD0),
17362306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_TX_CTL),
17462306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_TXC),
17562306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_RX_CTL),
17662306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_RXC),
17762306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_RD0),
17862306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_RD1),
17962306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_RD2),
18062306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET1_RD3),
18162306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_MDC),
18262306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_MDIO),
18362306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_TD3),
18462306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_TD2),
18562306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_TD1),
18662306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_TD0),
18762306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_TX_CTL),
18862306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_TXC),
18962306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_RX_CTL),
19062306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_RXC),
19162306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_RD0),
19262306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_RD1),
19362306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_RD2),
19462306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_ENET2_RD3),
19562306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD1_CLK),
19662306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD1_CMD),
19762306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD1_DATA0),
19862306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD1_DATA1),
19962306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD1_DATA2),
20062306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD1_DATA3),
20162306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD1_DATA4),
20262306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD1_DATA5),
20362306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD1_DATA6),
20462306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD1_DATA7),
20562306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD1_STROBE),
20662306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD2_VSELECT),
20762306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD3_CLK),
20862306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD3_CMD),
20962306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD3_DATA0),
21062306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD3_DATA1),
21162306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD3_DATA2),
21262306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD3_DATA3),
21362306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD2_CD_B),
21462306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD2_CLK),
21562306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD2_CMD),
21662306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD2_DATA0),
21762306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD2_DATA1),
21862306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD2_DATA2),
21962306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD2_DATA3),
22062306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SD2_RESET_B),
22162306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_I2C1_SCL),
22262306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_I2C1_SDA),
22362306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_I2C2_SCL),
22462306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_I2C2_SDA),
22562306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_UART1_RXD),
22662306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_UART1_TXD),
22762306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_UART2_RXD),
22862306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_UART2_TXD),
22962306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_PDM_CLK),
23062306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_PDM_BIT_STREAM0),
23162306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_PDM_BIT_STREAM1),
23262306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SAI1_TXFS),
23362306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SAI1_TXC),
23462306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SAI1_TXD0),
23562306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_SAI1_RXD0),
23662306a36Sopenharmony_ci	IMX_PINCTRL_PIN(IMX93_IOMUXC_WDOG_ANY),
23762306a36Sopenharmony_ci};
23862306a36Sopenharmony_ci
23962306a36Sopenharmony_cistatic const struct imx_pinctrl_soc_info imx93_pinctrl_info = {
24062306a36Sopenharmony_ci	.pins = imx93_pinctrl_pads,
24162306a36Sopenharmony_ci	.npins = ARRAY_SIZE(imx93_pinctrl_pads),
24262306a36Sopenharmony_ci	.flags = ZERO_OFFSET_VALID,
24362306a36Sopenharmony_ci	.gpr_compatible = "fsl,imx93-iomuxc-gpr",
24462306a36Sopenharmony_ci};
24562306a36Sopenharmony_ci
24662306a36Sopenharmony_cistatic const struct of_device_id imx93_pinctrl_of_match[] = {
24762306a36Sopenharmony_ci	{ .compatible = "fsl,imx93-iomuxc", },
24862306a36Sopenharmony_ci	{ /* sentinel */ }
24962306a36Sopenharmony_ci};
25062306a36Sopenharmony_ciMODULE_DEVICE_TABLE(of, imx93_pinctrl_of_match);
25162306a36Sopenharmony_ci
25262306a36Sopenharmony_cistatic int imx93_pinctrl_probe(struct platform_device *pdev)
25362306a36Sopenharmony_ci{
25462306a36Sopenharmony_ci	return imx_pinctrl_probe(pdev, &imx93_pinctrl_info);
25562306a36Sopenharmony_ci}
25662306a36Sopenharmony_ci
25762306a36Sopenharmony_cistatic struct platform_driver imx93_pinctrl_driver = {
25862306a36Sopenharmony_ci	.driver = {
25962306a36Sopenharmony_ci		.name = "imx93-pinctrl",
26062306a36Sopenharmony_ci		.of_match_table = imx93_pinctrl_of_match,
26162306a36Sopenharmony_ci		.suppress_bind_attrs = true,
26262306a36Sopenharmony_ci	},
26362306a36Sopenharmony_ci	.probe = imx93_pinctrl_probe,
26462306a36Sopenharmony_ci};
26562306a36Sopenharmony_ci
26662306a36Sopenharmony_cistatic int __init imx93_pinctrl_init(void)
26762306a36Sopenharmony_ci{
26862306a36Sopenharmony_ci	return platform_driver_register(&imx93_pinctrl_driver);
26962306a36Sopenharmony_ci}
27062306a36Sopenharmony_ciarch_initcall(imx93_pinctrl_init);
27162306a36Sopenharmony_ci
27262306a36Sopenharmony_ciMODULE_AUTHOR("Bai Ping <ping.bai@nxp.com>");
27362306a36Sopenharmony_ciMODULE_DESCRIPTION("NXP i.MX93 pinctrl driver");
27462306a36Sopenharmony_ciMODULE_LICENSE("GPL v2");
275