pinctrl-msm8994.c 42 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363
  1. // SPDX-License-Identifier: GPL-2.0-only
  2. /*
  3. * Copyright (c) 2016, The Linux Foundation. All rights reserved.
  4. */
  5. #include <linux/module.h>
  6. #include <linux/of.h>
  7. #include <linux/platform_device.h>
  8. #include "pinctrl-msm.h"
  9. #define PINGROUP(id, f1, f2, f3, f4, f5, f6, f7, f8, f9, f10, f11) \
  10. { \
  11. .grp = PINCTRL_PINGROUP("gpio" #id, \
  12. gpio##id##_pins, \
  13. ARRAY_SIZE(gpio##id##_pins)), \
  14. .funcs = (int[]){ \
  15. msm_mux_gpio, \
  16. msm_mux_##f1, \
  17. msm_mux_##f2, \
  18. msm_mux_##f3, \
  19. msm_mux_##f4, \
  20. msm_mux_##f5, \
  21. msm_mux_##f6, \
  22. msm_mux_##f7, \
  23. msm_mux_##f8, \
  24. msm_mux_##f9, \
  25. msm_mux_##f10, \
  26. msm_mux_##f11 \
  27. }, \
  28. .nfuncs = 12, \
  29. .ctl_reg = 0x1000 + 0x10 * id, \
  30. .io_reg = 0x1004 + 0x10 * id, \
  31. .intr_cfg_reg = 0x1008 + 0x10 * id, \
  32. .intr_status_reg = 0x100c + 0x10 * id, \
  33. .intr_target_reg = 0x1008 + 0x10 * id, \
  34. .mux_bit = 2, \
  35. .pull_bit = 0, \
  36. .drv_bit = 6, \
  37. .oe_bit = 9, \
  38. .in_bit = 0, \
  39. .out_bit = 1, \
  40. .intr_enable_bit = 0, \
  41. .intr_status_bit = 0, \
  42. .intr_target_bit = 5, \
  43. .intr_target_kpss_val = 4, \
  44. .intr_raw_status_bit = 4, \
  45. .intr_polarity_bit = 1, \
  46. .intr_detection_bit = 2, \
  47. .intr_detection_width = 2, \
  48. }
  49. #define SDC_PINGROUP(pg_name, ctl, pull, drv) \
  50. { \
  51. .grp = PINCTRL_PINGROUP(#pg_name, \
  52. pg_name##_pins, \
  53. ARRAY_SIZE(pg_name##_pins)), \
  54. .ctl_reg = ctl, \
  55. .io_reg = 0, \
  56. .intr_cfg_reg = 0, \
  57. .intr_status_reg = 0, \
  58. .intr_target_reg = 0, \
  59. .mux_bit = -1, \
  60. .pull_bit = pull, \
  61. .drv_bit = drv, \
  62. .oe_bit = -1, \
  63. .in_bit = -1, \
  64. .out_bit = -1, \
  65. .intr_enable_bit = -1, \
  66. .intr_status_bit = -1, \
  67. .intr_target_bit = -1, \
  68. .intr_target_kpss_val = -1, \
  69. .intr_raw_status_bit = -1, \
  70. .intr_polarity_bit = -1, \
  71. .intr_detection_bit = -1, \
  72. .intr_detection_width = -1, \
  73. }
  74. static const struct pinctrl_pin_desc msm8994_pins[] = {
  75. PINCTRL_PIN(0, "GPIO_0"),
  76. PINCTRL_PIN(1, "GPIO_1"),
  77. PINCTRL_PIN(2, "GPIO_2"),
  78. PINCTRL_PIN(3, "GPIO_3"),
  79. PINCTRL_PIN(4, "GPIO_4"),
  80. PINCTRL_PIN(5, "GPIO_5"),
  81. PINCTRL_PIN(6, "GPIO_6"),
  82. PINCTRL_PIN(7, "GPIO_7"),
  83. PINCTRL_PIN(8, "GPIO_8"),
  84. PINCTRL_PIN(9, "GPIO_9"),
  85. PINCTRL_PIN(10, "GPIO_10"),
  86. PINCTRL_PIN(11, "GPIO_11"),
  87. PINCTRL_PIN(12, "GPIO_12"),
  88. PINCTRL_PIN(13, "GPIO_13"),
  89. PINCTRL_PIN(14, "GPIO_14"),
  90. PINCTRL_PIN(15, "GPIO_15"),
  91. PINCTRL_PIN(16, "GPIO_16"),
  92. PINCTRL_PIN(17, "GPIO_17"),
  93. PINCTRL_PIN(18, "GPIO_18"),
  94. PINCTRL_PIN(19, "GPIO_19"),
  95. PINCTRL_PIN(20, "GPIO_20"),
  96. PINCTRL_PIN(21, "GPIO_21"),
  97. PINCTRL_PIN(22, "GPIO_22"),
  98. PINCTRL_PIN(23, "GPIO_23"),
  99. PINCTRL_PIN(24, "GPIO_24"),
  100. PINCTRL_PIN(25, "GPIO_25"),
  101. PINCTRL_PIN(26, "GPIO_26"),
  102. PINCTRL_PIN(27, "GPIO_27"),
  103. PINCTRL_PIN(28, "GPIO_28"),
  104. PINCTRL_PIN(29, "GPIO_29"),
  105. PINCTRL_PIN(30, "GPIO_30"),
  106. PINCTRL_PIN(31, "GPIO_31"),
  107. PINCTRL_PIN(32, "GPIO_32"),
  108. PINCTRL_PIN(33, "GPIO_33"),
  109. PINCTRL_PIN(34, "GPIO_34"),
  110. PINCTRL_PIN(35, "GPIO_35"),
  111. PINCTRL_PIN(36, "GPIO_36"),
  112. PINCTRL_PIN(37, "GPIO_37"),
  113. PINCTRL_PIN(38, "GPIO_38"),
  114. PINCTRL_PIN(39, "GPIO_39"),
  115. PINCTRL_PIN(40, "GPIO_40"),
  116. PINCTRL_PIN(41, "GPIO_41"),
  117. PINCTRL_PIN(42, "GPIO_42"),
  118. PINCTRL_PIN(43, "GPIO_43"),
  119. PINCTRL_PIN(44, "GPIO_44"),
  120. PINCTRL_PIN(45, "GPIO_45"),
  121. PINCTRL_PIN(46, "GPIO_46"),
  122. PINCTRL_PIN(47, "GPIO_47"),
  123. PINCTRL_PIN(48, "GPIO_48"),
  124. PINCTRL_PIN(49, "GPIO_49"),
  125. PINCTRL_PIN(50, "GPIO_50"),
  126. PINCTRL_PIN(51, "GPIO_51"),
  127. PINCTRL_PIN(52, "GPIO_52"),
  128. PINCTRL_PIN(53, "GPIO_53"),
  129. PINCTRL_PIN(54, "GPIO_54"),
  130. PINCTRL_PIN(55, "GPIO_55"),
  131. PINCTRL_PIN(56, "GPIO_56"),
  132. PINCTRL_PIN(57, "GPIO_57"),
  133. PINCTRL_PIN(58, "GPIO_58"),
  134. PINCTRL_PIN(59, "GPIO_59"),
  135. PINCTRL_PIN(60, "GPIO_60"),
  136. PINCTRL_PIN(61, "GPIO_61"),
  137. PINCTRL_PIN(62, "GPIO_62"),
  138. PINCTRL_PIN(63, "GPIO_63"),
  139. PINCTRL_PIN(64, "GPIO_64"),
  140. PINCTRL_PIN(65, "GPIO_65"),
  141. PINCTRL_PIN(66, "GPIO_66"),
  142. PINCTRL_PIN(67, "GPIO_67"),
  143. PINCTRL_PIN(68, "GPIO_68"),
  144. PINCTRL_PIN(69, "GPIO_69"),
  145. PINCTRL_PIN(70, "GPIO_70"),
  146. PINCTRL_PIN(71, "GPIO_71"),
  147. PINCTRL_PIN(72, "GPIO_72"),
  148. PINCTRL_PIN(73, "GPIO_73"),
  149. PINCTRL_PIN(74, "GPIO_74"),
  150. PINCTRL_PIN(75, "GPIO_75"),
  151. PINCTRL_PIN(76, "GPIO_76"),
  152. PINCTRL_PIN(77, "GPIO_77"),
  153. PINCTRL_PIN(78, "GPIO_78"),
  154. PINCTRL_PIN(79, "GPIO_79"),
  155. PINCTRL_PIN(80, "GPIO_80"),
  156. PINCTRL_PIN(81, "GPIO_81"),
  157. PINCTRL_PIN(82, "GPIO_82"),
  158. PINCTRL_PIN(83, "GPIO_83"),
  159. PINCTRL_PIN(84, "GPIO_84"),
  160. PINCTRL_PIN(85, "GPIO_85"),
  161. PINCTRL_PIN(86, "GPIO_86"),
  162. PINCTRL_PIN(87, "GPIO_87"),
  163. PINCTRL_PIN(88, "GPIO_88"),
  164. PINCTRL_PIN(89, "GPIO_89"),
  165. PINCTRL_PIN(90, "GPIO_90"),
  166. PINCTRL_PIN(91, "GPIO_91"),
  167. PINCTRL_PIN(92, "GPIO_92"),
  168. PINCTRL_PIN(93, "GPIO_93"),
  169. PINCTRL_PIN(94, "GPIO_94"),
  170. PINCTRL_PIN(95, "GPIO_95"),
  171. PINCTRL_PIN(96, "GPIO_96"),
  172. PINCTRL_PIN(97, "GPIO_97"),
  173. PINCTRL_PIN(98, "GPIO_98"),
  174. PINCTRL_PIN(99, "GPIO_99"),
  175. PINCTRL_PIN(100, "GPIO_100"),
  176. PINCTRL_PIN(101, "GPIO_101"),
  177. PINCTRL_PIN(102, "GPIO_102"),
  178. PINCTRL_PIN(103, "GPIO_103"),
  179. PINCTRL_PIN(104, "GPIO_104"),
  180. PINCTRL_PIN(105, "GPIO_105"),
  181. PINCTRL_PIN(106, "GPIO_106"),
  182. PINCTRL_PIN(107, "GPIO_107"),
  183. PINCTRL_PIN(108, "GPIO_108"),
  184. PINCTRL_PIN(109, "GPIO_109"),
  185. PINCTRL_PIN(110, "GPIO_110"),
  186. PINCTRL_PIN(111, "GPIO_111"),
  187. PINCTRL_PIN(112, "GPIO_112"),
  188. PINCTRL_PIN(113, "GPIO_113"),
  189. PINCTRL_PIN(114, "GPIO_114"),
  190. PINCTRL_PIN(115, "GPIO_115"),
  191. PINCTRL_PIN(116, "GPIO_116"),
  192. PINCTRL_PIN(117, "GPIO_117"),
  193. PINCTRL_PIN(118, "GPIO_118"),
  194. PINCTRL_PIN(119, "GPIO_119"),
  195. PINCTRL_PIN(120, "GPIO_120"),
  196. PINCTRL_PIN(121, "GPIO_121"),
  197. PINCTRL_PIN(122, "GPIO_122"),
  198. PINCTRL_PIN(123, "GPIO_123"),
  199. PINCTRL_PIN(124, "GPIO_124"),
  200. PINCTRL_PIN(125, "GPIO_125"),
  201. PINCTRL_PIN(126, "GPIO_126"),
  202. PINCTRL_PIN(127, "GPIO_127"),
  203. PINCTRL_PIN(128, "GPIO_128"),
  204. PINCTRL_PIN(129, "GPIO_129"),
  205. PINCTRL_PIN(130, "GPIO_130"),
  206. PINCTRL_PIN(131, "GPIO_131"),
  207. PINCTRL_PIN(132, "GPIO_132"),
  208. PINCTRL_PIN(133, "GPIO_133"),
  209. PINCTRL_PIN(134, "GPIO_134"),
  210. PINCTRL_PIN(135, "GPIO_135"),
  211. PINCTRL_PIN(136, "GPIO_136"),
  212. PINCTRL_PIN(137, "GPIO_137"),
  213. PINCTRL_PIN(138, "GPIO_138"),
  214. PINCTRL_PIN(139, "GPIO_139"),
  215. PINCTRL_PIN(140, "GPIO_140"),
  216. PINCTRL_PIN(141, "GPIO_141"),
  217. PINCTRL_PIN(142, "GPIO_142"),
  218. PINCTRL_PIN(143, "GPIO_143"),
  219. PINCTRL_PIN(144, "GPIO_144"),
  220. PINCTRL_PIN(145, "GPIO_145"),
  221. PINCTRL_PIN(146, "SDC1_RCLK"),
  222. PINCTRL_PIN(147, "SDC1_CLK"),
  223. PINCTRL_PIN(148, "SDC1_CMD"),
  224. PINCTRL_PIN(149, "SDC1_DATA"),
  225. PINCTRL_PIN(150, "SDC2_CLK"),
  226. PINCTRL_PIN(151, "SDC2_CMD"),
  227. PINCTRL_PIN(152, "SDC2_DATA"),
  228. PINCTRL_PIN(153, "SDC3_CLK"),
  229. PINCTRL_PIN(154, "SDC3_CMD"),
  230. PINCTRL_PIN(155, "SDC3_DATA"),
  231. };
  232. #define DECLARE_MSM_GPIO_PINS(pin) \
  233. static const unsigned int gpio##pin##_pins[] = { pin }
  234. DECLARE_MSM_GPIO_PINS(0);
  235. DECLARE_MSM_GPIO_PINS(1);
  236. DECLARE_MSM_GPIO_PINS(2);
  237. DECLARE_MSM_GPIO_PINS(3);
  238. DECLARE_MSM_GPIO_PINS(4);
  239. DECLARE_MSM_GPIO_PINS(5);
  240. DECLARE_MSM_GPIO_PINS(6);
  241. DECLARE_MSM_GPIO_PINS(7);
  242. DECLARE_MSM_GPIO_PINS(8);
  243. DECLARE_MSM_GPIO_PINS(9);
  244. DECLARE_MSM_GPIO_PINS(10);
  245. DECLARE_MSM_GPIO_PINS(11);
  246. DECLARE_MSM_GPIO_PINS(12);
  247. DECLARE_MSM_GPIO_PINS(13);
  248. DECLARE_MSM_GPIO_PINS(14);
  249. DECLARE_MSM_GPIO_PINS(15);
  250. DECLARE_MSM_GPIO_PINS(16);
  251. DECLARE_MSM_GPIO_PINS(17);
  252. DECLARE_MSM_GPIO_PINS(18);
  253. DECLARE_MSM_GPIO_PINS(19);
  254. DECLARE_MSM_GPIO_PINS(20);
  255. DECLARE_MSM_GPIO_PINS(21);
  256. DECLARE_MSM_GPIO_PINS(22);
  257. DECLARE_MSM_GPIO_PINS(23);
  258. DECLARE_MSM_GPIO_PINS(24);
  259. DECLARE_MSM_GPIO_PINS(25);
  260. DECLARE_MSM_GPIO_PINS(26);
  261. DECLARE_MSM_GPIO_PINS(27);
  262. DECLARE_MSM_GPIO_PINS(28);
  263. DECLARE_MSM_GPIO_PINS(29);
  264. DECLARE_MSM_GPIO_PINS(30);
  265. DECLARE_MSM_GPIO_PINS(31);
  266. DECLARE_MSM_GPIO_PINS(32);
  267. DECLARE_MSM_GPIO_PINS(33);
  268. DECLARE_MSM_GPIO_PINS(34);
  269. DECLARE_MSM_GPIO_PINS(35);
  270. DECLARE_MSM_GPIO_PINS(36);
  271. DECLARE_MSM_GPIO_PINS(37);
  272. DECLARE_MSM_GPIO_PINS(38);
  273. DECLARE_MSM_GPIO_PINS(39);
  274. DECLARE_MSM_GPIO_PINS(40);
  275. DECLARE_MSM_GPIO_PINS(41);
  276. DECLARE_MSM_GPIO_PINS(42);
  277. DECLARE_MSM_GPIO_PINS(43);
  278. DECLARE_MSM_GPIO_PINS(44);
  279. DECLARE_MSM_GPIO_PINS(45);
  280. DECLARE_MSM_GPIO_PINS(46);
  281. DECLARE_MSM_GPIO_PINS(47);
  282. DECLARE_MSM_GPIO_PINS(48);
  283. DECLARE_MSM_GPIO_PINS(49);
  284. DECLARE_MSM_GPIO_PINS(50);
  285. DECLARE_MSM_GPIO_PINS(51);
  286. DECLARE_MSM_GPIO_PINS(52);
  287. DECLARE_MSM_GPIO_PINS(53);
  288. DECLARE_MSM_GPIO_PINS(54);
  289. DECLARE_MSM_GPIO_PINS(55);
  290. DECLARE_MSM_GPIO_PINS(56);
  291. DECLARE_MSM_GPIO_PINS(57);
  292. DECLARE_MSM_GPIO_PINS(58);
  293. DECLARE_MSM_GPIO_PINS(59);
  294. DECLARE_MSM_GPIO_PINS(60);
  295. DECLARE_MSM_GPIO_PINS(61);
  296. DECLARE_MSM_GPIO_PINS(62);
  297. DECLARE_MSM_GPIO_PINS(63);
  298. DECLARE_MSM_GPIO_PINS(64);
  299. DECLARE_MSM_GPIO_PINS(65);
  300. DECLARE_MSM_GPIO_PINS(66);
  301. DECLARE_MSM_GPIO_PINS(67);
  302. DECLARE_MSM_GPIO_PINS(68);
  303. DECLARE_MSM_GPIO_PINS(69);
  304. DECLARE_MSM_GPIO_PINS(70);
  305. DECLARE_MSM_GPIO_PINS(71);
  306. DECLARE_MSM_GPIO_PINS(72);
  307. DECLARE_MSM_GPIO_PINS(73);
  308. DECLARE_MSM_GPIO_PINS(74);
  309. DECLARE_MSM_GPIO_PINS(75);
  310. DECLARE_MSM_GPIO_PINS(76);
  311. DECLARE_MSM_GPIO_PINS(77);
  312. DECLARE_MSM_GPIO_PINS(78);
  313. DECLARE_MSM_GPIO_PINS(79);
  314. DECLARE_MSM_GPIO_PINS(80);
  315. DECLARE_MSM_GPIO_PINS(81);
  316. DECLARE_MSM_GPIO_PINS(82);
  317. DECLARE_MSM_GPIO_PINS(83);
  318. DECLARE_MSM_GPIO_PINS(84);
  319. DECLARE_MSM_GPIO_PINS(85);
  320. DECLARE_MSM_GPIO_PINS(86);
  321. DECLARE_MSM_GPIO_PINS(87);
  322. DECLARE_MSM_GPIO_PINS(88);
  323. DECLARE_MSM_GPIO_PINS(89);
  324. DECLARE_MSM_GPIO_PINS(90);
  325. DECLARE_MSM_GPIO_PINS(91);
  326. DECLARE_MSM_GPIO_PINS(92);
  327. DECLARE_MSM_GPIO_PINS(93);
  328. DECLARE_MSM_GPIO_PINS(94);
  329. DECLARE_MSM_GPIO_PINS(95);
  330. DECLARE_MSM_GPIO_PINS(96);
  331. DECLARE_MSM_GPIO_PINS(97);
  332. DECLARE_MSM_GPIO_PINS(98);
  333. DECLARE_MSM_GPIO_PINS(99);
  334. DECLARE_MSM_GPIO_PINS(100);
  335. DECLARE_MSM_GPIO_PINS(101);
  336. DECLARE_MSM_GPIO_PINS(102);
  337. DECLARE_MSM_GPIO_PINS(103);
  338. DECLARE_MSM_GPIO_PINS(104);
  339. DECLARE_MSM_GPIO_PINS(105);
  340. DECLARE_MSM_GPIO_PINS(106);
  341. DECLARE_MSM_GPIO_PINS(107);
  342. DECLARE_MSM_GPIO_PINS(108);
  343. DECLARE_MSM_GPIO_PINS(109);
  344. DECLARE_MSM_GPIO_PINS(110);
  345. DECLARE_MSM_GPIO_PINS(111);
  346. DECLARE_MSM_GPIO_PINS(112);
  347. DECLARE_MSM_GPIO_PINS(113);
  348. DECLARE_MSM_GPIO_PINS(114);
  349. DECLARE_MSM_GPIO_PINS(115);
  350. DECLARE_MSM_GPIO_PINS(116);
  351. DECLARE_MSM_GPIO_PINS(117);
  352. DECLARE_MSM_GPIO_PINS(118);
  353. DECLARE_MSM_GPIO_PINS(119);
  354. DECLARE_MSM_GPIO_PINS(120);
  355. DECLARE_MSM_GPIO_PINS(121);
  356. DECLARE_MSM_GPIO_PINS(122);
  357. DECLARE_MSM_GPIO_PINS(123);
  358. DECLARE_MSM_GPIO_PINS(124);
  359. DECLARE_MSM_GPIO_PINS(125);
  360. DECLARE_MSM_GPIO_PINS(126);
  361. DECLARE_MSM_GPIO_PINS(127);
  362. DECLARE_MSM_GPIO_PINS(128);
  363. DECLARE_MSM_GPIO_PINS(129);
  364. DECLARE_MSM_GPIO_PINS(130);
  365. DECLARE_MSM_GPIO_PINS(131);
  366. DECLARE_MSM_GPIO_PINS(132);
  367. DECLARE_MSM_GPIO_PINS(133);
  368. DECLARE_MSM_GPIO_PINS(134);
  369. DECLARE_MSM_GPIO_PINS(135);
  370. DECLARE_MSM_GPIO_PINS(136);
  371. DECLARE_MSM_GPIO_PINS(137);
  372. DECLARE_MSM_GPIO_PINS(138);
  373. DECLARE_MSM_GPIO_PINS(139);
  374. DECLARE_MSM_GPIO_PINS(140);
  375. DECLARE_MSM_GPIO_PINS(141);
  376. DECLARE_MSM_GPIO_PINS(142);
  377. DECLARE_MSM_GPIO_PINS(143);
  378. DECLARE_MSM_GPIO_PINS(144);
  379. DECLARE_MSM_GPIO_PINS(145);
  380. static const unsigned int sdc1_rclk_pins[] = { 146 };
  381. static const unsigned int sdc1_clk_pins[] = { 147 };
  382. static const unsigned int sdc1_cmd_pins[] = { 148 };
  383. static const unsigned int sdc1_data_pins[] = { 149 };
  384. static const unsigned int sdc2_clk_pins[] = { 150 };
  385. static const unsigned int sdc2_cmd_pins[] = { 151 };
  386. static const unsigned int sdc2_data_pins[] = { 152 };
  387. static const unsigned int sdc3_clk_pins[] = { 153 };
  388. static const unsigned int sdc3_cmd_pins[] = { 154 };
  389. static const unsigned int sdc3_data_pins[] = { 155 };
  390. enum msm8994_functions {
  391. msm_mux_audio_ref_clk,
  392. msm_mux_blsp_i2c1,
  393. msm_mux_blsp_i2c2,
  394. msm_mux_blsp_i2c3,
  395. msm_mux_blsp_i2c4,
  396. msm_mux_blsp_i2c5,
  397. msm_mux_blsp_i2c6,
  398. msm_mux_blsp_i2c7,
  399. msm_mux_blsp_i2c8,
  400. msm_mux_blsp_i2c9,
  401. msm_mux_blsp_i2c10,
  402. msm_mux_blsp_i2c11,
  403. msm_mux_blsp_i2c12,
  404. msm_mux_blsp_spi1,
  405. msm_mux_blsp_spi1_cs1,
  406. msm_mux_blsp_spi1_cs2,
  407. msm_mux_blsp_spi1_cs3,
  408. msm_mux_blsp_spi2,
  409. msm_mux_blsp_spi2_cs1,
  410. msm_mux_blsp_spi2_cs2,
  411. msm_mux_blsp_spi2_cs3,
  412. msm_mux_blsp_spi3,
  413. msm_mux_blsp_spi4,
  414. msm_mux_blsp_spi5,
  415. msm_mux_blsp_spi6,
  416. msm_mux_blsp_spi7,
  417. msm_mux_blsp_spi8,
  418. msm_mux_blsp_spi9,
  419. msm_mux_blsp_spi10,
  420. msm_mux_blsp_spi10_cs1,
  421. msm_mux_blsp_spi10_cs2,
  422. msm_mux_blsp_spi10_cs3,
  423. msm_mux_blsp_spi11,
  424. msm_mux_blsp_spi12,
  425. msm_mux_blsp_uart1,
  426. msm_mux_blsp_uart2,
  427. msm_mux_blsp_uart3,
  428. msm_mux_blsp_uart4,
  429. msm_mux_blsp_uart5,
  430. msm_mux_blsp_uart6,
  431. msm_mux_blsp_uart7,
  432. msm_mux_blsp_uart8,
  433. msm_mux_blsp_uart9,
  434. msm_mux_blsp_uart10,
  435. msm_mux_blsp_uart11,
  436. msm_mux_blsp_uart12,
  437. msm_mux_blsp_uim1,
  438. msm_mux_blsp_uim2,
  439. msm_mux_blsp_uim3,
  440. msm_mux_blsp_uim4,
  441. msm_mux_blsp_uim5,
  442. msm_mux_blsp_uim6,
  443. msm_mux_blsp_uim7,
  444. msm_mux_blsp_uim8,
  445. msm_mux_blsp_uim9,
  446. msm_mux_blsp_uim10,
  447. msm_mux_blsp_uim11,
  448. msm_mux_blsp_uim12,
  449. msm_mux_blsp11_i2c_scl_b,
  450. msm_mux_blsp11_i2c_sda_b,
  451. msm_mux_blsp11_uart_rx_b,
  452. msm_mux_blsp11_uart_tx_b,
  453. msm_mux_cam_mclk0,
  454. msm_mux_cam_mclk1,
  455. msm_mux_cam_mclk2,
  456. msm_mux_cam_mclk3,
  457. msm_mux_cci_async_in0,
  458. msm_mux_cci_async_in1,
  459. msm_mux_cci_async_in2,
  460. msm_mux_cci_i2c0,
  461. msm_mux_cci_i2c1,
  462. msm_mux_cci_timer0,
  463. msm_mux_cci_timer1,
  464. msm_mux_cci_timer2,
  465. msm_mux_cci_timer3,
  466. msm_mux_cci_timer4,
  467. msm_mux_gcc_gp1_clk_a,
  468. msm_mux_gcc_gp1_clk_b,
  469. msm_mux_gcc_gp2_clk_a,
  470. msm_mux_gcc_gp2_clk_b,
  471. msm_mux_gcc_gp3_clk_a,
  472. msm_mux_gcc_gp3_clk_b,
  473. msm_mux_gp_mn,
  474. msm_mux_gp_pdm0,
  475. msm_mux_gp_pdm1,
  476. msm_mux_gp_pdm2,
  477. msm_mux_gp0_clk,
  478. msm_mux_gp1_clk,
  479. msm_mux_gps_tx,
  480. msm_mux_gsm_tx,
  481. msm_mux_hdmi_cec,
  482. msm_mux_hdmi_ddc,
  483. msm_mux_hdmi_hpd,
  484. msm_mux_hdmi_rcv,
  485. msm_mux_mdp_vsync,
  486. msm_mux_mss_lte,
  487. msm_mux_nav_pps,
  488. msm_mux_nav_tsync,
  489. msm_mux_qdss_cti_trig_in_a,
  490. msm_mux_qdss_cti_trig_in_b,
  491. msm_mux_qdss_cti_trig_in_c,
  492. msm_mux_qdss_cti_trig_in_d,
  493. msm_mux_qdss_cti_trig_out_a,
  494. msm_mux_qdss_cti_trig_out_b,
  495. msm_mux_qdss_cti_trig_out_c,
  496. msm_mux_qdss_cti_trig_out_d,
  497. msm_mux_qdss_traceclk_a,
  498. msm_mux_qdss_traceclk_b,
  499. msm_mux_qdss_tracectl_a,
  500. msm_mux_qdss_tracectl_b,
  501. msm_mux_qdss_tracedata_a,
  502. msm_mux_qdss_tracedata_b,
  503. msm_mux_qua_mi2s,
  504. msm_mux_pci_e0,
  505. msm_mux_pci_e1,
  506. msm_mux_pri_mi2s,
  507. msm_mux_sdc4,
  508. msm_mux_sec_mi2s,
  509. msm_mux_slimbus,
  510. msm_mux_spkr_i2s,
  511. msm_mux_ter_mi2s,
  512. msm_mux_tsif1,
  513. msm_mux_tsif2,
  514. msm_mux_uim1,
  515. msm_mux_uim2,
  516. msm_mux_uim3,
  517. msm_mux_uim4,
  518. msm_mux_uim_batt_alarm,
  519. msm_mux_gpio,
  520. msm_mux_NA,
  521. };
  522. static const char * const gpio_groups[] = {
  523. "gpio0", "gpio1", "gpio2", "gpio3", "gpio4", "gpio5", "gpio6", "gpio7",
  524. "gpio8", "gpio9", "gpio10", "gpio11", "gpio12", "gpio13", "gpio14",
  525. "gpio15", "gpio16", "gpio17", "gpio18", "gpio19", "gpio20", "gpio21",
  526. "gpio22", "gpio23", "gpio24", "gpio25", "gpio26", "gpio27", "gpio28",
  527. "gpio29", "gpio30", "gpio31", "gpio32", "gpio33", "gpio34", "gpio35",
  528. "gpio36", "gpio37", "gpio38", "gpio39", "gpio40", "gpio41", "gpio42",
  529. "gpio43", "gpio44", "gpio45", "gpio46", "gpio47", "gpio48", "gpio49",
  530. "gpio50", "gpio51", "gpio52", "gpio53", "gpio54", "gpio55", "gpio56",
  531. "gpio57", "gpio58", "gpio59", "gpio60", "gpio61", "gpio62", "gpio63",
  532. "gpio64", "gpio65", "gpio66", "gpio67", "gpio68", "gpio69", "gpio70",
  533. "gpio71", "gpio72", "gpio73", "gpio74", "gpio75", "gpio76", "gpio77",
  534. "gpio78", "gpio79", "gpio80", "gpio81", "gpio82", "gpio83", "gpio84",
  535. "gpio85", "gpio86", "gpio87", "gpio88", "gpio89", "gpio90", "gpio91",
  536. "gpio92", "gpio93", "gpio94", "gpio95", "gpio96", "gpio97", "gpio98",
  537. "gpio99", "gpio100", "gpio101", "gpio102", "gpio103", "gpio104",
  538. "gpio105", "gpio106", "gpio107", "gpio108", "gpio109", "gpio110",
  539. "gpio111", "gpio112", "gpio113", "gpio114", "gpio115", "gpio116",
  540. "gpio117", "gpio118", "gpio119", "gpio120", "gpio121", "gpio122",
  541. "gpio123", "gpio124", "gpio125", "gpio126", "gpio127", "gpio128",
  542. "gpio129", "gpio130", "gpio131", "gpio132", "gpio133", "gpio134",
  543. "gpio135", "gpio136", "gpio137", "gpio138", "gpio139", "gpio140",
  544. "gpio141", "gpio142", "gpio143", "gpio144", "gpio145",
  545. };
  546. static const char * const blsp_spi1_groups[] = {
  547. "gpio0", "gpio1", "gpio2", "gpio3"
  548. };
  549. static const char * const blsp_uart1_groups[] = {
  550. "gpio0", "gpio1", "gpio2", "gpio3"
  551. };
  552. static const char * const blsp_uim1_groups[] = {
  553. "gpio0", "gpio1"
  554. };
  555. static const char * const hdmi_rcv_groups[] = {
  556. "gpio0"
  557. };
  558. static const char * const blsp_i2c1_groups[] = {
  559. "gpio2", "gpio3"
  560. };
  561. static const char * const blsp_spi2_groups[] = {
  562. "gpio4", "gpio5", "gpio6", "gpio7"
  563. };
  564. static const char * const blsp_uart2_groups[] = {
  565. "gpio4", "gpio5", "gpio6", "gpio7"
  566. };
  567. static const char * const blsp_uim2_groups[] = {
  568. "gpio4", "gpio5"
  569. };
  570. static const char * const qdss_cti_trig_out_b_groups[] = {
  571. "gpio4",
  572. };
  573. static const char * const qdss_cti_trig_in_b_groups[] = {
  574. "gpio5",
  575. };
  576. static const char * const blsp_i2c2_groups[] = {
  577. "gpio6", "gpio7"
  578. };
  579. static const char * const blsp_spi3_groups[] = {
  580. "gpio8", "gpio9", "gpio10", "gpio11"
  581. };
  582. static const char * const blsp_uart3_groups[] = {
  583. "gpio8", "gpio9", "gpio10", "gpio11"
  584. };
  585. static const char * const blsp_uim3_groups[] = {
  586. "gpio8", "gpio9"
  587. };
  588. static const char * const blsp_spi1_cs1_groups[] = {
  589. "gpio8"
  590. };
  591. static const char * const blsp_spi1_cs2_groups[] = {
  592. "gpio9", "gpio11"
  593. };
  594. static const char * const mdp_vsync_groups[] = {
  595. "gpio10", "gpio11", "gpio12"
  596. };
  597. static const char * const blsp_i2c3_groups[] = {
  598. "gpio10", "gpio11"
  599. };
  600. static const char * const blsp_spi1_cs3_groups[] = {
  601. "gpio10"
  602. };
  603. static const char * const qdss_tracedata_b_groups[] = {
  604. "gpio13", "gpio14", "gpio15", "gpio16", "gpio17", "gpio18",
  605. "gpio19", "gpio21", "gpio22", "gpio23", "gpio25", "gpio26",
  606. "gpio57", "gpio58", "gpio92", "gpio93",
  607. };
  608. static const char * const cam_mclk0_groups[] = {
  609. "gpio13"
  610. };
  611. static const char * const cam_mclk1_groups[] = {
  612. "gpio14"
  613. };
  614. static const char * const cam_mclk2_groups[] = {
  615. "gpio15"
  616. };
  617. static const char * const cam_mclk3_groups[] = {
  618. "gpio16"
  619. };
  620. static const char * const cci_i2c0_groups[] = {
  621. "gpio17", "gpio18"
  622. };
  623. static const char * const blsp_spi4_groups[] = {
  624. "gpio17", "gpio18", "gpio19", "gpio20"
  625. };
  626. static const char * const blsp_uart4_groups[] = {
  627. "gpio17", "gpio18", "gpio19", "gpio20"
  628. };
  629. static const char * const blsp_uim4_groups[] = {
  630. "gpio17", "gpio18"
  631. };
  632. static const char * const cci_i2c1_groups[] = {
  633. "gpio19", "gpio20"
  634. };
  635. static const char * const blsp_i2c4_groups[] = {
  636. "gpio19", "gpio20"
  637. };
  638. static const char * const cci_timer0_groups[] = {
  639. "gpio21"
  640. };
  641. static const char * const blsp_spi5_groups[] = {
  642. "gpio21", "gpio22", "gpio23", "gpio24"
  643. };
  644. static const char * const blsp_uart5_groups[] = {
  645. "gpio21", "gpio22", "gpio23", "gpio24"
  646. };
  647. static const char * const blsp_uim5_groups[] = {
  648. "gpio21", "gpio22"
  649. };
  650. static const char * const cci_timer1_groups[] = {
  651. "gpio22"
  652. };
  653. static const char * const cci_timer2_groups[] = {
  654. "gpio23"
  655. };
  656. static const char * const blsp_i2c5_groups[] = {
  657. "gpio23", "gpio24"
  658. };
  659. static const char * const cci_timer3_groups[] = {
  660. "gpio24"
  661. };
  662. static const char * const cci_async_in1_groups[] = {
  663. "gpio24"
  664. };
  665. static const char * const cci_timer4_groups[] = {
  666. "gpio25"
  667. };
  668. static const char * const cci_async_in2_groups[] = {
  669. "gpio25"
  670. };
  671. static const char * const blsp_spi6_groups[] = {
  672. "gpio25", "gpio26", "gpio27", "gpio28"
  673. };
  674. static const char * const blsp_uart6_groups[] = {
  675. "gpio25", "gpio26", "gpio27", "gpio28"
  676. };
  677. static const char * const blsp_uim6_groups[] = {
  678. "gpio25", "gpio26"
  679. };
  680. static const char * const cci_async_in0_groups[] = {
  681. "gpio26"
  682. };
  683. static const char * const gp0_clk_groups[] = {
  684. "gpio26"
  685. };
  686. static const char * const gp1_clk_groups[] = {
  687. "gpio27", "gpio57", "gpio78"
  688. };
  689. static const char * const blsp_i2c6_groups[] = {
  690. "gpio27", "gpio28"
  691. };
  692. static const char * const qdss_tracectl_a_groups[] = {
  693. "gpio27",
  694. };
  695. static const char * const qdss_traceclk_a_groups[] = {
  696. "gpio28",
  697. };
  698. static const char * const gp_mn_groups[] = {
  699. "gpio29"
  700. };
  701. static const char * const hdmi_cec_groups[] = {
  702. "gpio31"
  703. };
  704. static const char * const hdmi_ddc_groups[] = {
  705. "gpio32", "gpio33"
  706. };
  707. static const char * const hdmi_hpd_groups[] = {
  708. "gpio34"
  709. };
  710. static const char * const uim3_groups[] = {
  711. "gpio35", "gpio36", "gpio37", "gpio38"
  712. };
  713. static const char * const pci_e1_groups[] = {
  714. "gpio35", "gpio36",
  715. };
  716. static const char * const blsp_spi7_groups[] = {
  717. "gpio41", "gpio42", "gpio43", "gpio44"
  718. };
  719. static const char * const blsp_uart7_groups[] = {
  720. "gpio41", "gpio42", "gpio43", "gpio44"
  721. };
  722. static const char * const blsp_uim7_groups[] = {
  723. "gpio41", "gpio42"
  724. };
  725. static const char * const qdss_cti_trig_out_c_groups[] = {
  726. "gpio41",
  727. };
  728. static const char * const qdss_cti_trig_in_c_groups[] = {
  729. "gpio42",
  730. };
  731. static const char * const blsp_i2c7_groups[] = {
  732. "gpio43", "gpio44"
  733. };
  734. static const char * const blsp_spi8_groups[] = {
  735. "gpio45", "gpio46", "gpio47", "gpio48"
  736. };
  737. static const char * const blsp_uart8_groups[] = {
  738. "gpio45", "gpio46", "gpio47", "gpio48"
  739. };
  740. static const char * const blsp_uim8_groups[] = {
  741. "gpio45", "gpio46"
  742. };
  743. static const char * const blsp_i2c8_groups[] = {
  744. "gpio47", "gpio48"
  745. };
  746. static const char * const blsp_spi10_cs1_groups[] = {
  747. "gpio47", "gpio67"
  748. };
  749. static const char * const blsp_spi10_cs2_groups[] = {
  750. "gpio48", "gpio68"
  751. };
  752. static const char * const uim2_groups[] = {
  753. "gpio49", "gpio50", "gpio51", "gpio52"
  754. };
  755. static const char * const blsp_spi9_groups[] = {
  756. "gpio49", "gpio50", "gpio51", "gpio52"
  757. };
  758. static const char * const blsp_uart9_groups[] = {
  759. "gpio49", "gpio50", "gpio51", "gpio52"
  760. };
  761. static const char * const blsp_uim9_groups[] = {
  762. "gpio49", "gpio50"
  763. };
  764. static const char * const blsp_i2c9_groups[] = {
  765. "gpio51", "gpio52"
  766. };
  767. static const char * const pci_e0_groups[] = {
  768. "gpio53", "gpio54",
  769. };
  770. static const char * const uim4_groups[] = {
  771. "gpio53", "gpio54", "gpio55", "gpio56"
  772. };
  773. static const char * const blsp_spi10_groups[] = {
  774. "gpio53", "gpio54", "gpio55", "gpio56"
  775. };
  776. static const char * const blsp_uart10_groups[] = {
  777. "gpio53", "gpio54", "gpio55", "gpio56"
  778. };
  779. static const char * const blsp_uim10_groups[] = {
  780. "gpio53", "gpio54"
  781. };
  782. static const char * const qdss_tracedata_a_groups[] = {
  783. "gpio53", "gpio54", "gpio63", "gpio64", "gpio65",
  784. "gpio66", "gpio67", "gpio74", "gpio75", "gpio76",
  785. "gpio77", "gpio85", "gpio86", "gpio87", "gpio89",
  786. "gpio90"
  787. };
  788. static const char * const gp_pdm0_groups[] = {
  789. "gpio54", "gpio95"
  790. };
  791. static const char * const blsp_i2c10_groups[] = {
  792. "gpio55", "gpio56"
  793. };
  794. static const char * const qdss_cti_trig_in_a_groups[] = {
  795. "gpio55",
  796. };
  797. static const char * const qdss_cti_trig_out_a_groups[] = {
  798. "gpio56",
  799. };
  800. static const char * const qua_mi2s_groups[] = {
  801. "gpio57", "gpio58", "gpio59", "gpio60", "gpio61", "gpio62", "gpio63",
  802. };
  803. static const char * const gcc_gp1_clk_a_groups[] = {
  804. "gpio57"
  805. };
  806. static const char * const gcc_gp2_clk_a_groups[] = {
  807. "gpio58"
  808. };
  809. static const char * const gcc_gp3_clk_a_groups[] = {
  810. "gpio59"
  811. };
  812. static const char * const blsp_spi2_cs1_groups[] = {
  813. "gpio62"
  814. };
  815. static const char * const blsp_spi2_cs2_groups[] = {
  816. "gpio63"
  817. };
  818. static const char * const gp_pdm2_groups[] = {
  819. "gpio63", "gpio79"
  820. };
  821. static const char * const pri_mi2s_groups[] = {
  822. "gpio64", "gpio65", "gpio66", "gpio67", "gpio68"
  823. };
  824. static const char * const blsp_spi2_cs3_groups[] = {
  825. "gpio66"
  826. };
  827. static const char * const spkr_i2s_groups[] = {
  828. "gpio69", "gpio70", "gpio71", "gpio72"
  829. };
  830. static const char * const audio_ref_clk_groups[] = {
  831. "gpio69"
  832. };
  833. static const char * const slimbus_groups[] = {
  834. "gpio70", "gpio71"
  835. };
  836. static const char * const ter_mi2s_groups[] = {
  837. "gpio73", "gpio74", "gpio75", "gpio76", "gpio77"
  838. };
  839. static const char * const gp_pdm1_groups[] = {
  840. "gpio74", "gpio86"
  841. };
  842. static const char * const sec_mi2s_groups[] = {
  843. "gpio78", "gpio79", "gpio80", "gpio81", "gpio82"
  844. };
  845. static const char * const gcc_gp1_clk_b_groups[] = {
  846. "gpio78"
  847. };
  848. static const char * const blsp_spi11_groups[] = {
  849. "gpio81", "gpio82", "gpio83", "gpio84"
  850. };
  851. static const char * const blsp_uart11_groups[] = {
  852. "gpio81", "gpio82", "gpio83", "gpio84"
  853. };
  854. static const char * const blsp_uim11_groups[] = {
  855. "gpio81", "gpio82"
  856. };
  857. static const char * const gcc_gp2_clk_b_groups[] = {
  858. "gpio81"
  859. };
  860. static const char * const gcc_gp3_clk_b_groups[] = {
  861. "gpio82"
  862. };
  863. static const char * const blsp_i2c11_groups[] = {
  864. "gpio83", "gpio84"
  865. };
  866. static const char * const blsp_uart12_groups[] = {
  867. "gpio85", "gpio86", "gpio87", "gpio88"
  868. };
  869. static const char * const blsp_uim12_groups[] = {
  870. "gpio85", "gpio86"
  871. };
  872. static const char * const blsp_i2c12_groups[] = {
  873. "gpio87", "gpio88"
  874. };
  875. static const char * const blsp_spi12_groups[] = {
  876. "gpio85", "gpio86", "gpio87", "gpio88"
  877. };
  878. static const char * const tsif1_groups[] = {
  879. "gpio89", "gpio90", "gpio91", "gpio110", "gpio111"
  880. };
  881. static const char * const blsp_spi10_cs3_groups[] = {
  882. "gpio90"
  883. };
  884. static const char * const sdc4_groups[] = {
  885. "gpio91", "gpio92", "gpio93", "gpio94", "gpio95", "gpio96"
  886. };
  887. static const char * const qdss_traceclk_b_groups[] = {
  888. "gpio91",
  889. };
  890. static const char * const tsif2_groups[] = {
  891. "gpio92", "gpio93", "gpio94", "gpio95", "gpio96"
  892. };
  893. static const char * const qdss_tracectl_b_groups[] = {
  894. "gpio94",
  895. };
  896. static const char * const qdss_cti_trig_out_d_groups[] = {
  897. "gpio95",
  898. };
  899. static const char * const qdss_cti_trig_in_d_groups[] = {
  900. "gpio96",
  901. };
  902. static const char * const uim1_groups[] = {
  903. "gpio97", "gpio98", "gpio99", "gpio100"
  904. };
  905. static const char * const uim_batt_alarm_groups[] = {
  906. "gpio101"
  907. };
  908. static const char * const blsp11_uart_tx_b_groups[] = {
  909. "gpio111"
  910. };
  911. static const char * const blsp11_uart_rx_b_groups[] = {
  912. "gpio112"
  913. };
  914. static const char * const blsp11_i2c_sda_b_groups[] = {
  915. "gpio113"
  916. };
  917. static const char * const blsp11_i2c_scl_b_groups[] = {
  918. "gpio114"
  919. };
  920. static const char * const gsm_tx_groups[] = {
  921. "gpio126", "gpio131", "gpio132", "gpio133"
  922. };
  923. static const char * const nav_tsync_groups[] = {
  924. "gpio127"
  925. };
  926. static const char * const nav_pps_groups[] = {
  927. "gpio127"
  928. };
  929. static const char * const gps_tx_groups[] = {
  930. "gpio130"
  931. };
  932. static const char * const mss_lte_groups[] = {
  933. "gpio134", "gpio135"
  934. };
  935. static const struct pinfunction msm8994_functions[] = {
  936. MSM_PIN_FUNCTION(audio_ref_clk),
  937. MSM_PIN_FUNCTION(blsp_i2c1),
  938. MSM_PIN_FUNCTION(blsp_i2c2),
  939. MSM_PIN_FUNCTION(blsp_i2c3),
  940. MSM_PIN_FUNCTION(blsp_i2c4),
  941. MSM_PIN_FUNCTION(blsp_i2c5),
  942. MSM_PIN_FUNCTION(blsp_i2c6),
  943. MSM_PIN_FUNCTION(blsp_i2c7),
  944. MSM_PIN_FUNCTION(blsp_i2c8),
  945. MSM_PIN_FUNCTION(blsp_i2c9),
  946. MSM_PIN_FUNCTION(blsp_i2c10),
  947. MSM_PIN_FUNCTION(blsp_i2c11),
  948. MSM_PIN_FUNCTION(blsp_i2c12),
  949. MSM_PIN_FUNCTION(blsp_spi1),
  950. MSM_PIN_FUNCTION(blsp_spi1_cs1),
  951. MSM_PIN_FUNCTION(blsp_spi1_cs2),
  952. MSM_PIN_FUNCTION(blsp_spi1_cs3),
  953. MSM_PIN_FUNCTION(blsp_spi2),
  954. MSM_PIN_FUNCTION(blsp_spi2_cs1),
  955. MSM_PIN_FUNCTION(blsp_spi2_cs2),
  956. MSM_PIN_FUNCTION(blsp_spi2_cs3),
  957. MSM_PIN_FUNCTION(blsp_spi3),
  958. MSM_PIN_FUNCTION(blsp_spi4),
  959. MSM_PIN_FUNCTION(blsp_spi5),
  960. MSM_PIN_FUNCTION(blsp_spi6),
  961. MSM_PIN_FUNCTION(blsp_spi7),
  962. MSM_PIN_FUNCTION(blsp_spi8),
  963. MSM_PIN_FUNCTION(blsp_spi9),
  964. MSM_PIN_FUNCTION(blsp_spi10),
  965. MSM_PIN_FUNCTION(blsp_spi10_cs1),
  966. MSM_PIN_FUNCTION(blsp_spi10_cs2),
  967. MSM_PIN_FUNCTION(blsp_spi10_cs3),
  968. MSM_PIN_FUNCTION(blsp_spi11),
  969. MSM_PIN_FUNCTION(blsp_spi12),
  970. MSM_PIN_FUNCTION(blsp_uart1),
  971. MSM_PIN_FUNCTION(blsp_uart2),
  972. MSM_PIN_FUNCTION(blsp_uart3),
  973. MSM_PIN_FUNCTION(blsp_uart4),
  974. MSM_PIN_FUNCTION(blsp_uart5),
  975. MSM_PIN_FUNCTION(blsp_uart6),
  976. MSM_PIN_FUNCTION(blsp_uart7),
  977. MSM_PIN_FUNCTION(blsp_uart8),
  978. MSM_PIN_FUNCTION(blsp_uart9),
  979. MSM_PIN_FUNCTION(blsp_uart10),
  980. MSM_PIN_FUNCTION(blsp_uart11),
  981. MSM_PIN_FUNCTION(blsp_uart12),
  982. MSM_PIN_FUNCTION(blsp_uim1),
  983. MSM_PIN_FUNCTION(blsp_uim2),
  984. MSM_PIN_FUNCTION(blsp_uim3),
  985. MSM_PIN_FUNCTION(blsp_uim4),
  986. MSM_PIN_FUNCTION(blsp_uim5),
  987. MSM_PIN_FUNCTION(blsp_uim6),
  988. MSM_PIN_FUNCTION(blsp_uim7),
  989. MSM_PIN_FUNCTION(blsp_uim8),
  990. MSM_PIN_FUNCTION(blsp_uim9),
  991. MSM_PIN_FUNCTION(blsp_uim10),
  992. MSM_PIN_FUNCTION(blsp_uim11),
  993. MSM_PIN_FUNCTION(blsp_uim12),
  994. MSM_PIN_FUNCTION(blsp11_i2c_scl_b),
  995. MSM_PIN_FUNCTION(blsp11_i2c_sda_b),
  996. MSM_PIN_FUNCTION(blsp11_uart_rx_b),
  997. MSM_PIN_FUNCTION(blsp11_uart_tx_b),
  998. MSM_PIN_FUNCTION(cam_mclk0),
  999. MSM_PIN_FUNCTION(cam_mclk1),
  1000. MSM_PIN_FUNCTION(cam_mclk2),
  1001. MSM_PIN_FUNCTION(cam_mclk3),
  1002. MSM_PIN_FUNCTION(cci_async_in0),
  1003. MSM_PIN_FUNCTION(cci_async_in1),
  1004. MSM_PIN_FUNCTION(cci_async_in2),
  1005. MSM_PIN_FUNCTION(cci_i2c0),
  1006. MSM_PIN_FUNCTION(cci_i2c1),
  1007. MSM_PIN_FUNCTION(cci_timer0),
  1008. MSM_PIN_FUNCTION(cci_timer1),
  1009. MSM_PIN_FUNCTION(cci_timer2),
  1010. MSM_PIN_FUNCTION(cci_timer3),
  1011. MSM_PIN_FUNCTION(cci_timer4),
  1012. MSM_PIN_FUNCTION(gcc_gp1_clk_a),
  1013. MSM_PIN_FUNCTION(gcc_gp1_clk_b),
  1014. MSM_PIN_FUNCTION(gcc_gp2_clk_a),
  1015. MSM_PIN_FUNCTION(gcc_gp2_clk_b),
  1016. MSM_PIN_FUNCTION(gcc_gp3_clk_a),
  1017. MSM_PIN_FUNCTION(gcc_gp3_clk_b),
  1018. MSM_PIN_FUNCTION(gp_mn),
  1019. MSM_PIN_FUNCTION(gp_pdm0),
  1020. MSM_PIN_FUNCTION(gp_pdm1),
  1021. MSM_PIN_FUNCTION(gp_pdm2),
  1022. MSM_PIN_FUNCTION(gp0_clk),
  1023. MSM_PIN_FUNCTION(gp1_clk),
  1024. MSM_PIN_FUNCTION(gps_tx),
  1025. MSM_PIN_FUNCTION(gsm_tx),
  1026. MSM_PIN_FUNCTION(hdmi_cec),
  1027. MSM_PIN_FUNCTION(hdmi_ddc),
  1028. MSM_PIN_FUNCTION(hdmi_hpd),
  1029. MSM_PIN_FUNCTION(hdmi_rcv),
  1030. MSM_PIN_FUNCTION(mdp_vsync),
  1031. MSM_PIN_FUNCTION(mss_lte),
  1032. MSM_PIN_FUNCTION(nav_pps),
  1033. MSM_PIN_FUNCTION(nav_tsync),
  1034. MSM_PIN_FUNCTION(qdss_cti_trig_in_a),
  1035. MSM_PIN_FUNCTION(qdss_cti_trig_in_b),
  1036. MSM_PIN_FUNCTION(qdss_cti_trig_in_c),
  1037. MSM_PIN_FUNCTION(qdss_cti_trig_in_d),
  1038. MSM_PIN_FUNCTION(qdss_cti_trig_out_a),
  1039. MSM_PIN_FUNCTION(qdss_cti_trig_out_b),
  1040. MSM_PIN_FUNCTION(qdss_cti_trig_out_c),
  1041. MSM_PIN_FUNCTION(qdss_cti_trig_out_d),
  1042. MSM_PIN_FUNCTION(qdss_traceclk_a),
  1043. MSM_PIN_FUNCTION(qdss_traceclk_b),
  1044. MSM_PIN_FUNCTION(qdss_tracectl_a),
  1045. MSM_PIN_FUNCTION(qdss_tracectl_b),
  1046. MSM_PIN_FUNCTION(qdss_tracedata_a),
  1047. MSM_PIN_FUNCTION(qdss_tracedata_b),
  1048. MSM_PIN_FUNCTION(qua_mi2s),
  1049. MSM_PIN_FUNCTION(pci_e0),
  1050. MSM_PIN_FUNCTION(pci_e1),
  1051. MSM_PIN_FUNCTION(pri_mi2s),
  1052. MSM_PIN_FUNCTION(sdc4),
  1053. MSM_PIN_FUNCTION(sec_mi2s),
  1054. MSM_PIN_FUNCTION(slimbus),
  1055. MSM_PIN_FUNCTION(spkr_i2s),
  1056. MSM_PIN_FUNCTION(ter_mi2s),
  1057. MSM_PIN_FUNCTION(tsif1),
  1058. MSM_PIN_FUNCTION(tsif2),
  1059. MSM_PIN_FUNCTION(uim_batt_alarm),
  1060. MSM_PIN_FUNCTION(uim1),
  1061. MSM_PIN_FUNCTION(uim2),
  1062. MSM_PIN_FUNCTION(uim3),
  1063. MSM_PIN_FUNCTION(uim4),
  1064. MSM_PIN_FUNCTION(gpio),
  1065. };
  1066. static const struct msm_pingroup msm8994_groups[] = {
  1067. PINGROUP(0, blsp_spi1, blsp_uart1, blsp_uim1, hdmi_rcv, NA, NA, NA,
  1068. NA, NA, NA, NA),
  1069. PINGROUP(1, blsp_spi1, blsp_uart1, blsp_uim1, NA, NA, NA, NA, NA, NA,
  1070. NA, NA),
  1071. PINGROUP(2, blsp_spi1, blsp_uart1, blsp_i2c1, NA, NA, NA, NA, NA, NA,
  1072. NA, NA),
  1073. PINGROUP(3, blsp_spi1, blsp_uart1, blsp_i2c1, NA, NA, NA, NA, NA, NA,
  1074. NA, NA),
  1075. PINGROUP(4, blsp_spi2, blsp_uart2, blsp_uim2, NA, qdss_cti_trig_out_b,
  1076. NA, NA, NA, NA, NA, NA),
  1077. PINGROUP(5, blsp_spi2, blsp_uart2, blsp_uim2, NA, qdss_cti_trig_in_b,
  1078. NA, NA, NA, NA, NA, NA),
  1079. PINGROUP(6, blsp_spi2, blsp_uart2, blsp_i2c2, NA, NA, NA, NA, NA, NA,
  1080. NA, NA),
  1081. PINGROUP(7, blsp_spi2, blsp_uart2, blsp_i2c2, NA, NA, NA, NA, NA, NA,
  1082. NA, NA),
  1083. PINGROUP(8, blsp_spi3, blsp_uart3, blsp_uim3, blsp_spi1_cs1, NA, NA,
  1084. NA, NA, NA, NA, NA),
  1085. PINGROUP(9, blsp_spi3, blsp_uart3, blsp_uim3, blsp_spi1_cs2, NA, NA,
  1086. NA, NA, NA, NA, NA),
  1087. PINGROUP(10, mdp_vsync, blsp_spi3, blsp_uart3, blsp_i2c3,
  1088. blsp_spi1_cs3, NA, NA, NA, NA, NA, NA),
  1089. PINGROUP(11, mdp_vsync, blsp_spi3, blsp_uart3, blsp_i2c3,
  1090. blsp_spi1_cs2, NA, NA, NA, NA, NA, NA),
  1091. PINGROUP(12, mdp_vsync, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1092. PINGROUP(13, cam_mclk0, NA, NA, qdss_tracedata_b, NA, NA, NA, NA, NA,
  1093. NA, NA),
  1094. PINGROUP(14, cam_mclk1, NA, NA, qdss_tracedata_b, NA, NA, NA, NA, NA,
  1095. NA, NA),
  1096. PINGROUP(15, cam_mclk2, NA, qdss_tracedata_b, NA, NA, NA, NA, NA, NA,
  1097. NA, NA),
  1098. PINGROUP(16, cam_mclk3, NA, qdss_tracedata_b, NA, NA, NA, NA, NA, NA,
  1099. NA, NA),
  1100. PINGROUP(17, cci_i2c0, blsp_spi4, blsp_uart4, blsp_uim4, NA,
  1101. qdss_tracedata_b, NA, NA, NA, NA, NA),
  1102. PINGROUP(18, cci_i2c0, blsp_spi4, blsp_uart4, blsp_uim4, NA,
  1103. qdss_tracedata_b, NA, NA, NA, NA, NA),
  1104. PINGROUP(19, cci_i2c1, blsp_spi4, blsp_uart4, blsp_i2c4, NA,
  1105. qdss_tracedata_b, NA, NA, NA, NA, NA),
  1106. PINGROUP(20, cci_i2c1, blsp_spi4, blsp_uart4, blsp_i2c4, NA, NA, NA,
  1107. NA, NA, NA, NA),
  1108. PINGROUP(21, cci_timer0, blsp_spi5, blsp_uart5, blsp_uim5, NA,
  1109. qdss_tracedata_b, NA, NA, NA, NA, NA),
  1110. PINGROUP(22, cci_timer1, blsp_spi5, blsp_uart5, blsp_uim5, NA,
  1111. qdss_tracedata_b, NA, NA, NA, NA, NA),
  1112. PINGROUP(23, cci_timer2, blsp_spi5, blsp_uart5, blsp_i2c5, NA, NA,
  1113. qdss_tracedata_b, NA, NA, NA, NA),
  1114. PINGROUP(24, cci_timer3, cci_async_in1, blsp_spi5, blsp_uart5,
  1115. blsp_i2c5, NA, NA, NA, NA, NA, NA),
  1116. PINGROUP(25, cci_timer4, cci_async_in2, blsp_spi6, blsp_uart6,
  1117. blsp_uim6, NA, NA, qdss_tracedata_b, NA, NA, NA),
  1118. PINGROUP(26, cci_async_in0, blsp_spi6, blsp_uart6, blsp_uim6, gp0_clk,
  1119. NA, qdss_tracedata_b, NA, NA, NA, NA),
  1120. PINGROUP(27, blsp_spi6, blsp_uart6, blsp_i2c6, gp1_clk,
  1121. qdss_tracectl_a, NA, NA, NA, NA, NA, NA),
  1122. PINGROUP(28, blsp_spi6, blsp_uart6, blsp_i2c6, qdss_traceclk_a, NA,
  1123. NA, NA, NA, NA, NA, NA),
  1124. PINGROUP(29, gp_mn, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1125. PINGROUP(30, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1126. PINGROUP(31, hdmi_cec, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1127. PINGROUP(32, hdmi_ddc, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1128. PINGROUP(33, hdmi_ddc, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1129. PINGROUP(34, hdmi_hpd, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1130. PINGROUP(35, uim3, pci_e1, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1131. PINGROUP(36, uim3, pci_e1, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1132. PINGROUP(37, uim3, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1133. PINGROUP(38, uim3, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1134. PINGROUP(39, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1135. PINGROUP(40, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1136. PINGROUP(41, blsp_spi7, blsp_uart7, blsp_uim7, qdss_cti_trig_out_c,
  1137. NA, NA, NA, NA, NA, NA, NA),
  1138. PINGROUP(42, blsp_spi7, blsp_uart7, blsp_uim7, qdss_cti_trig_in_c, NA,
  1139. NA, NA, NA, NA, NA, NA),
  1140. PINGROUP(43, blsp_spi7, blsp_uart7, blsp_i2c7, NA, NA, NA, NA, NA, NA,
  1141. NA, NA),
  1142. PINGROUP(44, blsp_spi7, blsp_uart7, blsp_i2c7, NA, NA, NA, NA, NA, NA,
  1143. NA, NA),
  1144. PINGROUP(45, blsp_spi8, blsp_uart8, blsp_uim8, NA, NA, NA, NA, NA, NA,
  1145. NA, NA),
  1146. PINGROUP(46, blsp_spi8, blsp_uart8, blsp_uim8, NA, NA, NA, NA, NA, NA,
  1147. NA, NA),
  1148. PINGROUP(47, blsp_spi8, blsp_uart8, blsp_i2c8, blsp_spi10_cs1, NA, NA,
  1149. NA, NA, NA, NA, NA),
  1150. PINGROUP(48, blsp_spi8, blsp_uart8, blsp_i2c8, blsp_spi10_cs2, NA, NA,
  1151. NA, NA, NA, NA, NA),
  1152. PINGROUP(49, uim2, blsp_spi9, blsp_uart9, blsp_uim9, NA, NA, NA, NA,
  1153. NA, NA, NA),
  1154. PINGROUP(50, uim2, blsp_spi9, blsp_uart9, blsp_uim9, NA, NA, NA, NA,
  1155. NA, NA, NA),
  1156. PINGROUP(51, uim2, blsp_spi9, blsp_uart9, blsp_i2c9, NA, NA, NA, NA,
  1157. NA, NA, NA),
  1158. PINGROUP(52, uim2, blsp_spi9, blsp_uart9, blsp_i2c9, NA, NA, NA, NA,
  1159. NA, NA, NA),
  1160. PINGROUP(53, uim4, pci_e0, blsp_spi10, blsp_uart10, blsp_uim10, NA,
  1161. NA, qdss_tracedata_a, NA, NA, NA),
  1162. PINGROUP(54, uim4, pci_e0, blsp_spi10, blsp_uart10, blsp_uim10,
  1163. gp_pdm0, NA, NA, qdss_tracedata_a, NA, NA),
  1164. PINGROUP(55, uim4, blsp_spi10, blsp_uart10, blsp_i2c10, NA, NA, NA,
  1165. qdss_cti_trig_in_a, NA, NA, NA),
  1166. PINGROUP(56, uim4, blsp_spi10, blsp_uart10, blsp_i2c10, NA, NA,
  1167. qdss_cti_trig_out_a, NA, NA, NA, NA),
  1168. PINGROUP(57, qua_mi2s, gcc_gp1_clk_a, NA, NA, qdss_tracedata_b, NA, NA,
  1169. NA, NA, NA, NA),
  1170. PINGROUP(58, qua_mi2s, gcc_gp2_clk_a, NA, NA, qdss_tracedata_b, NA, NA,
  1171. NA, NA, NA, NA),
  1172. PINGROUP(59, qua_mi2s, gcc_gp3_clk_a, NA, NA, NA, NA, NA, NA, NA, NA,
  1173. NA),
  1174. PINGROUP(60, qua_mi2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1175. PINGROUP(61, qua_mi2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1176. PINGROUP(62, qua_mi2s, blsp_spi2_cs1, NA, NA, NA, NA, NA, NA, NA, NA,
  1177. NA),
  1178. PINGROUP(63, qua_mi2s, blsp_spi2_cs2, gp_pdm2, NA, NA, NA, NA, NA,
  1179. qdss_tracedata_a, NA, NA),
  1180. PINGROUP(64, pri_mi2s, NA, NA, NA, qdss_tracedata_a, NA, NA, NA, NA,
  1181. NA, NA),
  1182. PINGROUP(65, pri_mi2s, NA, NA, NA, qdss_tracedata_a, NA, NA, NA, NA,
  1183. NA, NA),
  1184. PINGROUP(66, pri_mi2s, blsp_spi2_cs3, NA, NA, NA, qdss_tracedata_a,
  1185. NA, NA, NA, NA, NA),
  1186. PINGROUP(67, pri_mi2s, blsp_spi10_cs1, NA, NA, NA, qdss_tracedata_a,
  1187. NA, NA, NA, NA, NA),
  1188. PINGROUP(68, pri_mi2s, blsp_spi10_cs2, NA, NA, NA, NA, NA, NA, NA, NA,
  1189. NA),
  1190. PINGROUP(69, spkr_i2s, audio_ref_clk, NA, NA, NA, NA, NA, NA, NA, NA,
  1191. NA),
  1192. PINGROUP(70, slimbus, spkr_i2s, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1193. PINGROUP(71, slimbus, spkr_i2s, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1194. PINGROUP(72, spkr_i2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1195. PINGROUP(73, ter_mi2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1196. PINGROUP(74, ter_mi2s, gp_pdm1, NA, NA, NA, qdss_tracedata_a, NA, NA,
  1197. NA, NA, NA),
  1198. PINGROUP(75, ter_mi2s, NA, NA, qdss_tracedata_a, NA, NA, NA, NA, NA,
  1199. NA, NA),
  1200. PINGROUP(76, ter_mi2s, NA, NA, qdss_tracedata_a, NA, NA, NA, NA, NA,
  1201. NA, NA),
  1202. PINGROUP(77, ter_mi2s, NA, NA, qdss_tracedata_a, NA, NA, NA, NA, NA,
  1203. NA, NA),
  1204. PINGROUP(78, sec_mi2s, gcc_gp1_clk_b, NA, NA, NA, NA, NA, NA, NA, NA,
  1205. NA),
  1206. PINGROUP(79, sec_mi2s, gp_pdm2, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1207. PINGROUP(80, sec_mi2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1208. PINGROUP(81, sec_mi2s, blsp_spi11, blsp_uart11, blsp_uim11,
  1209. gcc_gp2_clk_b, NA, NA, NA, NA, NA, NA),
  1210. PINGROUP(82, sec_mi2s, blsp_spi11, blsp_uart11, blsp_uim11,
  1211. gcc_gp3_clk_b, NA, NA, NA, NA, NA, NA),
  1212. PINGROUP(83, blsp_spi11, blsp_uart11, blsp_i2c11, NA, NA, NA, NA, NA,
  1213. NA, NA, NA),
  1214. PINGROUP(84, blsp_spi11, blsp_uart11, blsp_i2c11, NA, NA, NA, NA, NA,
  1215. NA, NA, NA),
  1216. PINGROUP(85, blsp_spi12, blsp_uart12, blsp_uim12, NA, NA,
  1217. qdss_tracedata_a, NA, NA, NA, NA, NA),
  1218. PINGROUP(86, blsp_spi12, blsp_uart12, blsp_uim12, gp_pdm1, NA,
  1219. qdss_tracedata_a, NA, NA, NA, NA, NA),
  1220. PINGROUP(87, blsp_spi12, blsp_uart12, blsp_i2c12, NA,
  1221. qdss_tracedata_a, NA, NA, NA, NA, NA, NA),
  1222. PINGROUP(88, blsp_spi12, blsp_uart12, blsp_i2c12, NA, NA, NA, NA, NA,
  1223. NA, NA, NA),
  1224. PINGROUP(89, tsif1, NA, qdss_tracedata_a, NA, NA, NA, NA, NA, NA, NA,
  1225. NA),
  1226. PINGROUP(90, tsif1, blsp_spi10_cs3, qdss_tracedata_a, NA, NA, NA, NA,
  1227. NA, NA, NA, NA),
  1228. PINGROUP(91, tsif1, sdc4, NA, NA, NA, NA, qdss_traceclk_b, NA, NA, NA,
  1229. NA),
  1230. PINGROUP(92, tsif2, sdc4, NA, NA, qdss_tracedata_b, NA, NA, NA, NA,
  1231. NA, NA),
  1232. PINGROUP(93, tsif2, sdc4, NA, NA, NA, NA, qdss_tracedata_b, NA, NA,
  1233. NA, NA),
  1234. PINGROUP(94, tsif2, sdc4, NA, NA, NA, NA, qdss_tracectl_b, NA, NA, NA,
  1235. NA),
  1236. PINGROUP(95, tsif2, sdc4, gp_pdm0, NA, NA, NA, qdss_cti_trig_out_d,
  1237. NA, NA, NA, NA),
  1238. PINGROUP(96, tsif2, sdc4, qdss_cti_trig_in_d, NA, NA, NA, NA, NA, NA,
  1239. NA, NA),
  1240. PINGROUP(97, uim1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1241. PINGROUP(98, uim1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1242. PINGROUP(99, uim1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1243. PINGROUP(100, uim1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1244. PINGROUP(101, uim_batt_alarm, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1245. PINGROUP(102, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1246. PINGROUP(103, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1247. PINGROUP(104, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1248. PINGROUP(105, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1249. PINGROUP(106, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1250. PINGROUP(107, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1251. PINGROUP(108, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1252. PINGROUP(109, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1253. PINGROUP(110, tsif1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1254. PINGROUP(111, tsif1, blsp11_uart_tx_b, NA, NA, NA, NA, NA, NA, NA, NA,
  1255. NA),
  1256. PINGROUP(112, blsp11_uart_rx_b, NA, NA, NA, NA, NA, NA, NA, NA, NA,
  1257. NA),
  1258. PINGROUP(113, blsp11_i2c_sda_b, NA, NA, NA, NA, NA, NA, NA, NA, NA,
  1259. NA),
  1260. PINGROUP(114, blsp11_i2c_scl_b, NA, NA, NA, NA, NA, NA, NA, NA, NA,
  1261. NA),
  1262. PINGROUP(115, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1263. PINGROUP(116, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1264. PINGROUP(117, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1265. PINGROUP(118, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1266. PINGROUP(119, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1267. PINGROUP(120, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1268. PINGROUP(121, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1269. PINGROUP(122, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1270. PINGROUP(123, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1271. PINGROUP(124, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1272. PINGROUP(125, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1273. PINGROUP(126, NA, gsm_tx, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1274. PINGROUP(127, NA, nav_tsync, nav_pps, NA, NA, NA, NA, NA, NA, NA,
  1275. NA),
  1276. PINGROUP(128, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1277. PINGROUP(129, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1278. PINGROUP(130, gps_tx, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1279. PINGROUP(131, gsm_tx, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1280. PINGROUP(132, gsm_tx, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1281. PINGROUP(133, gsm_tx, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1282. PINGROUP(134, mss_lte, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1283. PINGROUP(135, mss_lte, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1284. PINGROUP(136, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1285. PINGROUP(137, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1286. PINGROUP(138, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1287. PINGROUP(139, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1288. PINGROUP(140, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1289. PINGROUP(141, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1290. PINGROUP(142, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1291. PINGROUP(143, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1292. PINGROUP(144, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1293. PINGROUP(145, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA),
  1294. SDC_PINGROUP(sdc1_rclk, 0x2044, 15, 0),
  1295. SDC_PINGROUP(sdc1_clk, 0x2044, 13, 6),
  1296. SDC_PINGROUP(sdc1_cmd, 0x2044, 11, 3),
  1297. SDC_PINGROUP(sdc1_data, 0x2044, 9, 0),
  1298. SDC_PINGROUP(sdc2_clk, 0x2048, 14, 6),
  1299. SDC_PINGROUP(sdc2_cmd, 0x2048, 11, 3),
  1300. SDC_PINGROUP(sdc2_data, 0x2048, 9, 0),
  1301. SDC_PINGROUP(sdc3_clk, 0x206c, 14, 6),
  1302. SDC_PINGROUP(sdc3_cmd, 0x206c, 11, 3),
  1303. SDC_PINGROUP(sdc3_data, 0x206c, 9, 0),
  1304. };
  1305. #define NUM_GPIO_PINGROUPS 146
  1306. static const struct msm_pinctrl_soc_data msm8994_pinctrl = {
  1307. .pins = msm8994_pins,
  1308. .npins = ARRAY_SIZE(msm8994_pins),
  1309. .functions = msm8994_functions,
  1310. .nfunctions = ARRAY_SIZE(msm8994_functions),
  1311. .groups = msm8994_groups,
  1312. .ngroups = ARRAY_SIZE(msm8994_groups),
  1313. .ngpios = NUM_GPIO_PINGROUPS,
  1314. };
  1315. static int msm8994_pinctrl_probe(struct platform_device *pdev)
  1316. {
  1317. return msm_pinctrl_probe(pdev, &msm8994_pinctrl);
  1318. }
  1319. static const struct of_device_id msm8994_pinctrl_of_match[] = {
  1320. { .compatible = "qcom,msm8992-pinctrl", },
  1321. { .compatible = "qcom,msm8994-pinctrl", },
  1322. { }
  1323. };
  1324. static struct platform_driver msm8994_pinctrl_driver = {
  1325. .driver = {
  1326. .name = "msm8994-pinctrl",
  1327. .of_match_table = msm8994_pinctrl_of_match,
  1328. },
  1329. .probe = msm8994_pinctrl_probe,
  1330. .remove_new = msm_pinctrl_remove,
  1331. };
  1332. static int __init msm8994_pinctrl_init(void)
  1333. {
  1334. return platform_driver_register(&msm8994_pinctrl_driver);
  1335. }
  1336. arch_initcall(msm8994_pinctrl_init);
  1337. static void __exit msm8994_pinctrl_exit(void)
  1338. {
  1339. platform_driver_unregister(&msm8994_pinctrl_driver);
  1340. }
  1341. module_exit(msm8994_pinctrl_exit);
  1342. MODULE_DESCRIPTION("Qualcomm MSM8994 pinctrl driver");
  1343. MODULE_LICENSE("GPL v2");
  1344. MODULE_DEVICE_TABLE(of, msm8994_pinctrl_of_match);