162306a36Sopenharmony_ci// SPDX-License-Identifier: GPL-2.0-only
262306a36Sopenharmony_ci/*
362306a36Sopenharmony_ci * Copyright (c) 2016-2018, The Linux Foundation. All rights reserved.
462306a36Sopenharmony_ci * Copyright (C) 2022, Kernkonzept GmbH.
562306a36Sopenharmony_ci */
662306a36Sopenharmony_ci
762306a36Sopenharmony_ci#include <linux/module.h>
862306a36Sopenharmony_ci#include <linux/of.h>
962306a36Sopenharmony_ci#include <linux/platform_device.h>
1062306a36Sopenharmony_ci
1162306a36Sopenharmony_ci#include "pinctrl-msm.h"
1262306a36Sopenharmony_ci
1362306a36Sopenharmony_ci#define REG_SIZE 0x1000
1462306a36Sopenharmony_ci#define PINGROUP(id, f1, f2, f3, f4, f5, f6, f7, f8, f9)	\
1562306a36Sopenharmony_ci	{						\
1662306a36Sopenharmony_ci		.grp = PINCTRL_PINGROUP("gpio" #id, 	\
1762306a36Sopenharmony_ci			gpio##id##_pins, 		\
1862306a36Sopenharmony_ci			ARRAY_SIZE(gpio##id##_pins)),	\
1962306a36Sopenharmony_ci		.funcs = (int[]){			\
2062306a36Sopenharmony_ci			msm_mux_gpio,			\
2162306a36Sopenharmony_ci			msm_mux_##f1,			\
2262306a36Sopenharmony_ci			msm_mux_##f2,			\
2362306a36Sopenharmony_ci			msm_mux_##f3,			\
2462306a36Sopenharmony_ci			msm_mux_##f4,			\
2562306a36Sopenharmony_ci			msm_mux_##f5,			\
2662306a36Sopenharmony_ci			msm_mux_##f6,			\
2762306a36Sopenharmony_ci			msm_mux_##f7,			\
2862306a36Sopenharmony_ci			msm_mux_##f8,			\
2962306a36Sopenharmony_ci			msm_mux_##f9,			\
3062306a36Sopenharmony_ci		},					\
3162306a36Sopenharmony_ci		.nfuncs = 10,				\
3262306a36Sopenharmony_ci		.ctl_reg = REG_SIZE * id,		\
3362306a36Sopenharmony_ci		.io_reg = 0x4 + REG_SIZE * id,		\
3462306a36Sopenharmony_ci		.intr_cfg_reg = 0x8 + REG_SIZE * id,	\
3562306a36Sopenharmony_ci		.intr_status_reg = 0xc + REG_SIZE * id,	\
3662306a36Sopenharmony_ci		.intr_target_reg = 0x8 + REG_SIZE * id,	\
3762306a36Sopenharmony_ci		.mux_bit = 2,				\
3862306a36Sopenharmony_ci		.pull_bit = 0,				\
3962306a36Sopenharmony_ci		.drv_bit = 6,				\
4062306a36Sopenharmony_ci		.oe_bit = 9,				\
4162306a36Sopenharmony_ci		.in_bit = 0,				\
4262306a36Sopenharmony_ci		.out_bit = 1,				\
4362306a36Sopenharmony_ci		.intr_enable_bit = 0,			\
4462306a36Sopenharmony_ci		.intr_status_bit = 0,			\
4562306a36Sopenharmony_ci		.intr_target_bit = 5,			\
4662306a36Sopenharmony_ci		.intr_target_kpss_val = 4,		\
4762306a36Sopenharmony_ci		.intr_raw_status_bit = 4,		\
4862306a36Sopenharmony_ci		.intr_polarity_bit = 1,			\
4962306a36Sopenharmony_ci		.intr_detection_bit = 2,		\
5062306a36Sopenharmony_ci		.intr_detection_width = 2,		\
5162306a36Sopenharmony_ci	}
5262306a36Sopenharmony_ci
5362306a36Sopenharmony_ci#define SDC_QDSD_PINGROUP(pg_name, ctl, pull, drv)	\
5462306a36Sopenharmony_ci	{						\
5562306a36Sopenharmony_ci		.grp = PINCTRL_PINGROUP(#pg_name, 	\
5662306a36Sopenharmony_ci			pg_name##_pins, 		\
5762306a36Sopenharmony_ci			ARRAY_SIZE(pg_name##_pins)),	\
5862306a36Sopenharmony_ci		.ctl_reg = ctl,				\
5962306a36Sopenharmony_ci		.io_reg = 0,				\
6062306a36Sopenharmony_ci		.intr_cfg_reg = 0,			\
6162306a36Sopenharmony_ci		.intr_status_reg = 0,			\
6262306a36Sopenharmony_ci		.intr_target_reg = 0,			\
6362306a36Sopenharmony_ci		.mux_bit = -1,				\
6462306a36Sopenharmony_ci		.pull_bit = pull,			\
6562306a36Sopenharmony_ci		.drv_bit = drv,				\
6662306a36Sopenharmony_ci		.oe_bit = -1,				\
6762306a36Sopenharmony_ci		.in_bit = -1,				\
6862306a36Sopenharmony_ci		.out_bit = -1,				\
6962306a36Sopenharmony_ci		.intr_enable_bit = -1,			\
7062306a36Sopenharmony_ci		.intr_status_bit = -1,			\
7162306a36Sopenharmony_ci		.intr_target_bit = -1,			\
7262306a36Sopenharmony_ci		.intr_raw_status_bit = -1,		\
7362306a36Sopenharmony_ci		.intr_polarity_bit = -1,		\
7462306a36Sopenharmony_ci		.intr_detection_bit = -1,		\
7562306a36Sopenharmony_ci		.intr_detection_width = -1,		\
7662306a36Sopenharmony_ci	}
7762306a36Sopenharmony_cistatic const struct pinctrl_pin_desc msm8909_pins[] = {
7862306a36Sopenharmony_ci	PINCTRL_PIN(0, "GPIO_0"),
7962306a36Sopenharmony_ci	PINCTRL_PIN(1, "GPIO_1"),
8062306a36Sopenharmony_ci	PINCTRL_PIN(2, "GPIO_2"),
8162306a36Sopenharmony_ci	PINCTRL_PIN(3, "GPIO_3"),
8262306a36Sopenharmony_ci	PINCTRL_PIN(4, "GPIO_4"),
8362306a36Sopenharmony_ci	PINCTRL_PIN(5, "GPIO_5"),
8462306a36Sopenharmony_ci	PINCTRL_PIN(6, "GPIO_6"),
8562306a36Sopenharmony_ci	PINCTRL_PIN(7, "GPIO_7"),
8662306a36Sopenharmony_ci	PINCTRL_PIN(8, "GPIO_8"),
8762306a36Sopenharmony_ci	PINCTRL_PIN(9, "GPIO_9"),
8862306a36Sopenharmony_ci	PINCTRL_PIN(10, "GPIO_10"),
8962306a36Sopenharmony_ci	PINCTRL_PIN(11, "GPIO_11"),
9062306a36Sopenharmony_ci	PINCTRL_PIN(12, "GPIO_12"),
9162306a36Sopenharmony_ci	PINCTRL_PIN(13, "GPIO_13"),
9262306a36Sopenharmony_ci	PINCTRL_PIN(14, "GPIO_14"),
9362306a36Sopenharmony_ci	PINCTRL_PIN(15, "GPIO_15"),
9462306a36Sopenharmony_ci	PINCTRL_PIN(16, "GPIO_16"),
9562306a36Sopenharmony_ci	PINCTRL_PIN(17, "GPIO_17"),
9662306a36Sopenharmony_ci	PINCTRL_PIN(18, "GPIO_18"),
9762306a36Sopenharmony_ci	PINCTRL_PIN(19, "GPIO_19"),
9862306a36Sopenharmony_ci	PINCTRL_PIN(20, "GPIO_20"),
9962306a36Sopenharmony_ci	PINCTRL_PIN(21, "GPIO_21"),
10062306a36Sopenharmony_ci	PINCTRL_PIN(22, "GPIO_22"),
10162306a36Sopenharmony_ci	PINCTRL_PIN(23, "GPIO_23"),
10262306a36Sopenharmony_ci	PINCTRL_PIN(24, "GPIO_24"),
10362306a36Sopenharmony_ci	PINCTRL_PIN(25, "GPIO_25"),
10462306a36Sopenharmony_ci	PINCTRL_PIN(26, "GPIO_26"),
10562306a36Sopenharmony_ci	PINCTRL_PIN(27, "GPIO_27"),
10662306a36Sopenharmony_ci	PINCTRL_PIN(28, "GPIO_28"),
10762306a36Sopenharmony_ci	PINCTRL_PIN(29, "GPIO_29"),
10862306a36Sopenharmony_ci	PINCTRL_PIN(30, "GPIO_30"),
10962306a36Sopenharmony_ci	PINCTRL_PIN(31, "GPIO_31"),
11062306a36Sopenharmony_ci	PINCTRL_PIN(32, "GPIO_32"),
11162306a36Sopenharmony_ci	PINCTRL_PIN(33, "GPIO_33"),
11262306a36Sopenharmony_ci	PINCTRL_PIN(34, "GPIO_34"),
11362306a36Sopenharmony_ci	PINCTRL_PIN(35, "GPIO_35"),
11462306a36Sopenharmony_ci	PINCTRL_PIN(36, "GPIO_36"),
11562306a36Sopenharmony_ci	PINCTRL_PIN(37, "GPIO_37"),
11662306a36Sopenharmony_ci	PINCTRL_PIN(38, "GPIO_38"),
11762306a36Sopenharmony_ci	PINCTRL_PIN(39, "GPIO_39"),
11862306a36Sopenharmony_ci	PINCTRL_PIN(40, "GPIO_40"),
11962306a36Sopenharmony_ci	PINCTRL_PIN(41, "GPIO_41"),
12062306a36Sopenharmony_ci	PINCTRL_PIN(42, "GPIO_42"),
12162306a36Sopenharmony_ci	PINCTRL_PIN(43, "GPIO_43"),
12262306a36Sopenharmony_ci	PINCTRL_PIN(44, "GPIO_44"),
12362306a36Sopenharmony_ci	PINCTRL_PIN(45, "GPIO_45"),
12462306a36Sopenharmony_ci	PINCTRL_PIN(46, "GPIO_46"),
12562306a36Sopenharmony_ci	PINCTRL_PIN(47, "GPIO_47"),
12662306a36Sopenharmony_ci	PINCTRL_PIN(48, "GPIO_48"),
12762306a36Sopenharmony_ci	PINCTRL_PIN(49, "GPIO_49"),
12862306a36Sopenharmony_ci	PINCTRL_PIN(50, "GPIO_50"),
12962306a36Sopenharmony_ci	PINCTRL_PIN(51, "GPIO_51"),
13062306a36Sopenharmony_ci	PINCTRL_PIN(52, "GPIO_52"),
13162306a36Sopenharmony_ci	PINCTRL_PIN(53, "GPIO_53"),
13262306a36Sopenharmony_ci	PINCTRL_PIN(54, "GPIO_54"),
13362306a36Sopenharmony_ci	PINCTRL_PIN(55, "GPIO_55"),
13462306a36Sopenharmony_ci	PINCTRL_PIN(56, "GPIO_56"),
13562306a36Sopenharmony_ci	PINCTRL_PIN(57, "GPIO_57"),
13662306a36Sopenharmony_ci	PINCTRL_PIN(58, "GPIO_58"),
13762306a36Sopenharmony_ci	PINCTRL_PIN(59, "GPIO_59"),
13862306a36Sopenharmony_ci	PINCTRL_PIN(60, "GPIO_60"),
13962306a36Sopenharmony_ci	PINCTRL_PIN(61, "GPIO_61"),
14062306a36Sopenharmony_ci	PINCTRL_PIN(62, "GPIO_62"),
14162306a36Sopenharmony_ci	PINCTRL_PIN(63, "GPIO_63"),
14262306a36Sopenharmony_ci	PINCTRL_PIN(64, "GPIO_64"),
14362306a36Sopenharmony_ci	PINCTRL_PIN(65, "GPIO_65"),
14462306a36Sopenharmony_ci	PINCTRL_PIN(66, "GPIO_66"),
14562306a36Sopenharmony_ci	PINCTRL_PIN(67, "GPIO_67"),
14662306a36Sopenharmony_ci	PINCTRL_PIN(68, "GPIO_68"),
14762306a36Sopenharmony_ci	PINCTRL_PIN(69, "GPIO_69"),
14862306a36Sopenharmony_ci	PINCTRL_PIN(70, "GPIO_70"),
14962306a36Sopenharmony_ci	PINCTRL_PIN(71, "GPIO_71"),
15062306a36Sopenharmony_ci	PINCTRL_PIN(72, "GPIO_72"),
15162306a36Sopenharmony_ci	PINCTRL_PIN(73, "GPIO_73"),
15262306a36Sopenharmony_ci	PINCTRL_PIN(74, "GPIO_74"),
15362306a36Sopenharmony_ci	PINCTRL_PIN(75, "GPIO_75"),
15462306a36Sopenharmony_ci	PINCTRL_PIN(76, "GPIO_76"),
15562306a36Sopenharmony_ci	PINCTRL_PIN(77, "GPIO_77"),
15662306a36Sopenharmony_ci	PINCTRL_PIN(78, "GPIO_78"),
15762306a36Sopenharmony_ci	PINCTRL_PIN(79, "GPIO_79"),
15862306a36Sopenharmony_ci	PINCTRL_PIN(80, "GPIO_80"),
15962306a36Sopenharmony_ci	PINCTRL_PIN(81, "GPIO_81"),
16062306a36Sopenharmony_ci	PINCTRL_PIN(82, "GPIO_82"),
16162306a36Sopenharmony_ci	PINCTRL_PIN(83, "GPIO_83"),
16262306a36Sopenharmony_ci	PINCTRL_PIN(84, "GPIO_84"),
16362306a36Sopenharmony_ci	PINCTRL_PIN(85, "GPIO_85"),
16462306a36Sopenharmony_ci	PINCTRL_PIN(86, "GPIO_86"),
16562306a36Sopenharmony_ci	PINCTRL_PIN(87, "GPIO_87"),
16662306a36Sopenharmony_ci	PINCTRL_PIN(88, "GPIO_88"),
16762306a36Sopenharmony_ci	PINCTRL_PIN(89, "GPIO_89"),
16862306a36Sopenharmony_ci	PINCTRL_PIN(90, "GPIO_90"),
16962306a36Sopenharmony_ci	PINCTRL_PIN(91, "GPIO_91"),
17062306a36Sopenharmony_ci	PINCTRL_PIN(92, "GPIO_92"),
17162306a36Sopenharmony_ci	PINCTRL_PIN(93, "GPIO_93"),
17262306a36Sopenharmony_ci	PINCTRL_PIN(94, "GPIO_94"),
17362306a36Sopenharmony_ci	PINCTRL_PIN(95, "GPIO_95"),
17462306a36Sopenharmony_ci	PINCTRL_PIN(96, "GPIO_96"),
17562306a36Sopenharmony_ci	PINCTRL_PIN(97, "GPIO_97"),
17662306a36Sopenharmony_ci	PINCTRL_PIN(98, "GPIO_98"),
17762306a36Sopenharmony_ci	PINCTRL_PIN(99, "GPIO_99"),
17862306a36Sopenharmony_ci	PINCTRL_PIN(100, "GPIO_100"),
17962306a36Sopenharmony_ci	PINCTRL_PIN(101, "GPIO_101"),
18062306a36Sopenharmony_ci	PINCTRL_PIN(102, "GPIO_102"),
18162306a36Sopenharmony_ci	PINCTRL_PIN(103, "GPIO_103"),
18262306a36Sopenharmony_ci	PINCTRL_PIN(104, "GPIO_104"),
18362306a36Sopenharmony_ci	PINCTRL_PIN(105, "GPIO_105"),
18462306a36Sopenharmony_ci	PINCTRL_PIN(106, "GPIO_106"),
18562306a36Sopenharmony_ci	PINCTRL_PIN(107, "GPIO_107"),
18662306a36Sopenharmony_ci	PINCTRL_PIN(108, "GPIO_108"),
18762306a36Sopenharmony_ci	PINCTRL_PIN(109, "GPIO_109"),
18862306a36Sopenharmony_ci	PINCTRL_PIN(110, "GPIO_110"),
18962306a36Sopenharmony_ci	PINCTRL_PIN(111, "GPIO_111"),
19062306a36Sopenharmony_ci	PINCTRL_PIN(112, "GPIO_112"),
19162306a36Sopenharmony_ci	PINCTRL_PIN(113, "SDC1_CLK"),
19262306a36Sopenharmony_ci	PINCTRL_PIN(114, "SDC1_CMD"),
19362306a36Sopenharmony_ci	PINCTRL_PIN(115, "SDC1_DATA"),
19462306a36Sopenharmony_ci	PINCTRL_PIN(116, "SDC2_CLK"),
19562306a36Sopenharmony_ci	PINCTRL_PIN(117, "SDC2_CMD"),
19662306a36Sopenharmony_ci	PINCTRL_PIN(118, "SDC2_DATA"),
19762306a36Sopenharmony_ci	PINCTRL_PIN(119, "QDSD_CLK"),
19862306a36Sopenharmony_ci	PINCTRL_PIN(120, "QDSD_CMD"),
19962306a36Sopenharmony_ci	PINCTRL_PIN(121, "QDSD_DATA0"),
20062306a36Sopenharmony_ci	PINCTRL_PIN(122, "QDSD_DATA1"),
20162306a36Sopenharmony_ci	PINCTRL_PIN(123, "QDSD_DATA2"),
20262306a36Sopenharmony_ci	PINCTRL_PIN(124, "QDSD_DATA3"),
20362306a36Sopenharmony_ci};
20462306a36Sopenharmony_ci
20562306a36Sopenharmony_ci#define DECLARE_MSM_GPIO_PINS(pin) \
20662306a36Sopenharmony_ci	static const unsigned int gpio##pin##_pins[] = { pin }
20762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(0);
20862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(1);
20962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(2);
21062306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(3);
21162306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(4);
21262306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(5);
21362306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(6);
21462306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(7);
21562306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(8);
21662306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(9);
21762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(10);
21862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(11);
21962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(12);
22062306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(13);
22162306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(14);
22262306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(15);
22362306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(16);
22462306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(17);
22562306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(18);
22662306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(19);
22762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(20);
22862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(21);
22962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(22);
23062306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(23);
23162306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(24);
23262306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(25);
23362306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(26);
23462306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(27);
23562306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(28);
23662306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(29);
23762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(30);
23862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(31);
23962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(32);
24062306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(33);
24162306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(34);
24262306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(35);
24362306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(36);
24462306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(37);
24562306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(38);
24662306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(39);
24762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(40);
24862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(41);
24962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(42);
25062306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(43);
25162306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(44);
25262306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(45);
25362306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(46);
25462306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(47);
25562306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(48);
25662306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(49);
25762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(50);
25862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(51);
25962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(52);
26062306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(53);
26162306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(54);
26262306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(55);
26362306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(56);
26462306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(57);
26562306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(58);
26662306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(59);
26762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(60);
26862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(61);
26962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(62);
27062306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(63);
27162306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(64);
27262306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(65);
27362306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(66);
27462306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(67);
27562306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(68);
27662306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(69);
27762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(70);
27862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(71);
27962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(72);
28062306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(73);
28162306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(74);
28262306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(75);
28362306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(76);
28462306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(77);
28562306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(78);
28662306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(79);
28762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(80);
28862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(81);
28962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(82);
29062306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(83);
29162306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(84);
29262306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(85);
29362306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(86);
29462306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(87);
29562306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(88);
29662306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(89);
29762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(90);
29862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(91);
29962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(92);
30062306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(93);
30162306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(94);
30262306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(95);
30362306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(96);
30462306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(97);
30562306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(98);
30662306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(99);
30762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(100);
30862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(101);
30962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(102);
31062306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(103);
31162306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(104);
31262306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(105);
31362306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(106);
31462306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(107);
31562306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(108);
31662306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(109);
31762306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(110);
31862306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(111);
31962306a36Sopenharmony_ciDECLARE_MSM_GPIO_PINS(112);
32062306a36Sopenharmony_ci
32162306a36Sopenharmony_cistatic const unsigned int sdc1_clk_pins[] = { 113 };
32262306a36Sopenharmony_cistatic const unsigned int sdc1_cmd_pins[] = { 114 };
32362306a36Sopenharmony_cistatic const unsigned int sdc1_data_pins[] = { 115 };
32462306a36Sopenharmony_cistatic const unsigned int sdc2_clk_pins[] = { 116 };
32562306a36Sopenharmony_cistatic const unsigned int sdc2_cmd_pins[] = { 117 };
32662306a36Sopenharmony_cistatic const unsigned int sdc2_data_pins[] = { 118 };
32762306a36Sopenharmony_cistatic const unsigned int qdsd_clk_pins[] = { 119 };
32862306a36Sopenharmony_cistatic const unsigned int qdsd_cmd_pins[] = { 120 };
32962306a36Sopenharmony_cistatic const unsigned int qdsd_data0_pins[] = { 121 };
33062306a36Sopenharmony_cistatic const unsigned int qdsd_data1_pins[] = { 122 };
33162306a36Sopenharmony_cistatic const unsigned int qdsd_data2_pins[] = { 123 };
33262306a36Sopenharmony_cistatic const unsigned int qdsd_data3_pins[] = { 124 };
33362306a36Sopenharmony_ci
33462306a36Sopenharmony_cienum msm8909_functions {
33562306a36Sopenharmony_ci	msm_mux_gpio,
33662306a36Sopenharmony_ci	msm_mux_adsp_ext,
33762306a36Sopenharmony_ci	msm_mux_atest_bbrx0,
33862306a36Sopenharmony_ci	msm_mux_atest_bbrx1,
33962306a36Sopenharmony_ci	msm_mux_atest_char,
34062306a36Sopenharmony_ci	msm_mux_atest_char0,
34162306a36Sopenharmony_ci	msm_mux_atest_char1,
34262306a36Sopenharmony_ci	msm_mux_atest_char2,
34362306a36Sopenharmony_ci	msm_mux_atest_char3,
34462306a36Sopenharmony_ci	msm_mux_atest_combodac,
34562306a36Sopenharmony_ci	msm_mux_atest_gpsadc0,
34662306a36Sopenharmony_ci	msm_mux_atest_gpsadc1,
34762306a36Sopenharmony_ci	msm_mux_atest_wlan0,
34862306a36Sopenharmony_ci	msm_mux_atest_wlan1,
34962306a36Sopenharmony_ci	msm_mux_bimc_dte0,
35062306a36Sopenharmony_ci	msm_mux_bimc_dte1,
35162306a36Sopenharmony_ci	msm_mux_blsp_i2c1,
35262306a36Sopenharmony_ci	msm_mux_blsp_i2c2,
35362306a36Sopenharmony_ci	msm_mux_blsp_i2c3,
35462306a36Sopenharmony_ci	msm_mux_blsp_i2c4,
35562306a36Sopenharmony_ci	msm_mux_blsp_i2c5,
35662306a36Sopenharmony_ci	msm_mux_blsp_i2c6,
35762306a36Sopenharmony_ci	msm_mux_blsp_spi1,
35862306a36Sopenharmony_ci	msm_mux_blsp_spi1_cs1,
35962306a36Sopenharmony_ci	msm_mux_blsp_spi1_cs2,
36062306a36Sopenharmony_ci	msm_mux_blsp_spi1_cs3,
36162306a36Sopenharmony_ci	msm_mux_blsp_spi2,
36262306a36Sopenharmony_ci	msm_mux_blsp_spi2_cs1,
36362306a36Sopenharmony_ci	msm_mux_blsp_spi2_cs2,
36462306a36Sopenharmony_ci	msm_mux_blsp_spi2_cs3,
36562306a36Sopenharmony_ci	msm_mux_blsp_spi3,
36662306a36Sopenharmony_ci	msm_mux_blsp_spi3_cs1,
36762306a36Sopenharmony_ci	msm_mux_blsp_spi3_cs2,
36862306a36Sopenharmony_ci	msm_mux_blsp_spi3_cs3,
36962306a36Sopenharmony_ci	msm_mux_blsp_spi4,
37062306a36Sopenharmony_ci	msm_mux_blsp_spi5,
37162306a36Sopenharmony_ci	msm_mux_blsp_spi6,
37262306a36Sopenharmony_ci	msm_mux_blsp_uart1,
37362306a36Sopenharmony_ci	msm_mux_blsp_uart2,
37462306a36Sopenharmony_ci	msm_mux_blsp_uim1,
37562306a36Sopenharmony_ci	msm_mux_blsp_uim2,
37662306a36Sopenharmony_ci	msm_mux_cam_mclk,
37762306a36Sopenharmony_ci	msm_mux_cci_async,
37862306a36Sopenharmony_ci	msm_mux_cci_timer0,
37962306a36Sopenharmony_ci	msm_mux_cci_timer1,
38062306a36Sopenharmony_ci	msm_mux_cci_timer2,
38162306a36Sopenharmony_ci	msm_mux_cdc_pdm0,
38262306a36Sopenharmony_ci	msm_mux_dbg_out,
38362306a36Sopenharmony_ci	msm_mux_dmic0_clk,
38462306a36Sopenharmony_ci	msm_mux_dmic0_data,
38562306a36Sopenharmony_ci	msm_mux_ebi0_wrcdc,
38662306a36Sopenharmony_ci	msm_mux_ebi2_a,
38762306a36Sopenharmony_ci	msm_mux_ebi2_lcd,
38862306a36Sopenharmony_ci	msm_mux_ext_lpass,
38962306a36Sopenharmony_ci	msm_mux_gcc_gp1_clk_a,
39062306a36Sopenharmony_ci	msm_mux_gcc_gp1_clk_b,
39162306a36Sopenharmony_ci	msm_mux_gcc_gp2_clk_a,
39262306a36Sopenharmony_ci	msm_mux_gcc_gp2_clk_b,
39362306a36Sopenharmony_ci	msm_mux_gcc_gp3_clk_a,
39462306a36Sopenharmony_ci	msm_mux_gcc_gp3_clk_b,
39562306a36Sopenharmony_ci	msm_mux_gcc_plltest,
39662306a36Sopenharmony_ci	msm_mux_gsm0_tx,
39762306a36Sopenharmony_ci	msm_mux_ldo_en,
39862306a36Sopenharmony_ci	msm_mux_ldo_update,
39962306a36Sopenharmony_ci	msm_mux_m_voc,
40062306a36Sopenharmony_ci	msm_mux_mdp_vsync,
40162306a36Sopenharmony_ci	msm_mux_modem_tsync,
40262306a36Sopenharmony_ci	msm_mux_nav_pps,
40362306a36Sopenharmony_ci	msm_mux_nav_tsync,
40462306a36Sopenharmony_ci	msm_mux_pa_indicator,
40562306a36Sopenharmony_ci	msm_mux_pbs0,
40662306a36Sopenharmony_ci	msm_mux_pbs1,
40762306a36Sopenharmony_ci	msm_mux_pbs2,
40862306a36Sopenharmony_ci	msm_mux_pri_mi2s_data0_a,
40962306a36Sopenharmony_ci	msm_mux_pri_mi2s_data0_b,
41062306a36Sopenharmony_ci	msm_mux_pri_mi2s_data1_a,
41162306a36Sopenharmony_ci	msm_mux_pri_mi2s_data1_b,
41262306a36Sopenharmony_ci	msm_mux_pri_mi2s_mclk_a,
41362306a36Sopenharmony_ci	msm_mux_pri_mi2s_mclk_b,
41462306a36Sopenharmony_ci	msm_mux_pri_mi2s_sck_a,
41562306a36Sopenharmony_ci	msm_mux_pri_mi2s_sck_b,
41662306a36Sopenharmony_ci	msm_mux_pri_mi2s_ws_a,
41762306a36Sopenharmony_ci	msm_mux_pri_mi2s_ws_b,
41862306a36Sopenharmony_ci	msm_mux_prng_rosc,
41962306a36Sopenharmony_ci	msm_mux_pwr_crypto_enabled_a,
42062306a36Sopenharmony_ci	msm_mux_pwr_crypto_enabled_b,
42162306a36Sopenharmony_ci	msm_mux_pwr_modem_enabled_a,
42262306a36Sopenharmony_ci	msm_mux_pwr_modem_enabled_b,
42362306a36Sopenharmony_ci	msm_mux_pwr_nav_enabled_a,
42462306a36Sopenharmony_ci	msm_mux_pwr_nav_enabled_b,
42562306a36Sopenharmony_ci	msm_mux_qdss_cti_trig_in_a0,
42662306a36Sopenharmony_ci	msm_mux_qdss_cti_trig_in_a1,
42762306a36Sopenharmony_ci	msm_mux_qdss_cti_trig_in_b0,
42862306a36Sopenharmony_ci	msm_mux_qdss_cti_trig_in_b1,
42962306a36Sopenharmony_ci	msm_mux_qdss_cti_trig_out_a0,
43062306a36Sopenharmony_ci	msm_mux_qdss_cti_trig_out_a1,
43162306a36Sopenharmony_ci	msm_mux_qdss_cti_trig_out_b0,
43262306a36Sopenharmony_ci	msm_mux_qdss_cti_trig_out_b1,
43362306a36Sopenharmony_ci	msm_mux_qdss_traceclk_a,
43462306a36Sopenharmony_ci	msm_mux_qdss_tracectl_a,
43562306a36Sopenharmony_ci	msm_mux_qdss_tracedata_a,
43662306a36Sopenharmony_ci	msm_mux_qdss_tracedata_b,
43762306a36Sopenharmony_ci	msm_mux_sd_write,
43862306a36Sopenharmony_ci	msm_mux_sec_mi2s,
43962306a36Sopenharmony_ci	msm_mux_smb_int,
44062306a36Sopenharmony_ci	msm_mux_ssbi0,
44162306a36Sopenharmony_ci	msm_mux_ssbi1,
44262306a36Sopenharmony_ci	msm_mux_uim1_clk,
44362306a36Sopenharmony_ci	msm_mux_uim1_data,
44462306a36Sopenharmony_ci	msm_mux_uim1_present,
44562306a36Sopenharmony_ci	msm_mux_uim1_reset,
44662306a36Sopenharmony_ci	msm_mux_uim2_clk,
44762306a36Sopenharmony_ci	msm_mux_uim2_data,
44862306a36Sopenharmony_ci	msm_mux_uim2_present,
44962306a36Sopenharmony_ci	msm_mux_uim2_reset,
45062306a36Sopenharmony_ci	msm_mux_uim3_clk,
45162306a36Sopenharmony_ci	msm_mux_uim3_data,
45262306a36Sopenharmony_ci	msm_mux_uim3_present,
45362306a36Sopenharmony_ci	msm_mux_uim3_reset,
45462306a36Sopenharmony_ci	msm_mux_uim_batt,
45562306a36Sopenharmony_ci	msm_mux_wcss_bt,
45662306a36Sopenharmony_ci	msm_mux_wcss_fm,
45762306a36Sopenharmony_ci	msm_mux_wcss_wlan,
45862306a36Sopenharmony_ci	msm_mux__,
45962306a36Sopenharmony_ci};
46062306a36Sopenharmony_ci
46162306a36Sopenharmony_cistatic const char * const adsp_ext_groups[] = { "gpio38" };
46262306a36Sopenharmony_cistatic const char * const atest_bbrx0_groups[] = { "gpio37" };
46362306a36Sopenharmony_cistatic const char * const atest_bbrx1_groups[] = { "gpio36" };
46462306a36Sopenharmony_cistatic const char * const atest_char0_groups[] = { "gpio62" };
46562306a36Sopenharmony_cistatic const char * const atest_char1_groups[] = { "gpio61" };
46662306a36Sopenharmony_cistatic const char * const atest_char2_groups[] = { "gpio60" };
46762306a36Sopenharmony_cistatic const char * const atest_char3_groups[] = { "gpio59" };
46862306a36Sopenharmony_cistatic const char * const atest_char_groups[] = { "gpio63" };
46962306a36Sopenharmony_cistatic const char * const atest_combodac_groups[] = {
47062306a36Sopenharmony_ci	"gpio32", "gpio38", "gpio39", "gpio40", "gpio41", "gpio42", "gpio43",
47162306a36Sopenharmony_ci	"gpio44", "gpio45", "gpio47", "gpio48", "gpio66", "gpio81", "gpio83",
47262306a36Sopenharmony_ci	"gpio84", "gpio85", "gpio86", "gpio94", "gpio95", "gpio110"
47362306a36Sopenharmony_ci};
47462306a36Sopenharmony_cistatic const char * const atest_gpsadc0_groups[] = { "gpio65" };
47562306a36Sopenharmony_cistatic const char * const atest_gpsadc1_groups[] = { "gpio79" };
47662306a36Sopenharmony_cistatic const char * const atest_wlan0_groups[] = { "gpio96" };
47762306a36Sopenharmony_cistatic const char * const atest_wlan1_groups[] = { "gpio97" };
47862306a36Sopenharmony_cistatic const char * const bimc_dte0_groups[] = { "gpio6", "gpio59" };
47962306a36Sopenharmony_cistatic const char * const bimc_dte1_groups[] = { "gpio7", "gpio60" };
48062306a36Sopenharmony_cistatic const char * const blsp_i2c1_groups[] = { "gpio6", "gpio7" };
48162306a36Sopenharmony_cistatic const char * const blsp_i2c2_groups[] = { "gpio111", "gpio112" };
48262306a36Sopenharmony_cistatic const char * const blsp_i2c3_groups[] = { "gpio29", "gpio30" };
48362306a36Sopenharmony_cistatic const char * const blsp_i2c4_groups[] = { "gpio14", "gpio15" };
48462306a36Sopenharmony_cistatic const char * const blsp_i2c5_groups[] = { "gpio18", "gpio19" };
48562306a36Sopenharmony_cistatic const char * const blsp_i2c6_groups[] = { "gpio10", "gpio11" };
48662306a36Sopenharmony_cistatic const char * const blsp_spi1_cs1_groups[] = { "gpio97" };
48762306a36Sopenharmony_cistatic const char * const blsp_spi1_cs2_groups[] = { "gpio37" };
48862306a36Sopenharmony_cistatic const char * const blsp_spi1_cs3_groups[] = { "gpio65" };
48962306a36Sopenharmony_cistatic const char * const blsp_spi1_groups[] = {
49062306a36Sopenharmony_ci	"gpio4", "gpio5", "gpio6", "gpio7"
49162306a36Sopenharmony_ci};
49262306a36Sopenharmony_cistatic const char * const blsp_spi2_cs1_groups[] = { "gpio98" };
49362306a36Sopenharmony_cistatic const char * const blsp_spi2_cs2_groups[] = { "gpio17" };
49462306a36Sopenharmony_cistatic const char * const blsp_spi2_cs3_groups[] = { "gpio5" };
49562306a36Sopenharmony_cistatic const char * const blsp_spi2_groups[] = {
49662306a36Sopenharmony_ci	"gpio20", "gpio21", "gpio111", "gpio112"
49762306a36Sopenharmony_ci};
49862306a36Sopenharmony_cistatic const char * const blsp_spi3_cs1_groups[] = { "gpio95" };
49962306a36Sopenharmony_cistatic const char * const blsp_spi3_cs2_groups[] = { "gpio65" };
50062306a36Sopenharmony_cistatic const char * const blsp_spi3_cs3_groups[] = { "gpio4" };
50162306a36Sopenharmony_cistatic const char * const blsp_spi3_groups[] = {
50262306a36Sopenharmony_ci	"gpio0", "gpio1", "gpio2", "gpio3"
50362306a36Sopenharmony_ci};
50462306a36Sopenharmony_cistatic const char * const blsp_spi4_groups[] = {
50562306a36Sopenharmony_ci	"gpio12", "gpio13", "gpio14", "gpio15"
50662306a36Sopenharmony_ci};
50762306a36Sopenharmony_cistatic const char * const blsp_spi5_groups[] = {
50862306a36Sopenharmony_ci	"gpio16", "gpio17", "gpio18", "gpio19"
50962306a36Sopenharmony_ci};
51062306a36Sopenharmony_cistatic const char * const blsp_spi6_groups[] = {
51162306a36Sopenharmony_ci	"gpio8", "gpio9", "gpio10", "gpio11"
51262306a36Sopenharmony_ci};
51362306a36Sopenharmony_cistatic const char * const blsp_uart1_groups[] = {
51462306a36Sopenharmony_ci	"gpio4", "gpio5", "gpio6", "gpio7"
51562306a36Sopenharmony_ci};
51662306a36Sopenharmony_cistatic const char * const blsp_uart2_groups[] = {
51762306a36Sopenharmony_ci	"gpio20", "gpio21", "gpio111", "gpio112"
51862306a36Sopenharmony_ci};
51962306a36Sopenharmony_cistatic const char * const blsp_uim1_groups[] = { "gpio4", "gpio5" };
52062306a36Sopenharmony_cistatic const char * const blsp_uim2_groups[] = { "gpio20", "gpio21" };
52162306a36Sopenharmony_cistatic const char * const cam_mclk_groups[] = { "gpio26", "gpio27" };
52262306a36Sopenharmony_cistatic const char * const cci_async_groups[] = { "gpio33" };
52362306a36Sopenharmony_cistatic const char * const cci_timer0_groups[] = { "gpio31" };
52462306a36Sopenharmony_cistatic const char * const cci_timer1_groups[] = { "gpio32" };
52562306a36Sopenharmony_cistatic const char * const cci_timer2_groups[] = { "gpio38" };
52662306a36Sopenharmony_cistatic const char * const cdc_pdm0_groups[] = {
52762306a36Sopenharmony_ci	"gpio59", "gpio60", "gpio61", "gpio62", "gpio63", "gpio64"
52862306a36Sopenharmony_ci};
52962306a36Sopenharmony_cistatic const char * const dbg_out_groups[] = { "gpio10" };
53062306a36Sopenharmony_cistatic const char * const dmic0_clk_groups[] = { "gpio4" };
53162306a36Sopenharmony_cistatic const char * const dmic0_data_groups[] = { "gpio5" };
53262306a36Sopenharmony_cistatic const char * const ebi0_wrcdc_groups[] = { "gpio64" };
53362306a36Sopenharmony_cistatic const char * const ebi2_a_groups[] = { "gpio99" };
53462306a36Sopenharmony_cistatic const char * const ebi2_lcd_groups[] = {
53562306a36Sopenharmony_ci	"gpio24", "gpio24", "gpio25", "gpio95"
53662306a36Sopenharmony_ci};
53762306a36Sopenharmony_cistatic const char * const ext_lpass_groups[] = { "gpio45" };
53862306a36Sopenharmony_cistatic const char * const gcc_gp1_clk_a_groups[] = { "gpio49" };
53962306a36Sopenharmony_cistatic const char * const gcc_gp1_clk_b_groups[] = { "gpio14" };
54062306a36Sopenharmony_cistatic const char * const gcc_gp2_clk_a_groups[] = { "gpio50" };
54162306a36Sopenharmony_cistatic const char * const gcc_gp2_clk_b_groups[] = { "gpio12" };
54262306a36Sopenharmony_cistatic const char * const gcc_gp3_clk_a_groups[] = { "gpio51" };
54362306a36Sopenharmony_cistatic const char * const gcc_gp3_clk_b_groups[] = { "gpio13" };
54462306a36Sopenharmony_cistatic const char * const gcc_plltest_groups[] = { "gpio66", "gpio67" };
54562306a36Sopenharmony_cistatic const char * const gpio_groups[] = {
54662306a36Sopenharmony_ci	"gpio0", "gpio1", "gpio2", "gpio3", "gpio4", "gpio5", "gpio6", "gpio7",
54762306a36Sopenharmony_ci	"gpio8", "gpio9", "gpio10", "gpio11", "gpio12", "gpio13", "gpio14",
54862306a36Sopenharmony_ci	"gpio15", "gpio16", "gpio17", "gpio18", "gpio19", "gpio20", "gpio21",
54962306a36Sopenharmony_ci	"gpio22", "gpio23", "gpio24", "gpio25", "gpio26", "gpio27", "gpio28",
55062306a36Sopenharmony_ci	"gpio29", "gpio30", "gpio31", "gpio32", "gpio33", "gpio34", "gpio35",
55162306a36Sopenharmony_ci	"gpio36", "gpio37", "gpio38", "gpio39", "gpio40", "gpio41", "gpio42",
55262306a36Sopenharmony_ci	"gpio43", "gpio44", "gpio45", "gpio46", "gpio47", "gpio48", "gpio49",
55362306a36Sopenharmony_ci	"gpio50", "gpio51", "gpio52", "gpio53", "gpio54", "gpio55", "gpio56",
55462306a36Sopenharmony_ci	"gpio57", "gpio58", "gpio59", "gpio60", "gpio61", "gpio62", "gpio63",
55562306a36Sopenharmony_ci	"gpio64", "gpio65", "gpio66", "gpio67", "gpio68", "gpio69", "gpio70",
55662306a36Sopenharmony_ci	"gpio71", "gpio72", "gpio73", "gpio74", "gpio75", "gpio76", "gpio77",
55762306a36Sopenharmony_ci	"gpio78", "gpio79", "gpio80", "gpio81", "gpio82", "gpio83", "gpio84",
55862306a36Sopenharmony_ci	"gpio85", "gpio86", "gpio87", "gpio88", "gpio89", "gpio90", "gpio91",
55962306a36Sopenharmony_ci	"gpio92", "gpio93", "gpio94", "gpio95", "gpio96", "gpio97", "gpio98",
56062306a36Sopenharmony_ci	"gpio99", "gpio100", "gpio101", "gpio102", "gpio103", "gpio104",
56162306a36Sopenharmony_ci	"gpio105", "gpio106", "gpio107", "gpio108", "gpio109", "gpio110",
56262306a36Sopenharmony_ci	"gpio111", "gpio112"
56362306a36Sopenharmony_ci};
56462306a36Sopenharmony_cistatic const char * const gsm0_tx_groups[] = { "gpio85" };
56562306a36Sopenharmony_cistatic const char * const ldo_en_groups[] = { "gpio99" };
56662306a36Sopenharmony_cistatic const char * const ldo_update_groups[] = { "gpio98" };
56762306a36Sopenharmony_cistatic const char * const m_voc_groups[] = { "gpio8", "gpio95" };
56862306a36Sopenharmony_cistatic const char * const mdp_vsync_groups[] = { "gpio24", "gpio25" };
56962306a36Sopenharmony_cistatic const char * const modem_tsync_groups[] = { "gpio83" };
57062306a36Sopenharmony_cistatic const char * const nav_pps_groups[] = { "gpio83" };
57162306a36Sopenharmony_cistatic const char * const nav_tsync_groups[] = { "gpio83" };
57262306a36Sopenharmony_cistatic const char * const pa_indicator_groups[] = { "gpio82" };
57362306a36Sopenharmony_cistatic const char * const pbs0_groups[] = { "gpio90" };
57462306a36Sopenharmony_cistatic const char * const pbs1_groups[] = { "gpio91" };
57562306a36Sopenharmony_cistatic const char * const pbs2_groups[] = { "gpio92" };
57662306a36Sopenharmony_cistatic const char * const pri_mi2s_data0_a_groups[] = { "gpio62" };
57762306a36Sopenharmony_cistatic const char * const pri_mi2s_data0_b_groups[] = { "gpio95" };
57862306a36Sopenharmony_cistatic const char * const pri_mi2s_data1_a_groups[] = { "gpio63" };
57962306a36Sopenharmony_cistatic const char * const pri_mi2s_data1_b_groups[] = { "gpio96" };
58062306a36Sopenharmony_cistatic const char * const pri_mi2s_mclk_a_groups[] = { "gpio59" };
58162306a36Sopenharmony_cistatic const char * const pri_mi2s_mclk_b_groups[] = { "gpio98" };
58262306a36Sopenharmony_cistatic const char * const pri_mi2s_sck_a_groups[] = { "gpio60" };
58362306a36Sopenharmony_cistatic const char * const pri_mi2s_sck_b_groups[] = { "gpio94" };
58462306a36Sopenharmony_cistatic const char * const pri_mi2s_ws_a_groups[] = { "gpio61" };
58562306a36Sopenharmony_cistatic const char * const pri_mi2s_ws_b_groups[] = { "gpio110" };
58662306a36Sopenharmony_cistatic const char * const prng_rosc_groups[] = { "gpio43" };
58762306a36Sopenharmony_cistatic const char * const pwr_crypto_enabled_a_groups[] = { "gpio35" };
58862306a36Sopenharmony_cistatic const char * const pwr_crypto_enabled_b_groups[] = { "gpio96" };
58962306a36Sopenharmony_cistatic const char * const pwr_modem_enabled_a_groups[] = { "gpio28" };
59062306a36Sopenharmony_cistatic const char * const pwr_modem_enabled_b_groups[] = { "gpio94" };
59162306a36Sopenharmony_cistatic const char * const pwr_nav_enabled_a_groups[] = { "gpio34" };
59262306a36Sopenharmony_cistatic const char * const pwr_nav_enabled_b_groups[] = { "gpio95" };
59362306a36Sopenharmony_cistatic const char * const qdss_cti_trig_in_a0_groups[] = { "gpio20" };
59462306a36Sopenharmony_cistatic const char * const qdss_cti_trig_in_a1_groups[] = { "gpio49" };
59562306a36Sopenharmony_cistatic const char * const qdss_cti_trig_in_b0_groups[] = { "gpio21" };
59662306a36Sopenharmony_cistatic const char * const qdss_cti_trig_in_b1_groups[] = { "gpio50" };
59762306a36Sopenharmony_cistatic const char * const qdss_cti_trig_out_a0_groups[] = { "gpio23" };
59862306a36Sopenharmony_cistatic const char * const qdss_cti_trig_out_a1_groups[] = { "gpio52" };
59962306a36Sopenharmony_cistatic const char * const qdss_cti_trig_out_b0_groups[] = { "gpio22" };
60062306a36Sopenharmony_cistatic const char * const qdss_cti_trig_out_b1_groups[] = { "gpio51" };
60162306a36Sopenharmony_cistatic const char * const qdss_traceclk_a_groups[] = { "gpio46" };
60262306a36Sopenharmony_cistatic const char * const qdss_tracectl_a_groups[] = { "gpio45" };
60362306a36Sopenharmony_cistatic const char * const qdss_tracedata_a_groups[] = {
60462306a36Sopenharmony_ci	"gpio8", "gpio9", "gpio10", "gpio39", "gpio40", "gpio41", "gpio42",
60562306a36Sopenharmony_ci	"gpio43", "gpio47", "gpio48", "gpio58", "gpio65", "gpio94", "gpio96",
60662306a36Sopenharmony_ci	"gpio97"
60762306a36Sopenharmony_ci};
60862306a36Sopenharmony_cistatic const char * const qdss_tracedata_b_groups[] = {
60962306a36Sopenharmony_ci	"gpio14", "gpio16", "gpio17", "gpio29", "gpio30", "gpio31", "gpio32",
61062306a36Sopenharmony_ci	"gpio33", "gpio34", "gpio35", "gpio36", "gpio37", "gpio93"
61162306a36Sopenharmony_ci};
61262306a36Sopenharmony_cistatic const char * const sd_write_groups[] = { "gpio99" };
61362306a36Sopenharmony_cistatic const char * const sec_mi2s_groups[] = {
61462306a36Sopenharmony_ci	"gpio0", "gpio1", "gpio2", "gpio3", "gpio98"
61562306a36Sopenharmony_ci};
61662306a36Sopenharmony_cistatic const char * const smb_int_groups[] = { "gpio58" };
61762306a36Sopenharmony_cistatic const char * const ssbi0_groups[] = { "gpio88" };
61862306a36Sopenharmony_cistatic const char * const ssbi1_groups[] = { "gpio89" };
61962306a36Sopenharmony_cistatic const char * const uim1_clk_groups[] = { "gpio54" };
62062306a36Sopenharmony_cistatic const char * const uim1_data_groups[] = { "gpio53" };
62162306a36Sopenharmony_cistatic const char * const uim1_present_groups[] = { "gpio56" };
62262306a36Sopenharmony_cistatic const char * const uim1_reset_groups[] = { "gpio55" };
62362306a36Sopenharmony_cistatic const char * const uim2_clk_groups[] = { "gpio50" };
62462306a36Sopenharmony_cistatic const char * const uim2_data_groups[] = { "gpio49" };
62562306a36Sopenharmony_cistatic const char * const uim2_present_groups[] = { "gpio52" };
62662306a36Sopenharmony_cistatic const char * const uim2_reset_groups[] = { "gpio51" };
62762306a36Sopenharmony_cistatic const char * const uim3_clk_groups[] = { "gpio23" };
62862306a36Sopenharmony_cistatic const char * const uim3_data_groups[] = { "gpio20" };
62962306a36Sopenharmony_cistatic const char * const uim3_present_groups[] = { "gpio21" };
63062306a36Sopenharmony_cistatic const char * const uim3_reset_groups[] = { "gpio22" };
63162306a36Sopenharmony_cistatic const char * const uim_batt_groups[] = { "gpio57" };
63262306a36Sopenharmony_cistatic const char * const wcss_bt_groups[] = { "gpio39", "gpio47", "gpio48" };
63362306a36Sopenharmony_cistatic const char * const wcss_fm_groups[] = { "gpio45", "gpio46" };
63462306a36Sopenharmony_cistatic const char * const wcss_wlan_groups[] = {
63562306a36Sopenharmony_ci	"gpio40", "gpio41", "gpio42", "gpio43", "gpio44"
63662306a36Sopenharmony_ci};
63762306a36Sopenharmony_ci
63862306a36Sopenharmony_cistatic const struct pinfunction msm8909_functions[] = {
63962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(adsp_ext),
64062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_bbrx0),
64162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_bbrx1),
64262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_char),
64362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_char0),
64462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_char1),
64562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_char2),
64662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_char3),
64762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_combodac),
64862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_gpsadc0),
64962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_gpsadc1),
65062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_wlan0),
65162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(atest_wlan1),
65262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(bimc_dte0),
65362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(bimc_dte1),
65462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_i2c1),
65562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_i2c2),
65662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_i2c3),
65762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_i2c4),
65862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_i2c5),
65962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_i2c6),
66062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi1),
66162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi1_cs1),
66262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi1_cs2),
66362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi1_cs3),
66462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi2),
66562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi2_cs1),
66662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi2_cs2),
66762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi2_cs3),
66862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi3),
66962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi3_cs1),
67062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi3_cs2),
67162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi3_cs3),
67262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi4),
67362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi5),
67462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_spi6),
67562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_uart1),
67662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_uart2),
67762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_uim1),
67862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(blsp_uim2),
67962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(cam_mclk),
68062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(cci_async),
68162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(cci_timer0),
68262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(cci_timer1),
68362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(cci_timer2),
68462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(cdc_pdm0),
68562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(dbg_out),
68662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(dmic0_clk),
68762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(dmic0_data),
68862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(ebi0_wrcdc),
68962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(ebi2_a),
69062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(ebi2_lcd),
69162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(ext_lpass),
69262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(gcc_gp1_clk_a),
69362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(gcc_gp1_clk_b),
69462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(gcc_gp2_clk_a),
69562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(gcc_gp2_clk_b),
69662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(gcc_gp3_clk_a),
69762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(gcc_gp3_clk_b),
69862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(gcc_plltest),
69962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(gpio),
70062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(gsm0_tx),
70162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(ldo_en),
70262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(ldo_update),
70362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(m_voc),
70462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(mdp_vsync),
70562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(modem_tsync),
70662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(nav_pps),
70762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(nav_tsync),
70862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pa_indicator),
70962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pbs0),
71062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pbs1),
71162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pbs2),
71262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pri_mi2s_data0_a),
71362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pri_mi2s_data0_b),
71462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pri_mi2s_data1_a),
71562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pri_mi2s_data1_b),
71662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pri_mi2s_mclk_a),
71762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pri_mi2s_mclk_b),
71862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pri_mi2s_sck_a),
71962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pri_mi2s_sck_b),
72062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pri_mi2s_ws_a),
72162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pri_mi2s_ws_b),
72262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(prng_rosc),
72362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pwr_crypto_enabled_a),
72462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pwr_crypto_enabled_b),
72562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pwr_modem_enabled_a),
72662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pwr_modem_enabled_b),
72762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pwr_nav_enabled_a),
72862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(pwr_nav_enabled_b),
72962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_cti_trig_in_a0),
73062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_cti_trig_in_a1),
73162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_cti_trig_in_b0),
73262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_cti_trig_in_b1),
73362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_cti_trig_out_a0),
73462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_cti_trig_out_a1),
73562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_cti_trig_out_b0),
73662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_cti_trig_out_b1),
73762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_traceclk_a),
73862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_tracectl_a),
73962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_tracedata_a),
74062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(qdss_tracedata_b),
74162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(sd_write),
74262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(sec_mi2s),
74362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(smb_int),
74462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(ssbi0),
74562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(ssbi1),
74662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim1_clk),
74762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim1_data),
74862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim1_present),
74962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim1_reset),
75062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim2_clk),
75162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim2_data),
75262306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim2_present),
75362306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim2_reset),
75462306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim3_clk),
75562306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim3_data),
75662306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim3_present),
75762306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim3_reset),
75862306a36Sopenharmony_ci	MSM_PIN_FUNCTION(uim_batt),
75962306a36Sopenharmony_ci	MSM_PIN_FUNCTION(wcss_bt),
76062306a36Sopenharmony_ci	MSM_PIN_FUNCTION(wcss_fm),
76162306a36Sopenharmony_ci	MSM_PIN_FUNCTION(wcss_wlan),
76262306a36Sopenharmony_ci};
76362306a36Sopenharmony_ci
76462306a36Sopenharmony_cistatic const struct msm_pingroup msm8909_groups[] = {
76562306a36Sopenharmony_ci	PINGROUP(0, blsp_spi3, sec_mi2s, _, _, _, _, _, _, _),
76662306a36Sopenharmony_ci	PINGROUP(1, blsp_spi3, sec_mi2s, _, _, _, _, _, _, _),
76762306a36Sopenharmony_ci	PINGROUP(2, blsp_spi3, sec_mi2s, _, _, _, _, _, _, _),
76862306a36Sopenharmony_ci	PINGROUP(3, blsp_spi3, sec_mi2s, _, _, _, _, _, _, _),
76962306a36Sopenharmony_ci	PINGROUP(4, blsp_spi1, blsp_uart1, blsp_uim1, blsp_spi3_cs3, dmic0_clk, _, _, _, _),
77062306a36Sopenharmony_ci	PINGROUP(5, blsp_spi1, blsp_uart1, blsp_uim1, blsp_spi2_cs3, dmic0_data, _, _, _, _),
77162306a36Sopenharmony_ci	PINGROUP(6, blsp_spi1, blsp_uart1, blsp_i2c1, _, _, _, _, _, bimc_dte0),
77262306a36Sopenharmony_ci	PINGROUP(7, blsp_spi1, blsp_uart1, blsp_i2c1, _, _, _, _, _, bimc_dte1),
77362306a36Sopenharmony_ci	PINGROUP(8, blsp_spi6, m_voc, _, _, _, _, _, qdss_tracedata_a, _),
77462306a36Sopenharmony_ci	PINGROUP(9, blsp_spi6, _, _, _, _, _, qdss_tracedata_a, _, _),
77562306a36Sopenharmony_ci	PINGROUP(10, blsp_spi6, blsp_i2c6, dbg_out, qdss_tracedata_a, _, _, _, _, _),
77662306a36Sopenharmony_ci	PINGROUP(11, blsp_spi6, blsp_i2c6, _, _, _, _, _, _, _),
77762306a36Sopenharmony_ci	PINGROUP(12, blsp_spi4, gcc_gp2_clk_b, _, _, _, _, _, _, _),
77862306a36Sopenharmony_ci	PINGROUP(13, blsp_spi4, gcc_gp3_clk_b, _, _, _, _, _, _, _),
77962306a36Sopenharmony_ci	PINGROUP(14, blsp_spi4, blsp_i2c4, gcc_gp1_clk_b, _, _, _, _, _, qdss_tracedata_b),
78062306a36Sopenharmony_ci	PINGROUP(15, blsp_spi4, blsp_i2c4, _, _, _, _, _, _, _),
78162306a36Sopenharmony_ci	PINGROUP(16, blsp_spi5, _, _, _, _, _, qdss_tracedata_b, _, _),
78262306a36Sopenharmony_ci	PINGROUP(17, blsp_spi5, blsp_spi2_cs2, _, _, _, _, _, qdss_tracedata_b, _),
78362306a36Sopenharmony_ci	PINGROUP(18, blsp_spi5, blsp_i2c5, _, _, _, _, _, _, _),
78462306a36Sopenharmony_ci	PINGROUP(19, blsp_spi5, blsp_i2c5, _, _, _, _, _, _, _),
78562306a36Sopenharmony_ci	PINGROUP(20, uim3_data, blsp_spi2, blsp_uart2, blsp_uim2, _, qdss_cti_trig_in_a0, _, _, _),
78662306a36Sopenharmony_ci	PINGROUP(21, uim3_present, blsp_spi2, blsp_uart2, blsp_uim2, _, qdss_cti_trig_in_b0, _, _, _),
78762306a36Sopenharmony_ci	PINGROUP(22, uim3_reset, _, qdss_cti_trig_out_b0, _, _, _, _, _, _),
78862306a36Sopenharmony_ci	PINGROUP(23, uim3_clk, qdss_cti_trig_out_a0, _, _, _, _, _, _, _),
78962306a36Sopenharmony_ci	PINGROUP(24, mdp_vsync, ebi2_lcd, ebi2_lcd, _, _, _, _, _, _),
79062306a36Sopenharmony_ci	PINGROUP(25, mdp_vsync, ebi2_lcd, _, _, _, _, _, _, _),
79162306a36Sopenharmony_ci	PINGROUP(26, cam_mclk, _, _, _, _, _, _, _, _),
79262306a36Sopenharmony_ci	PINGROUP(27, cam_mclk, _, _, _, _, _, _, _, _),
79362306a36Sopenharmony_ci	PINGROUP(28, _, pwr_modem_enabled_a, _, _, _, _, _, _, _),
79462306a36Sopenharmony_ci	PINGROUP(29, blsp_i2c3, _, _, _, _, _, qdss_tracedata_b, _, _),
79562306a36Sopenharmony_ci	PINGROUP(30, blsp_i2c3, _, _, _, _, _, qdss_tracedata_b, _, _),
79662306a36Sopenharmony_ci	PINGROUP(31, cci_timer0, _, _, _, _, _, _, qdss_tracedata_b, _),
79762306a36Sopenharmony_ci	PINGROUP(32, cci_timer1, _, qdss_tracedata_b, _, atest_combodac, _, _, _, _),
79862306a36Sopenharmony_ci	PINGROUP(33, cci_async, qdss_tracedata_b, _, _, _, _, _, _, _),
79962306a36Sopenharmony_ci	PINGROUP(34, pwr_nav_enabled_a, qdss_tracedata_b, _, _, _, _, _, _, _),
80062306a36Sopenharmony_ci	PINGROUP(35, pwr_crypto_enabled_a, qdss_tracedata_b, _, _, _, _, _, _, _),
80162306a36Sopenharmony_ci	PINGROUP(36, qdss_tracedata_b, _, atest_bbrx1, _, _, _, _, _, _),
80262306a36Sopenharmony_ci	PINGROUP(37, blsp_spi1_cs2, qdss_tracedata_b, _, atest_bbrx0, _, _, _, _, _),
80362306a36Sopenharmony_ci	PINGROUP(38, cci_timer2, adsp_ext, _, atest_combodac, _, _, _, _, _),
80462306a36Sopenharmony_ci	PINGROUP(39, wcss_bt, qdss_tracedata_a, _, atest_combodac, _, _, _, _, _),
80562306a36Sopenharmony_ci	PINGROUP(40, wcss_wlan, qdss_tracedata_a, _, atest_combodac, _, _, _, _, _),
80662306a36Sopenharmony_ci	PINGROUP(41, wcss_wlan, qdss_tracedata_a, _, atest_combodac, _, _, _, _, _),
80762306a36Sopenharmony_ci	PINGROUP(42, wcss_wlan, qdss_tracedata_a, _, atest_combodac, _, _, _, _, _),
80862306a36Sopenharmony_ci	PINGROUP(43, wcss_wlan, prng_rosc, qdss_tracedata_a, _, atest_combodac, _, _, _, _),
80962306a36Sopenharmony_ci	PINGROUP(44, wcss_wlan, _, atest_combodac, _, _, _, _, _, _),
81062306a36Sopenharmony_ci	PINGROUP(45, wcss_fm, ext_lpass, qdss_tracectl_a, _, atest_combodac, _, _, _, _),
81162306a36Sopenharmony_ci	PINGROUP(46, wcss_fm, qdss_traceclk_a, _, _, _, _, _, _, _),
81262306a36Sopenharmony_ci	PINGROUP(47, wcss_bt, qdss_tracedata_a, _, atest_combodac, _, _, _, _, _),
81362306a36Sopenharmony_ci	PINGROUP(48, wcss_bt, qdss_tracedata_a, _, atest_combodac, _, _, _, _, _),
81462306a36Sopenharmony_ci	PINGROUP(49, uim2_data, gcc_gp1_clk_a, qdss_cti_trig_in_a1, _, _, _, _, _, _),
81562306a36Sopenharmony_ci	PINGROUP(50, uim2_clk, gcc_gp2_clk_a, qdss_cti_trig_in_b1, _, _, _, _, _, _),
81662306a36Sopenharmony_ci	PINGROUP(51, uim2_reset, gcc_gp3_clk_a, qdss_cti_trig_out_b1, _, _, _, _, _, _),
81762306a36Sopenharmony_ci	PINGROUP(52, uim2_present, qdss_cti_trig_out_a1, _, _, _, _, _, _, _),
81862306a36Sopenharmony_ci	PINGROUP(53, uim1_data, _, _, _, _, _, _, _, _),
81962306a36Sopenharmony_ci	PINGROUP(54, uim1_clk, _, _, _, _, _, _, _, _),
82062306a36Sopenharmony_ci	PINGROUP(55, uim1_reset, _, _, _, _, _, _, _, _),
82162306a36Sopenharmony_ci	PINGROUP(56, uim1_present, _, _, _, _, _, _, _, _),
82262306a36Sopenharmony_ci	PINGROUP(57, uim_batt, _, _, _, _, _, _, _, _),
82362306a36Sopenharmony_ci	PINGROUP(58, qdss_tracedata_a, smb_int, _, _, _, _, _, _, _),
82462306a36Sopenharmony_ci	PINGROUP(59, cdc_pdm0, pri_mi2s_mclk_a, atest_char3, _, _, _, _, _, bimc_dte0),
82562306a36Sopenharmony_ci	PINGROUP(60, cdc_pdm0, pri_mi2s_sck_a, atest_char2, _, _, _, _, _, bimc_dte1),
82662306a36Sopenharmony_ci	PINGROUP(61, cdc_pdm0, pri_mi2s_ws_a, atest_char1, _, _, _, _, _, _),
82762306a36Sopenharmony_ci	PINGROUP(62, cdc_pdm0, pri_mi2s_data0_a, atest_char0, _, _, _, _, _, _),
82862306a36Sopenharmony_ci	PINGROUP(63, cdc_pdm0, pri_mi2s_data1_a, atest_char, _, _, _, _, _, _),
82962306a36Sopenharmony_ci	PINGROUP(64, cdc_pdm0, _, _, _, _, _, ebi0_wrcdc, _, _),
83062306a36Sopenharmony_ci	PINGROUP(65, blsp_spi3_cs2, blsp_spi1_cs3, qdss_tracedata_a, _, atest_gpsadc0, _, _, _, _),
83162306a36Sopenharmony_ci	PINGROUP(66, _, gcc_plltest, _, atest_combodac, _, _, _, _, _),
83262306a36Sopenharmony_ci	PINGROUP(67, _, gcc_plltest, _, _, _, _, _, _, _),
83362306a36Sopenharmony_ci	PINGROUP(68, _, _, _, _, _, _, _, _, _),
83462306a36Sopenharmony_ci	PINGROUP(69, _, _, _, _, _, _, _, _, _),
83562306a36Sopenharmony_ci	PINGROUP(70, _, _, _, _, _, _, _, _, _),
83662306a36Sopenharmony_ci	PINGROUP(71, _, _, _, _, _, _, _, _, _),
83762306a36Sopenharmony_ci	PINGROUP(72, _, _, _, _, _, _, _, _, _),
83862306a36Sopenharmony_ci	PINGROUP(73, _, _, _, _, _, _, _, _, _),
83962306a36Sopenharmony_ci	PINGROUP(74, _, _, _, _, _, _, _, _, _),
84062306a36Sopenharmony_ci	PINGROUP(75, _, _, _, _, _, _, _, _, _),
84162306a36Sopenharmony_ci	PINGROUP(76, _, _, _, _, _, _, _, _, _),
84262306a36Sopenharmony_ci	PINGROUP(77, _, _, _, _, _, _, _, _, _),
84362306a36Sopenharmony_ci	PINGROUP(78, _, _, _, _, _, _, _, _, _),
84462306a36Sopenharmony_ci	PINGROUP(79, _, _, atest_gpsadc1, _, _, _, _, _, _),
84562306a36Sopenharmony_ci	PINGROUP(80, _, _, _, _, _, _, _, _, _),
84662306a36Sopenharmony_ci	PINGROUP(81, _, _, _, atest_combodac, _, _, _, _, _),
84762306a36Sopenharmony_ci	PINGROUP(82, _, pa_indicator, _, _, _, _, _, _, _),
84862306a36Sopenharmony_ci	PINGROUP(83, _, modem_tsync, nav_tsync, nav_pps, _, atest_combodac, _, _, _),
84962306a36Sopenharmony_ci	PINGROUP(84, _, _, atest_combodac, _, _, _, _, _, _),
85062306a36Sopenharmony_ci	PINGROUP(85, gsm0_tx, _, _, atest_combodac, _, _, _, _, _),
85162306a36Sopenharmony_ci	PINGROUP(86, _, _, atest_combodac, _, _, _, _, _, _),
85262306a36Sopenharmony_ci	PINGROUP(87, _, _, _, _, _, _, _, _, _),
85362306a36Sopenharmony_ci	PINGROUP(88, _, ssbi0, _, _, _, _, _, _, _),
85462306a36Sopenharmony_ci	PINGROUP(89, _, ssbi1, _, _, _, _, _, _, _),
85562306a36Sopenharmony_ci	PINGROUP(90, pbs0, _, _, _, _, _, _, _, _),
85662306a36Sopenharmony_ci	PINGROUP(91, pbs1, _, _, _, _, _, _, _, _),
85762306a36Sopenharmony_ci	PINGROUP(92, pbs2, _, _, _, _, _, _, _, _),
85862306a36Sopenharmony_ci	PINGROUP(93, qdss_tracedata_b, _, _, _, _, _, _, _, _),
85962306a36Sopenharmony_ci	PINGROUP(94, pri_mi2s_sck_b, pwr_modem_enabled_b, qdss_tracedata_a, _, atest_combodac, _, _, _, _),
86062306a36Sopenharmony_ci	PINGROUP(95, blsp_spi3_cs1, pri_mi2s_data0_b, ebi2_lcd, m_voc, pwr_nav_enabled_b, _, atest_combodac, _, _),
86162306a36Sopenharmony_ci	PINGROUP(96, pri_mi2s_data1_b, _, pwr_crypto_enabled_b, qdss_tracedata_a, _, atest_wlan0, _, _, _),
86262306a36Sopenharmony_ci	PINGROUP(97, blsp_spi1_cs1, qdss_tracedata_a, _, atest_wlan1, _, _, _, _, _),
86362306a36Sopenharmony_ci	PINGROUP(98, sec_mi2s, pri_mi2s_mclk_b, blsp_spi2_cs1, ldo_update, _, _, _, _, _),
86462306a36Sopenharmony_ci	PINGROUP(99, ebi2_a, sd_write, ldo_en, _, _, _, _, _, _),
86562306a36Sopenharmony_ci	PINGROUP(100, _, _, _, _, _, _, _, _, _),
86662306a36Sopenharmony_ci	PINGROUP(101, _, _, _, _, _, _, _, _, _),
86762306a36Sopenharmony_ci	PINGROUP(102, _, _, _, _, _, _, _, _, _),
86862306a36Sopenharmony_ci	PINGROUP(103, _, _, _, _, _, _, _, _, _),
86962306a36Sopenharmony_ci	PINGROUP(104, _, _, _, _, _, _, _, _, _),
87062306a36Sopenharmony_ci	PINGROUP(105, _, _, _, _, _, _, _, _, _),
87162306a36Sopenharmony_ci	PINGROUP(106, _, _, _, _, _, _, _, _, _),
87262306a36Sopenharmony_ci	PINGROUP(107, _, _, _, _, _, _, _, _, _),
87362306a36Sopenharmony_ci	PINGROUP(108, _, _, _, _, _, _, _, _, _),
87462306a36Sopenharmony_ci	PINGROUP(109, _, _, _, _, _, _, _, _, _),
87562306a36Sopenharmony_ci	PINGROUP(110, pri_mi2s_ws_b, _, atest_combodac, _, _, _, _, _, _),
87662306a36Sopenharmony_ci	PINGROUP(111, blsp_spi2, blsp_uart2, blsp_i2c2, _, _, _, _, _, _),
87762306a36Sopenharmony_ci	PINGROUP(112, blsp_spi2, blsp_uart2, blsp_i2c2, _, _, _, _, _, _),
87862306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(sdc1_clk, 0x10a000, 13, 6),
87962306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(sdc1_cmd, 0x10a000, 11, 3),
88062306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(sdc1_data, 0x10a000, 9, 0),
88162306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(sdc2_clk, 0x109000, 14, 6),
88262306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(sdc2_cmd, 0x109000, 11, 3),
88362306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(sdc2_data, 0x109000, 9, 0),
88462306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(qdsd_clk, 0x19c000, 3, 0),
88562306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(qdsd_cmd, 0x19c000, 8, 5),
88662306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(qdsd_data0, 0x19c000, 13, 10),
88762306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(qdsd_data1, 0x19c000, 18, 15),
88862306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(qdsd_data2, 0x19c000, 23, 20),
88962306a36Sopenharmony_ci	SDC_QDSD_PINGROUP(qdsd_data3, 0x19c000, 28, 25),
89062306a36Sopenharmony_ci};
89162306a36Sopenharmony_ci
89262306a36Sopenharmony_cistatic const struct msm_gpio_wakeirq_map msm8909_mpm_map[] = {
89362306a36Sopenharmony_ci	{ 65, 3 }, { 5, 4 }, { 11, 5 }, { 12, 6 }, { 64, 7 }, { 58, 8 },
89462306a36Sopenharmony_ci	{ 50, 9 }, { 13, 10 }, { 49, 11 }, { 20, 12 }, { 21, 13 }, { 25, 14 },
89562306a36Sopenharmony_ci	{ 46, 15 }, { 45, 16 }, { 28, 17 }, { 44, 18 }, { 31, 19 }, { 43, 20 },
89662306a36Sopenharmony_ci	{ 42, 21 }, { 34, 22 }, { 35, 23 }, { 36, 24 }, { 37, 25 }, { 38, 26 },
89762306a36Sopenharmony_ci	{ 39, 27 }, { 40, 28 }, { 41, 29 }, { 90, 30 }, { 91, 32 }, { 92, 33 },
89862306a36Sopenharmony_ci	{ 94, 34 }, { 95, 35 }, { 96, 36 }, { 97, 37 }, { 98, 38 },
89962306a36Sopenharmony_ci	{ 110, 39 }, { 111, 40 }, { 112, 41 }, { 105, 42 }, { 107, 43 },
90062306a36Sopenharmony_ci	{ 47, 50 }, { 48, 51 },
90162306a36Sopenharmony_ci};
90262306a36Sopenharmony_ci
90362306a36Sopenharmony_cistatic const struct msm_pinctrl_soc_data msm8909_pinctrl = {
90462306a36Sopenharmony_ci	.pins = msm8909_pins,
90562306a36Sopenharmony_ci	.npins = ARRAY_SIZE(msm8909_pins),
90662306a36Sopenharmony_ci	.functions = msm8909_functions,
90762306a36Sopenharmony_ci	.nfunctions = ARRAY_SIZE(msm8909_functions),
90862306a36Sopenharmony_ci	.groups = msm8909_groups,
90962306a36Sopenharmony_ci	.ngroups = ARRAY_SIZE(msm8909_groups),
91062306a36Sopenharmony_ci	.ngpios = 113,
91162306a36Sopenharmony_ci	.wakeirq_map = msm8909_mpm_map,
91262306a36Sopenharmony_ci	.nwakeirq_map = ARRAY_SIZE(msm8909_mpm_map),
91362306a36Sopenharmony_ci};
91462306a36Sopenharmony_ci
91562306a36Sopenharmony_cistatic int msm8909_pinctrl_probe(struct platform_device *pdev)
91662306a36Sopenharmony_ci{
91762306a36Sopenharmony_ci	return msm_pinctrl_probe(pdev, &msm8909_pinctrl);
91862306a36Sopenharmony_ci}
91962306a36Sopenharmony_ci
92062306a36Sopenharmony_cistatic const struct of_device_id msm8909_pinctrl_of_match[] = {
92162306a36Sopenharmony_ci	{ .compatible = "qcom,msm8909-tlmm", },
92262306a36Sopenharmony_ci	{ },
92362306a36Sopenharmony_ci};
92462306a36Sopenharmony_ciMODULE_DEVICE_TABLE(of, msm8909_pinctrl_of_match);
92562306a36Sopenharmony_ci
92662306a36Sopenharmony_cistatic struct platform_driver msm8909_pinctrl_driver = {
92762306a36Sopenharmony_ci	.driver = {
92862306a36Sopenharmony_ci		.name = "msm8909-pinctrl",
92962306a36Sopenharmony_ci		.of_match_table = msm8909_pinctrl_of_match,
93062306a36Sopenharmony_ci	},
93162306a36Sopenharmony_ci	.probe = msm8909_pinctrl_probe,
93262306a36Sopenharmony_ci	.remove = msm_pinctrl_remove,
93362306a36Sopenharmony_ci};
93462306a36Sopenharmony_ci
93562306a36Sopenharmony_cistatic int __init msm8909_pinctrl_init(void)
93662306a36Sopenharmony_ci{
93762306a36Sopenharmony_ci	return platform_driver_register(&msm8909_pinctrl_driver);
93862306a36Sopenharmony_ci}
93962306a36Sopenharmony_ciarch_initcall(msm8909_pinctrl_init);
94062306a36Sopenharmony_ci
94162306a36Sopenharmony_cistatic void __exit msm8909_pinctrl_exit(void)
94262306a36Sopenharmony_ci{
94362306a36Sopenharmony_ci	platform_driver_unregister(&msm8909_pinctrl_driver);
94462306a36Sopenharmony_ci}
94562306a36Sopenharmony_cimodule_exit(msm8909_pinctrl_exit);
94662306a36Sopenharmony_ci
94762306a36Sopenharmony_ciMODULE_DESCRIPTION("Qualcomm MSM8909 TLMM pinctrl driver");
94862306a36Sopenharmony_ciMODULE_LICENSE("GPL");
949