diff options
author | Bjorn Andersson <bjorn.andersson@sonymobile.com> | 2014-07-09 00:59:31 -0400 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2014-07-11 08:08:38 -0400 |
commit | 14d40ff8f8b25a1ae6a273b62e239c7064e5bc9f (patch) | |
tree | 479ce8839d64a87fb1f22114b87d324fdc5464d4 /drivers/pinctrl | |
parent | 2700bc013572e3c07e3a28e3715f277fd94b678a (diff) |
pinctrl: msm: Add msm8960 definitions
Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl')
-rw-r--r-- | drivers/pinctrl/Kconfig | 8 | ||||
-rw-r--r-- | drivers/pinctrl/Makefile | 1 | ||||
-rw-r--r-- | drivers/pinctrl/pinctrl-msm8960.c | 1254 |
3 files changed, 1263 insertions, 0 deletions
diff --git a/drivers/pinctrl/Kconfig b/drivers/pinctrl/Kconfig index 2744fa2825e0..c0f49fb3276c 100644 --- a/drivers/pinctrl/Kconfig +++ b/drivers/pinctrl/Kconfig | |||
@@ -256,6 +256,14 @@ config PINCTRL_IPQ8064 | |||
256 | This is the pinctrl, pinmux, pinconf and gpiolib driver for the | 256 | This is the pinctrl, pinmux, pinconf and gpiolib driver for the |
257 | Qualcomm TLMM block found in the Qualcomm IPQ8064 platform. | 257 | Qualcomm TLMM block found in the Qualcomm IPQ8064 platform. |
258 | 258 | ||
259 | config PINCTRL_MSM8960 | ||
260 | tristate "Qualcomm 8960 pin controller driver" | ||
261 | depends on GPIOLIB && OF | ||
262 | select PINCTRL_MSM | ||
263 | help | ||
264 | This is the pinctrl, pinmux, pinconf and gpiolib driver for the | ||
265 | Qualcomm TLMM block found in the Qualcomm 8960 platform. | ||
266 | |||
259 | config PINCTRL_MSM8X74 | 267 | config PINCTRL_MSM8X74 |
260 | tristate "Qualcomm 8x74 pin controller driver" | 268 | tristate "Qualcomm 8x74 pin controller driver" |
261 | depends on GPIOLIB && OF && (ARCH_QCOM || COMPILE_TEST) | 269 | depends on GPIOLIB && OF && (ARCH_QCOM || COMPILE_TEST) |
diff --git a/drivers/pinctrl/Makefile b/drivers/pinctrl/Makefile index c7d8f1b7311f..80bced77446a 100644 --- a/drivers/pinctrl/Makefile +++ b/drivers/pinctrl/Makefile | |||
@@ -42,6 +42,7 @@ obj-$(CONFIG_PINCTRL_IMX28) += pinctrl-imx28.o | |||
42 | obj-$(CONFIG_PINCTRL_MSM) += pinctrl-msm.o | 42 | obj-$(CONFIG_PINCTRL_MSM) += pinctrl-msm.o |
43 | obj-$(CONFIG_PINCTRL_APQ8064) += pinctrl-apq8064.o | 43 | obj-$(CONFIG_PINCTRL_APQ8064) += pinctrl-apq8064.o |
44 | obj-$(CONFIG_PINCTRL_IPQ8064) += pinctrl-ipq8064.o | 44 | obj-$(CONFIG_PINCTRL_IPQ8064) += pinctrl-ipq8064.o |
45 | obj-$(CONFIG_PINCTRL_MSM8960) += pinctrl-msm8960.o | ||
45 | obj-$(CONFIG_PINCTRL_MSM8X74) += pinctrl-msm8x74.o | 46 | obj-$(CONFIG_PINCTRL_MSM8X74) += pinctrl-msm8x74.o |
46 | obj-$(CONFIG_PINCTRL_NOMADIK) += pinctrl-nomadik.o | 47 | obj-$(CONFIG_PINCTRL_NOMADIK) += pinctrl-nomadik.o |
47 | obj-$(CONFIG_PINCTRL_STN8815) += pinctrl-nomadik-stn8815.o | 48 | obj-$(CONFIG_PINCTRL_STN8815) += pinctrl-nomadik-stn8815.o |
diff --git a/drivers/pinctrl/pinctrl-msm8960.c b/drivers/pinctrl/pinctrl-msm8960.c new file mode 100644 index 000000000000..564543bb2c1c --- /dev/null +++ b/drivers/pinctrl/pinctrl-msm8960.c | |||
@@ -0,0 +1,1254 @@ | |||
1 | /* | ||
2 | * Copyright (c) 2014, Sony Mobile Communications AB. | ||
3 | * | ||
4 | * This program is free software; you can redistribute it and/or modify | ||
5 | * it under the terms of the GNU General Public License version 2 and | ||
6 | * only version 2 as published by the Free Software Foundation. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | */ | ||
13 | |||
14 | #include <linux/module.h> | ||
15 | #include <linux/of.h> | ||
16 | #include <linux/platform_device.h> | ||
17 | #include <linux/pinctrl/pinctrl.h> | ||
18 | #include <linux/pinctrl/pinmux.h> | ||
19 | |||
20 | #include "pinctrl-msm.h" | ||
21 | |||
22 | static const struct pinctrl_pin_desc msm8960_pins[] = { | ||
23 | PINCTRL_PIN(0, "GPIO_0"), | ||
24 | PINCTRL_PIN(1, "GPIO_1"), | ||
25 | PINCTRL_PIN(2, "GPIO_2"), | ||
26 | PINCTRL_PIN(3, "GPIO_3"), | ||
27 | PINCTRL_PIN(4, "GPIO_4"), | ||
28 | PINCTRL_PIN(5, "GPIO_5"), | ||
29 | PINCTRL_PIN(6, "GPIO_6"), | ||
30 | PINCTRL_PIN(7, "GPIO_7"), | ||
31 | PINCTRL_PIN(8, "GPIO_8"), | ||
32 | PINCTRL_PIN(9, "GPIO_9"), | ||
33 | PINCTRL_PIN(10, "GPIO_10"), | ||
34 | PINCTRL_PIN(11, "GPIO_11"), | ||
35 | PINCTRL_PIN(12, "GPIO_12"), | ||
36 | PINCTRL_PIN(13, "GPIO_13"), | ||
37 | PINCTRL_PIN(14, "GPIO_14"), | ||
38 | PINCTRL_PIN(15, "GPIO_15"), | ||
39 | PINCTRL_PIN(16, "GPIO_16"), | ||
40 | PINCTRL_PIN(17, "GPIO_17"), | ||
41 | PINCTRL_PIN(18, "GPIO_18"), | ||
42 | PINCTRL_PIN(19, "GPIO_19"), | ||
43 | PINCTRL_PIN(20, "GPIO_20"), | ||
44 | PINCTRL_PIN(21, "GPIO_21"), | ||
45 | PINCTRL_PIN(22, "GPIO_22"), | ||
46 | PINCTRL_PIN(23, "GPIO_23"), | ||
47 | PINCTRL_PIN(24, "GPIO_24"), | ||
48 | PINCTRL_PIN(25, "GPIO_25"), | ||
49 | PINCTRL_PIN(26, "GPIO_26"), | ||
50 | PINCTRL_PIN(27, "GPIO_27"), | ||
51 | PINCTRL_PIN(28, "GPIO_28"), | ||
52 | PINCTRL_PIN(29, "GPIO_29"), | ||
53 | PINCTRL_PIN(30, "GPIO_30"), | ||
54 | PINCTRL_PIN(31, "GPIO_31"), | ||
55 | PINCTRL_PIN(32, "GPIO_32"), | ||
56 | PINCTRL_PIN(33, "GPIO_33"), | ||
57 | PINCTRL_PIN(34, "GPIO_34"), | ||
58 | PINCTRL_PIN(35, "GPIO_35"), | ||
59 | PINCTRL_PIN(36, "GPIO_36"), | ||
60 | PINCTRL_PIN(37, "GPIO_37"), | ||
61 | PINCTRL_PIN(38, "GPIO_38"), | ||
62 | PINCTRL_PIN(39, "GPIO_39"), | ||
63 | PINCTRL_PIN(40, "GPIO_40"), | ||
64 | PINCTRL_PIN(41, "GPIO_41"), | ||
65 | PINCTRL_PIN(42, "GPIO_42"), | ||
66 | PINCTRL_PIN(43, "GPIO_43"), | ||
67 | PINCTRL_PIN(44, "GPIO_44"), | ||
68 | PINCTRL_PIN(45, "GPIO_45"), | ||
69 | PINCTRL_PIN(46, "GPIO_46"), | ||
70 | PINCTRL_PIN(47, "GPIO_47"), | ||
71 | PINCTRL_PIN(48, "GPIO_48"), | ||
72 | PINCTRL_PIN(49, "GPIO_49"), | ||
73 | PINCTRL_PIN(50, "GPIO_50"), | ||
74 | PINCTRL_PIN(51, "GPIO_51"), | ||
75 | PINCTRL_PIN(52, "GPIO_52"), | ||
76 | PINCTRL_PIN(53, "GPIO_53"), | ||
77 | PINCTRL_PIN(54, "GPIO_54"), | ||
78 | PINCTRL_PIN(55, "GPIO_55"), | ||
79 | PINCTRL_PIN(56, "GPIO_56"), | ||
80 | PINCTRL_PIN(57, "GPIO_57"), | ||
81 | PINCTRL_PIN(58, "GPIO_58"), | ||
82 | PINCTRL_PIN(59, "GPIO_59"), | ||
83 | PINCTRL_PIN(60, "GPIO_60"), | ||
84 | PINCTRL_PIN(61, "GPIO_61"), | ||
85 | PINCTRL_PIN(62, "GPIO_62"), | ||
86 | PINCTRL_PIN(63, "GPIO_63"), | ||
87 | PINCTRL_PIN(64, "GPIO_64"), | ||
88 | PINCTRL_PIN(65, "GPIO_65"), | ||
89 | PINCTRL_PIN(66, "GPIO_66"), | ||
90 | PINCTRL_PIN(67, "GPIO_67"), | ||
91 | PINCTRL_PIN(68, "GPIO_68"), | ||
92 | PINCTRL_PIN(69, "GPIO_69"), | ||
93 | PINCTRL_PIN(70, "GPIO_70"), | ||
94 | PINCTRL_PIN(71, "GPIO_71"), | ||
95 | PINCTRL_PIN(72, "GPIO_72"), | ||
96 | PINCTRL_PIN(73, "GPIO_73"), | ||
97 | PINCTRL_PIN(74, "GPIO_74"), | ||
98 | PINCTRL_PIN(75, "GPIO_75"), | ||
99 | PINCTRL_PIN(76, "GPIO_76"), | ||
100 | PINCTRL_PIN(77, "GPIO_77"), | ||
101 | PINCTRL_PIN(78, "GPIO_78"), | ||
102 | PINCTRL_PIN(79, "GPIO_79"), | ||
103 | PINCTRL_PIN(80, "GPIO_80"), | ||
104 | PINCTRL_PIN(81, "GPIO_81"), | ||
105 | PINCTRL_PIN(82, "GPIO_82"), | ||
106 | PINCTRL_PIN(83, "GPIO_83"), | ||
107 | PINCTRL_PIN(84, "GPIO_84"), | ||
108 | PINCTRL_PIN(85, "GPIO_85"), | ||
109 | PINCTRL_PIN(86, "GPIO_86"), | ||
110 | PINCTRL_PIN(87, "GPIO_87"), | ||
111 | PINCTRL_PIN(88, "GPIO_88"), | ||
112 | PINCTRL_PIN(89, "GPIO_89"), | ||
113 | PINCTRL_PIN(90, "GPIO_90"), | ||
114 | PINCTRL_PIN(91, "GPIO_91"), | ||
115 | PINCTRL_PIN(92, "GPIO_92"), | ||
116 | PINCTRL_PIN(93, "GPIO_93"), | ||
117 | PINCTRL_PIN(94, "GPIO_94"), | ||
118 | PINCTRL_PIN(95, "GPIO_95"), | ||
119 | PINCTRL_PIN(96, "GPIO_96"), | ||
120 | PINCTRL_PIN(97, "GPIO_97"), | ||
121 | PINCTRL_PIN(98, "GPIO_98"), | ||
122 | PINCTRL_PIN(99, "GPIO_99"), | ||
123 | PINCTRL_PIN(100, "GPIO_100"), | ||
124 | PINCTRL_PIN(101, "GPIO_101"), | ||
125 | PINCTRL_PIN(102, "GPIO_102"), | ||
126 | PINCTRL_PIN(103, "GPIO_103"), | ||
127 | PINCTRL_PIN(104, "GPIO_104"), | ||
128 | PINCTRL_PIN(105, "GPIO_105"), | ||
129 | PINCTRL_PIN(106, "GPIO_106"), | ||
130 | PINCTRL_PIN(107, "GPIO_107"), | ||
131 | PINCTRL_PIN(108, "GPIO_108"), | ||
132 | PINCTRL_PIN(109, "GPIO_109"), | ||
133 | PINCTRL_PIN(110, "GPIO_110"), | ||
134 | PINCTRL_PIN(111, "GPIO_111"), | ||
135 | PINCTRL_PIN(112, "GPIO_112"), | ||
136 | PINCTRL_PIN(113, "GPIO_113"), | ||
137 | PINCTRL_PIN(114, "GPIO_114"), | ||
138 | PINCTRL_PIN(115, "GPIO_115"), | ||
139 | PINCTRL_PIN(116, "GPIO_116"), | ||
140 | PINCTRL_PIN(117, "GPIO_117"), | ||
141 | PINCTRL_PIN(118, "GPIO_118"), | ||
142 | PINCTRL_PIN(119, "GPIO_119"), | ||
143 | PINCTRL_PIN(120, "GPIO_120"), | ||
144 | PINCTRL_PIN(121, "GPIO_121"), | ||
145 | PINCTRL_PIN(122, "GPIO_122"), | ||
146 | PINCTRL_PIN(123, "GPIO_123"), | ||
147 | PINCTRL_PIN(124, "GPIO_124"), | ||
148 | PINCTRL_PIN(125, "GPIO_125"), | ||
149 | PINCTRL_PIN(126, "GPIO_126"), | ||
150 | PINCTRL_PIN(127, "GPIO_127"), | ||
151 | PINCTRL_PIN(128, "GPIO_128"), | ||
152 | PINCTRL_PIN(129, "GPIO_129"), | ||
153 | PINCTRL_PIN(130, "GPIO_130"), | ||
154 | PINCTRL_PIN(131, "GPIO_131"), | ||
155 | PINCTRL_PIN(132, "GPIO_132"), | ||
156 | PINCTRL_PIN(133, "GPIO_133"), | ||
157 | PINCTRL_PIN(134, "GPIO_134"), | ||
158 | PINCTRL_PIN(135, "GPIO_135"), | ||
159 | PINCTRL_PIN(136, "GPIO_136"), | ||
160 | PINCTRL_PIN(137, "GPIO_137"), | ||
161 | PINCTRL_PIN(138, "GPIO_138"), | ||
162 | PINCTRL_PIN(139, "GPIO_139"), | ||
163 | PINCTRL_PIN(140, "GPIO_140"), | ||
164 | PINCTRL_PIN(141, "GPIO_141"), | ||
165 | PINCTRL_PIN(142, "GPIO_142"), | ||
166 | PINCTRL_PIN(143, "GPIO_143"), | ||
167 | PINCTRL_PIN(144, "GPIO_144"), | ||
168 | PINCTRL_PIN(145, "GPIO_145"), | ||
169 | PINCTRL_PIN(146, "GPIO_146"), | ||
170 | PINCTRL_PIN(147, "GPIO_147"), | ||
171 | PINCTRL_PIN(148, "GPIO_148"), | ||
172 | PINCTRL_PIN(149, "GPIO_149"), | ||
173 | PINCTRL_PIN(150, "GPIO_150"), | ||
174 | PINCTRL_PIN(151, "GPIO_151"), | ||
175 | |||
176 | PINCTRL_PIN(152, "SDC1_CLK"), | ||
177 | PINCTRL_PIN(153, "SDC1_CMD"), | ||
178 | PINCTRL_PIN(154, "SDC1_DATA"), | ||
179 | PINCTRL_PIN(155, "SDC3_CLK"), | ||
180 | PINCTRL_PIN(156, "SDC3_CMD"), | ||
181 | PINCTRL_PIN(157, "SDC3_DATA"), | ||
182 | }; | ||
183 | |||
184 | #define DECLARE_MSM_GPIO_PINS(pin) static const unsigned int gpio##pin##_pins[] = { pin } | ||
185 | DECLARE_MSM_GPIO_PINS(0); | ||
186 | DECLARE_MSM_GPIO_PINS(1); | ||
187 | DECLARE_MSM_GPIO_PINS(2); | ||
188 | DECLARE_MSM_GPIO_PINS(3); | ||
189 | DECLARE_MSM_GPIO_PINS(4); | ||
190 | DECLARE_MSM_GPIO_PINS(5); | ||
191 | DECLARE_MSM_GPIO_PINS(6); | ||
192 | DECLARE_MSM_GPIO_PINS(7); | ||
193 | DECLARE_MSM_GPIO_PINS(8); | ||
194 | DECLARE_MSM_GPIO_PINS(9); | ||
195 | DECLARE_MSM_GPIO_PINS(10); | ||
196 | DECLARE_MSM_GPIO_PINS(11); | ||
197 | DECLARE_MSM_GPIO_PINS(12); | ||
198 | DECLARE_MSM_GPIO_PINS(13); | ||
199 | DECLARE_MSM_GPIO_PINS(14); | ||
200 | DECLARE_MSM_GPIO_PINS(15); | ||
201 | DECLARE_MSM_GPIO_PINS(16); | ||
202 | DECLARE_MSM_GPIO_PINS(17); | ||
203 | DECLARE_MSM_GPIO_PINS(18); | ||
204 | DECLARE_MSM_GPIO_PINS(19); | ||
205 | DECLARE_MSM_GPIO_PINS(20); | ||
206 | DECLARE_MSM_GPIO_PINS(21); | ||
207 | DECLARE_MSM_GPIO_PINS(22); | ||
208 | DECLARE_MSM_GPIO_PINS(23); | ||
209 | DECLARE_MSM_GPIO_PINS(24); | ||
210 | DECLARE_MSM_GPIO_PINS(25); | ||
211 | DECLARE_MSM_GPIO_PINS(26); | ||
212 | DECLARE_MSM_GPIO_PINS(27); | ||
213 | DECLARE_MSM_GPIO_PINS(28); | ||
214 | DECLARE_MSM_GPIO_PINS(29); | ||
215 | DECLARE_MSM_GPIO_PINS(30); | ||
216 | DECLARE_MSM_GPIO_PINS(31); | ||
217 | DECLARE_MSM_GPIO_PINS(32); | ||
218 | DECLARE_MSM_GPIO_PINS(33); | ||
219 | DECLARE_MSM_GPIO_PINS(34); | ||
220 | DECLARE_MSM_GPIO_PINS(35); | ||
221 | DECLARE_MSM_GPIO_PINS(36); | ||
222 | DECLARE_MSM_GPIO_PINS(37); | ||
223 | DECLARE_MSM_GPIO_PINS(38); | ||
224 | DECLARE_MSM_GPIO_PINS(39); | ||
225 | DECLARE_MSM_GPIO_PINS(40); | ||
226 | DECLARE_MSM_GPIO_PINS(41); | ||
227 | DECLARE_MSM_GPIO_PINS(42); | ||
228 | DECLARE_MSM_GPIO_PINS(43); | ||
229 | DECLARE_MSM_GPIO_PINS(44); | ||
230 | DECLARE_MSM_GPIO_PINS(45); | ||
231 | DECLARE_MSM_GPIO_PINS(46); | ||
232 | DECLARE_MSM_GPIO_PINS(47); | ||
233 | DECLARE_MSM_GPIO_PINS(48); | ||
234 | DECLARE_MSM_GPIO_PINS(49); | ||
235 | DECLARE_MSM_GPIO_PINS(50); | ||
236 | DECLARE_MSM_GPIO_PINS(51); | ||
237 | DECLARE_MSM_GPIO_PINS(52); | ||
238 | DECLARE_MSM_GPIO_PINS(53); | ||
239 | DECLARE_MSM_GPIO_PINS(54); | ||
240 | DECLARE_MSM_GPIO_PINS(55); | ||
241 | DECLARE_MSM_GPIO_PINS(56); | ||
242 | DECLARE_MSM_GPIO_PINS(57); | ||
243 | DECLARE_MSM_GPIO_PINS(58); | ||
244 | DECLARE_MSM_GPIO_PINS(59); | ||
245 | DECLARE_MSM_GPIO_PINS(60); | ||
246 | DECLARE_MSM_GPIO_PINS(61); | ||
247 | DECLARE_MSM_GPIO_PINS(62); | ||
248 | DECLARE_MSM_GPIO_PINS(63); | ||
249 | DECLARE_MSM_GPIO_PINS(64); | ||
250 | DECLARE_MSM_GPIO_PINS(65); | ||
251 | DECLARE_MSM_GPIO_PINS(66); | ||
252 | DECLARE_MSM_GPIO_PINS(67); | ||
253 | DECLARE_MSM_GPIO_PINS(68); | ||
254 | DECLARE_MSM_GPIO_PINS(69); | ||
255 | DECLARE_MSM_GPIO_PINS(70); | ||
256 | DECLARE_MSM_GPIO_PINS(71); | ||
257 | DECLARE_MSM_GPIO_PINS(72); | ||
258 | DECLARE_MSM_GPIO_PINS(73); | ||
259 | DECLARE_MSM_GPIO_PINS(74); | ||
260 | DECLARE_MSM_GPIO_PINS(75); | ||
261 | DECLARE_MSM_GPIO_PINS(76); | ||
262 | DECLARE_MSM_GPIO_PINS(77); | ||
263 | DECLARE_MSM_GPIO_PINS(78); | ||
264 | DECLARE_MSM_GPIO_PINS(79); | ||
265 | DECLARE_MSM_GPIO_PINS(80); | ||
266 | DECLARE_MSM_GPIO_PINS(81); | ||
267 | DECLARE_MSM_GPIO_PINS(82); | ||
268 | DECLARE_MSM_GPIO_PINS(83); | ||
269 | DECLARE_MSM_GPIO_PINS(84); | ||
270 | DECLARE_MSM_GPIO_PINS(85); | ||
271 | DECLARE_MSM_GPIO_PINS(86); | ||
272 | DECLARE_MSM_GPIO_PINS(87); | ||
273 | DECLARE_MSM_GPIO_PINS(88); | ||
274 | DECLARE_MSM_GPIO_PINS(89); | ||
275 | DECLARE_MSM_GPIO_PINS(90); | ||
276 | DECLARE_MSM_GPIO_PINS(91); | ||
277 | DECLARE_MSM_GPIO_PINS(92); | ||
278 | DECLARE_MSM_GPIO_PINS(93); | ||
279 | DECLARE_MSM_GPIO_PINS(94); | ||
280 | DECLARE_MSM_GPIO_PINS(95); | ||
281 | DECLARE_MSM_GPIO_PINS(96); | ||
282 | DECLARE_MSM_GPIO_PINS(97); | ||
283 | DECLARE_MSM_GPIO_PINS(98); | ||
284 | DECLARE_MSM_GPIO_PINS(99); | ||
285 | DECLARE_MSM_GPIO_PINS(100); | ||
286 | DECLARE_MSM_GPIO_PINS(101); | ||
287 | DECLARE_MSM_GPIO_PINS(102); | ||
288 | DECLARE_MSM_GPIO_PINS(103); | ||
289 | DECLARE_MSM_GPIO_PINS(104); | ||
290 | DECLARE_MSM_GPIO_PINS(105); | ||
291 | DECLARE_MSM_GPIO_PINS(106); | ||
292 | DECLARE_MSM_GPIO_PINS(107); | ||
293 | DECLARE_MSM_GPIO_PINS(108); | ||
294 | DECLARE_MSM_GPIO_PINS(109); | ||
295 | DECLARE_MSM_GPIO_PINS(110); | ||
296 | DECLARE_MSM_GPIO_PINS(111); | ||
297 | DECLARE_MSM_GPIO_PINS(112); | ||
298 | DECLARE_MSM_GPIO_PINS(113); | ||
299 | DECLARE_MSM_GPIO_PINS(114); | ||
300 | DECLARE_MSM_GPIO_PINS(115); | ||
301 | DECLARE_MSM_GPIO_PINS(116); | ||
302 | DECLARE_MSM_GPIO_PINS(117); | ||
303 | DECLARE_MSM_GPIO_PINS(118); | ||
304 | DECLARE_MSM_GPIO_PINS(119); | ||
305 | DECLARE_MSM_GPIO_PINS(120); | ||
306 | DECLARE_MSM_GPIO_PINS(121); | ||
307 | DECLARE_MSM_GPIO_PINS(122); | ||
308 | DECLARE_MSM_GPIO_PINS(123); | ||
309 | DECLARE_MSM_GPIO_PINS(124); | ||
310 | DECLARE_MSM_GPIO_PINS(125); | ||
311 | DECLARE_MSM_GPIO_PINS(126); | ||
312 | DECLARE_MSM_GPIO_PINS(127); | ||
313 | DECLARE_MSM_GPIO_PINS(128); | ||
314 | DECLARE_MSM_GPIO_PINS(129); | ||
315 | DECLARE_MSM_GPIO_PINS(130); | ||
316 | DECLARE_MSM_GPIO_PINS(131); | ||
317 | DECLARE_MSM_GPIO_PINS(132); | ||
318 | DECLARE_MSM_GPIO_PINS(133); | ||
319 | DECLARE_MSM_GPIO_PINS(134); | ||
320 | DECLARE_MSM_GPIO_PINS(135); | ||
321 | DECLARE_MSM_GPIO_PINS(136); | ||
322 | DECLARE_MSM_GPIO_PINS(137); | ||
323 | DECLARE_MSM_GPIO_PINS(138); | ||
324 | DECLARE_MSM_GPIO_PINS(139); | ||
325 | DECLARE_MSM_GPIO_PINS(140); | ||
326 | DECLARE_MSM_GPIO_PINS(141); | ||
327 | DECLARE_MSM_GPIO_PINS(142); | ||
328 | DECLARE_MSM_GPIO_PINS(143); | ||
329 | DECLARE_MSM_GPIO_PINS(144); | ||
330 | DECLARE_MSM_GPIO_PINS(145); | ||
331 | DECLARE_MSM_GPIO_PINS(146); | ||
332 | DECLARE_MSM_GPIO_PINS(147); | ||
333 | DECLARE_MSM_GPIO_PINS(148); | ||
334 | DECLARE_MSM_GPIO_PINS(149); | ||
335 | DECLARE_MSM_GPIO_PINS(150); | ||
336 | DECLARE_MSM_GPIO_PINS(151); | ||
337 | |||
338 | static const unsigned int sdc1_clk_pins[] = { 152 }; | ||
339 | static const unsigned int sdc1_cmd_pins[] = { 153 }; | ||
340 | static const unsigned int sdc1_data_pins[] = { 154 }; | ||
341 | static const unsigned int sdc3_clk_pins[] = { 155 }; | ||
342 | static const unsigned int sdc3_cmd_pins[] = { 156 }; | ||
343 | static const unsigned int sdc3_data_pins[] = { 157 }; | ||
344 | |||
345 | #define FUNCTION(fname) \ | ||
346 | [MSM_MUX_##fname] = { \ | ||
347 | .name = #fname, \ | ||
348 | .groups = fname##_groups, \ | ||
349 | .ngroups = ARRAY_SIZE(fname##_groups), \ | ||
350 | } | ||
351 | |||
352 | #define PINGROUP(id, f1, f2, f3, f4, f5, f6, f7, f8, f9, f10, f11) \ | ||
353 | { \ | ||
354 | .name = "gpio" #id, \ | ||
355 | .pins = gpio##id##_pins, \ | ||
356 | .npins = ARRAY_SIZE(gpio##id##_pins), \ | ||
357 | .funcs = (int[]){ \ | ||
358 | MSM_MUX_NA, /* gpio mode */ \ | ||
359 | MSM_MUX_##f1, \ | ||
360 | MSM_MUX_##f2, \ | ||
361 | MSM_MUX_##f3, \ | ||
362 | MSM_MUX_##f4, \ | ||
363 | MSM_MUX_##f5, \ | ||
364 | MSM_MUX_##f6, \ | ||
365 | MSM_MUX_##f7, \ | ||
366 | MSM_MUX_##f8, \ | ||
367 | MSM_MUX_##f9, \ | ||
368 | MSM_MUX_##f10, \ | ||
369 | MSM_MUX_##f11 \ | ||
370 | }, \ | ||
371 | .nfuncs = 12, \ | ||
372 | .ctl_reg = 0x1000 + 0x10 * id, \ | ||
373 | .io_reg = 0x1004 + 0x10 * id, \ | ||
374 | .intr_cfg_reg = 0x1008 + 0x10 * id, \ | ||
375 | .intr_status_reg = 0x100c + 0x10 * id, \ | ||
376 | .intr_target_reg = 0x400 + 0x4 * id, \ | ||
377 | .mux_bit = 2, \ | ||
378 | .pull_bit = 0, \ | ||
379 | .drv_bit = 6, \ | ||
380 | .oe_bit = 9, \ | ||
381 | .in_bit = 0, \ | ||
382 | .out_bit = 1, \ | ||
383 | .intr_enable_bit = 0, \ | ||
384 | .intr_status_bit = 0, \ | ||
385 | .intr_ack_high = 1, \ | ||
386 | .intr_target_bit = 0, \ | ||
387 | .intr_raw_status_bit = 3, \ | ||
388 | .intr_polarity_bit = 1, \ | ||
389 | .intr_detection_bit = 2, \ | ||
390 | .intr_detection_width = 1, \ | ||
391 | } | ||
392 | |||
393 | #define SDC_PINGROUP(pg_name, ctl, pull, drv) \ | ||
394 | { \ | ||
395 | .name = #pg_name, \ | ||
396 | .pins = pg_name##_pins, \ | ||
397 | .npins = ARRAY_SIZE(pg_name##_pins), \ | ||
398 | .ctl_reg = ctl, \ | ||
399 | .io_reg = 0, \ | ||
400 | .intr_cfg_reg = 0, \ | ||
401 | .intr_status_reg = 0, \ | ||
402 | .intr_target_reg = 0, \ | ||
403 | .mux_bit = -1, \ | ||
404 | .pull_bit = pull, \ | ||
405 | .drv_bit = drv, \ | ||
406 | .oe_bit = -1, \ | ||
407 | .in_bit = -1, \ | ||
408 | .out_bit = -1, \ | ||
409 | .intr_enable_bit = -1, \ | ||
410 | .intr_status_bit = -1, \ | ||
411 | .intr_target_bit = -1, \ | ||
412 | .intr_raw_status_bit = -1, \ | ||
413 | .intr_polarity_bit = -1, \ | ||
414 | .intr_detection_bit = -1, \ | ||
415 | .intr_detection_width = -1, \ | ||
416 | } | ||
417 | |||
418 | enum msm8960_functions { | ||
419 | MSM_MUX_audio_pcm, | ||
420 | MSM_MUX_bt, | ||
421 | MSM_MUX_cam_mclk0, | ||
422 | MSM_MUX_cam_mclk1, | ||
423 | MSM_MUX_cam_mclk2, | ||
424 | MSM_MUX_codec_mic_i2s, | ||
425 | MSM_MUX_codec_spkr_i2s, | ||
426 | MSM_MUX_ext_gps, | ||
427 | MSM_MUX_fm, | ||
428 | MSM_MUX_gps_blanking, | ||
429 | MSM_MUX_gps_pps_in, | ||
430 | MSM_MUX_gps_pps_out, | ||
431 | MSM_MUX_gp_clk_0a, | ||
432 | MSM_MUX_gp_clk_0b, | ||
433 | MSM_MUX_gp_clk_1a, | ||
434 | MSM_MUX_gp_clk_1b, | ||
435 | MSM_MUX_gp_clk_2a, | ||
436 | MSM_MUX_gp_clk_2b, | ||
437 | MSM_MUX_gp_mn, | ||
438 | MSM_MUX_gp_pdm_0a, | ||
439 | MSM_MUX_gp_pdm_0b, | ||
440 | MSM_MUX_gp_pdm_1a, | ||
441 | MSM_MUX_gp_pdm_1b, | ||
442 | MSM_MUX_gp_pdm_2a, | ||
443 | MSM_MUX_gp_pdm_2b, | ||
444 | MSM_MUX_gsbi1, | ||
445 | MSM_MUX_gsbi1_spi_cs1_n, | ||
446 | MSM_MUX_gsbi1_spi_cs2a_n, | ||
447 | MSM_MUX_gsbi1_spi_cs2b_n, | ||
448 | MSM_MUX_gsbi1_spi_cs3_n, | ||
449 | MSM_MUX_gsbi2, | ||
450 | MSM_MUX_gsbi2_spi_cs1_n, | ||
451 | MSM_MUX_gsbi2_spi_cs2_n, | ||
452 | MSM_MUX_gsbi2_spi_cs3_n, | ||
453 | MSM_MUX_gsbi3, | ||
454 | MSM_MUX_gsbi4, | ||
455 | MSM_MUX_gsbi4_3d_cam_i2c_l, | ||
456 | MSM_MUX_gsbi4_3d_cam_i2c_r, | ||
457 | MSM_MUX_gsbi5, | ||
458 | MSM_MUX_gsbi5_3d_cam_i2c_l, | ||
459 | MSM_MUX_gsbi5_3d_cam_i2c_r, | ||
460 | MSM_MUX_gsbi6, | ||
461 | MSM_MUX_gsbi7, | ||
462 | MSM_MUX_gsbi8, | ||
463 | MSM_MUX_gsbi9, | ||
464 | MSM_MUX_gsbi10, | ||
465 | MSM_MUX_gsbi11, | ||
466 | MSM_MUX_gsbi11_spi_cs1a_n, | ||
467 | MSM_MUX_gsbi11_spi_cs1b_n, | ||
468 | MSM_MUX_gsbi11_spi_cs2a_n, | ||
469 | MSM_MUX_gsbi11_spi_cs2b_n, | ||
470 | MSM_MUX_gsbi11_spi_cs3_n, | ||
471 | MSM_MUX_gsbi12, | ||
472 | MSM_MUX_hdmi_cec, | ||
473 | MSM_MUX_hdmi_ddc_clock, | ||
474 | MSM_MUX_hdmi_ddc_data, | ||
475 | MSM_MUX_hdmi_hot_plug_detect, | ||
476 | MSM_MUX_hsic, | ||
477 | MSM_MUX_mdp_vsync, | ||
478 | MSM_MUX_mi2s, | ||
479 | MSM_MUX_mic_i2s, | ||
480 | MSM_MUX_pmb_clk, | ||
481 | MSM_MUX_pmb_ext_ctrl, | ||
482 | MSM_MUX_ps_hold, | ||
483 | MSM_MUX_rpm_wdog, | ||
484 | MSM_MUX_sdc2, | ||
485 | MSM_MUX_sdc4, | ||
486 | MSM_MUX_sdc5, | ||
487 | MSM_MUX_slimbus1, | ||
488 | MSM_MUX_slimbus2, | ||
489 | MSM_MUX_spkr_i2s, | ||
490 | MSM_MUX_ssbi1, | ||
491 | MSM_MUX_ssbi2, | ||
492 | MSM_MUX_ssbi_ext_gps, | ||
493 | MSM_MUX_ssbi_pmic2, | ||
494 | MSM_MUX_ssbi_qpa1, | ||
495 | MSM_MUX_ssbi_ts, | ||
496 | MSM_MUX_tsif1, | ||
497 | MSM_MUX_tsif2, | ||
498 | MSM_MUX_ts_eoc, | ||
499 | MSM_MUX_usb_fs1, | ||
500 | MSM_MUX_usb_fs1_oe, | ||
501 | MSM_MUX_usb_fs1_oe_n, | ||
502 | MSM_MUX_usb_fs2, | ||
503 | MSM_MUX_usb_fs2_oe, | ||
504 | MSM_MUX_usb_fs2_oe_n, | ||
505 | MSM_MUX_vfe_camif_timer1_a, | ||
506 | MSM_MUX_vfe_camif_timer1_b, | ||
507 | MSM_MUX_vfe_camif_timer2, | ||
508 | MSM_MUX_vfe_camif_timer3_a, | ||
509 | MSM_MUX_vfe_camif_timer3_b, | ||
510 | MSM_MUX_vfe_camif_timer4_a, | ||
511 | MSM_MUX_vfe_camif_timer4_b, | ||
512 | MSM_MUX_vfe_camif_timer4_c, | ||
513 | MSM_MUX_vfe_camif_timer5_a, | ||
514 | MSM_MUX_vfe_camif_timer5_b, | ||
515 | MSM_MUX_vfe_camif_timer6_a, | ||
516 | MSM_MUX_vfe_camif_timer6_b, | ||
517 | MSM_MUX_vfe_camif_timer6_c, | ||
518 | MSM_MUX_vfe_camif_timer7_a, | ||
519 | MSM_MUX_vfe_camif_timer7_b, | ||
520 | MSM_MUX_vfe_camif_timer7_c, | ||
521 | MSM_MUX_wlan, | ||
522 | MSM_MUX_NA, | ||
523 | }; | ||
524 | |||
525 | static const char * const audio_pcm_groups[] = { | ||
526 | "gpio63", "gpio64", "gpio65", "gpio66" | ||
527 | }; | ||
528 | |||
529 | static const char * const bt_groups[] = { | ||
530 | "gpio28", "gpio29", "gpio83" | ||
531 | }; | ||
532 | |||
533 | static const char * const cam_mclk0_groups[] = { | ||
534 | "gpio5" | ||
535 | }; | ||
536 | |||
537 | static const char * const cam_mclk1_groups[] = { | ||
538 | "gpio4" | ||
539 | }; | ||
540 | |||
541 | static const char * const cam_mclk2_groups[] = { | ||
542 | "gpio2" | ||
543 | }; | ||
544 | |||
545 | static const char * const codec_mic_i2s_groups[] = { | ||
546 | "gpio54", "gpio55", "gpio56", "gpio57", "gpio58" | ||
547 | }; | ||
548 | |||
549 | static const char * const codec_spkr_i2s_groups[] = { | ||
550 | "gpio59", "gpio60", "gpio61", "gpio62" | ||
551 | }; | ||
552 | |||
553 | static const char * const ext_gps_groups[] = { | ||
554 | "gpio22", "gpio23", "gpio24", "gpio25" | ||
555 | }; | ||
556 | |||
557 | static const char * const fm_groups[] = { | ||
558 | "gpio26", "gpio27" | ||
559 | }; | ||
560 | |||
561 | static const char * const gps_blanking_groups[] = { | ||
562 | "gpio137" | ||
563 | }; | ||
564 | |||
565 | static const char * const gps_pps_in_groups[] = { | ||
566 | "gpio37" | ||
567 | }; | ||
568 | |||
569 | static const char * const gps_pps_out_groups[] = { | ||
570 | "gpio37" | ||
571 | }; | ||
572 | |||
573 | static const char * const gp_clk_0a_groups[] = { | ||
574 | "gpio3" | ||
575 | }; | ||
576 | |||
577 | static const char * const gp_clk_0b_groups[] = { | ||
578 | "gpio54" | ||
579 | }; | ||
580 | |||
581 | static const char * const gp_clk_1a_groups[] = { | ||
582 | "gpio4" | ||
583 | }; | ||
584 | |||
585 | static const char * const gp_clk_1b_groups[] = { | ||
586 | "gpio70" | ||
587 | }; | ||
588 | |||
589 | static const char * const gp_clk_2a_groups[] = { | ||
590 | "gpio52" | ||
591 | }; | ||
592 | |||
593 | static const char * const gp_clk_2b_groups[] = { | ||
594 | "gpio37" | ||
595 | }; | ||
596 | |||
597 | static const char * const gp_mn_groups[] = { | ||
598 | "gpio2" | ||
599 | }; | ||
600 | |||
601 | static const char * const gp_pdm_0a_groups[] = { | ||
602 | "gpio58" | ||
603 | }; | ||
604 | |||
605 | static const char * const gp_pdm_0b_groups[] = { | ||
606 | "gpio39" | ||
607 | }; | ||
608 | |||
609 | static const char * const gp_pdm_1a_groups[] = { | ||
610 | "gpio94" | ||
611 | }; | ||
612 | |||
613 | static const char * const gp_pdm_1b_groups[] = { | ||
614 | "gpio64" | ||
615 | }; | ||
616 | |||
617 | static const char * const gp_pdm_2a_groups[] = { | ||
618 | "gpio69" | ||
619 | }; | ||
620 | |||
621 | static const char * const gp_pdm_2b_groups[] = { | ||
622 | "gpio53" | ||
623 | }; | ||
624 | |||
625 | static const char * const gsbi1_groups[] = { | ||
626 | "gpio6", "gpio7", "gpio8", "gpio9" | ||
627 | }; | ||
628 | |||
629 | static const char * const gsbi1_spi_cs1_n_groups[] = { | ||
630 | "gpio14" | ||
631 | }; | ||
632 | |||
633 | static const char * const gsbi1_spi_cs2a_n_groups[] = { | ||
634 | "gpio15" | ||
635 | }; | ||
636 | |||
637 | static const char * const gsbi1_spi_cs2b_n_groups[] = { | ||
638 | "gpio17" | ||
639 | }; | ||
640 | |||
641 | static const char * const gsbi1_spi_cs3_n_groups[] = { | ||
642 | "gpio16" | ||
643 | }; | ||
644 | |||
645 | static const char * const gsbi2_groups[] = { | ||
646 | "gpio10", "gpio11", "gpio12", "gpio13" | ||
647 | }; | ||
648 | |||
649 | static const char * const gsbi2_spi_cs1_n_groups[] = { | ||
650 | "gpio52" | ||
651 | }; | ||
652 | |||
653 | static const char * const gsbi2_spi_cs2_n_groups[] = { | ||
654 | "gpio68" | ||
655 | }; | ||
656 | |||
657 | static const char * const gsbi2_spi_cs3_n_groups[] = { | ||
658 | "gpio56" | ||
659 | }; | ||
660 | |||
661 | static const char * const gsbi3_groups[] = { | ||
662 | "gpio14", "gpio15", "gpio16", "gpio17" | ||
663 | }; | ||
664 | |||
665 | static const char * const gsbi4_groups[] = { | ||
666 | "gpio18", "gpio19", "gpio20", "gpio21" | ||
667 | }; | ||
668 | |||
669 | static const char * const gsbi4_3d_cam_i2c_l_groups[] = { | ||
670 | "gpio18", "gpio19" | ||
671 | }; | ||
672 | |||
673 | static const char * const gsbi4_3d_cam_i2c_r_groups[] = { | ||
674 | "gpio20", "gpio21" | ||
675 | }; | ||
676 | |||
677 | static const char * const gsbi5_groups[] = { | ||
678 | "gpio22", "gpio23", "gpio24", "gpio25" | ||
679 | }; | ||
680 | |||
681 | static const char * const gsbi5_3d_cam_i2c_l_groups[] = { | ||
682 | "gpio22", "gpio23" | ||
683 | }; | ||
684 | |||
685 | static const char * const gsbi5_3d_cam_i2c_r_groups[] = { | ||
686 | "gpio24", "gpio25" | ||
687 | }; | ||
688 | |||
689 | static const char * const gsbi6_groups[] = { | ||
690 | "gpio26", "gpio27", "gpio28", "gpio29" | ||
691 | }; | ||
692 | |||
693 | static const char * const gsbi7_groups[] = { | ||
694 | "gpio30", "gpio31", "gpio32", "gpio33" | ||
695 | }; | ||
696 | |||
697 | static const char * const gsbi8_groups[] = { | ||
698 | "gpio34", "gpio35", "gpio36", "gpio37" | ||
699 | }; | ||
700 | |||
701 | static const char * const gsbi9_groups[] = { | ||
702 | "gpio93", "gpio94", "gpio95", "gpio96" | ||
703 | }; | ||
704 | |||
705 | static const char * const gsbi10_groups[] = { | ||
706 | "gpio71", "gpio72", "gpio73", "gpio74" | ||
707 | }; | ||
708 | |||
709 | static const char * const gsbi11_groups[] = { | ||
710 | "gpio38", "gpio39", "gpio40", "gpio41" | ||
711 | }; | ||
712 | |||
713 | static const char * const gsbi11_spi_cs1a_n_groups[] = { | ||
714 | "gpio36" | ||
715 | }; | ||
716 | |||
717 | static const char * const gsbi11_spi_cs1b_n_groups[] = { | ||
718 | "gpio18" | ||
719 | }; | ||
720 | |||
721 | static const char * const gsbi11_spi_cs2a_n_groups[] = { | ||
722 | "gpio37" | ||
723 | }; | ||
724 | |||
725 | static const char * const gsbi11_spi_cs2b_n_groups[] = { | ||
726 | "gpio19" | ||
727 | }; | ||
728 | |||
729 | static const char * const gsbi11_spi_cs3_n_groups[] = { | ||
730 | "gpio76" | ||
731 | }; | ||
732 | |||
733 | static const char * const gsbi12_groups[] = { | ||
734 | "gpio42", "gpio43", "gpio44", "gpio45" | ||
735 | }; | ||
736 | |||
737 | static const char * const hdmi_cec_groups[] = { | ||
738 | "gpio99" | ||
739 | }; | ||
740 | |||
741 | static const char * const hdmi_ddc_clock_groups[] = { | ||
742 | "gpio100" | ||
743 | }; | ||
744 | |||
745 | static const char * const hdmi_ddc_data_groups[] = { | ||
746 | "gpio101" | ||
747 | }; | ||
748 | |||
749 | static const char * const hdmi_hot_plug_detect_groups[] = { | ||
750 | "gpio102" | ||
751 | }; | ||
752 | |||
753 | static const char * const hsic_groups[] = { | ||
754 | "gpio150", "gpio151" | ||
755 | }; | ||
756 | |||
757 | static const char * const mdp_vsync_groups[] = { | ||
758 | "gpio0", "gpio1", "gpio19" | ||
759 | }; | ||
760 | |||
761 | static const char * const mi2s_groups[] = { | ||
762 | "gpio47", "gpio48", "gpio49", "gpio50", "gpio51", "gpio52", "gpio53" | ||
763 | }; | ||
764 | |||
765 | static const char * const mic_i2s_groups[] = { | ||
766 | "gpio71", "gpio72", "gpio73", "gpio74" | ||
767 | }; | ||
768 | |||
769 | static const char * const pmb_clk_groups[] = { | ||
770 | "gpio21", "gpio86", "gpio112" | ||
771 | }; | ||
772 | |||
773 | static const char * const pmb_ext_ctrl_groups[] = { | ||
774 | "gpio4", "gpio5" | ||
775 | }; | ||
776 | |||
777 | static const char * const ps_hold_groups[] = { | ||
778 | "gpio108" | ||
779 | }; | ||
780 | |||
781 | static const char * const rpm_wdog_groups[] = { | ||
782 | "gpio12" | ||
783 | }; | ||
784 | |||
785 | static const char * const sdc2_groups[] = { | ||
786 | "gpio89", "gpio90", "gpio91", "gpio92", "gpio93", "gpio94", "gpio95", | ||
787 | "gpio96", "gpio97", "gpio98" | ||
788 | }; | ||
789 | |||
790 | static const char * const sdc4_groups[] = { | ||
791 | "gpio83", "gpio84", "gpio85", "gpio86", "gpio87", "gpio88" | ||
792 | }; | ||
793 | |||
794 | static const char * const sdc5_groups[] = { | ||
795 | "gpio77", "gpio78", "gpio79", "gpio80", "gpio81", "gpio82" | ||
796 | }; | ||
797 | |||
798 | static const char * const slimbus1_groups[] = { | ||
799 | "gpio50", "gpio51", "gpio60", "gpio61" | ||
800 | }; | ||
801 | |||
802 | static const char * const slimbus2_groups[] = { | ||
803 | "gpio42", "gpio43" | ||
804 | }; | ||
805 | |||
806 | static const char * const spkr_i2s_groups[] = { | ||
807 | "gpio67", "gpio68", "gpio69", "gpio70" | ||
808 | }; | ||
809 | |||
810 | static const char * const ssbi1_groups[] = { | ||
811 | "gpio141", "gpio143" | ||
812 | }; | ||
813 | |||
814 | static const char * const ssbi2_groups[] = { | ||
815 | "gpio140", "gpio142" | ||
816 | }; | ||
817 | |||
818 | static const char * const ssbi_ext_gps_groups[] = { | ||
819 | "gpio23" | ||
820 | }; | ||
821 | |||
822 | static const char * const ssbi_pmic2_groups[] = { | ||
823 | "gpio149" | ||
824 | }; | ||
825 | |||
826 | static const char * const ssbi_qpa1_groups[] = { | ||
827 | "gpio131" | ||
828 | }; | ||
829 | |||
830 | static const char * const ssbi_ts_groups[] = { | ||
831 | "gpio10" | ||
832 | }; | ||
833 | |||
834 | static const char * const tsif1_groups[] = { | ||
835 | "gpio75", "gpio76", "gpio77", "gpio82" | ||
836 | }; | ||
837 | |||
838 | static const char * const tsif2_groups[] = { | ||
839 | "gpio78", "gpio79", "gpio80", "gpio81" | ||
840 | }; | ||
841 | |||
842 | static const char * const ts_eoc_groups[] = { | ||
843 | "gpio11" | ||
844 | }; | ||
845 | |||
846 | static const char * const usb_fs1_groups[] = { | ||
847 | "gpio32", "gpio33" | ||
848 | }; | ||
849 | |||
850 | static const char * const usb_fs1_oe_groups[] = { | ||
851 | "gpio31" | ||
852 | }; | ||
853 | |||
854 | static const char * const usb_fs1_oe_n_groups[] = { | ||
855 | "gpio31" | ||
856 | }; | ||
857 | |||
858 | static const char * const usb_fs2_groups[] = { | ||
859 | "gpio34", "gpio35" | ||
860 | }; | ||
861 | |||
862 | static const char * const usb_fs2_oe_groups[] = { | ||
863 | "gpio36" | ||
864 | }; | ||
865 | |||
866 | static const char * const usb_fs2_oe_n_groups[] = { | ||
867 | "gpio36" | ||
868 | }; | ||
869 | |||
870 | static const char * const vfe_camif_timer1_a_groups[] = { | ||
871 | "gpio2" | ||
872 | }; | ||
873 | |||
874 | static const char * const vfe_camif_timer1_b_groups[] = { | ||
875 | "gpio38" | ||
876 | }; | ||
877 | |||
878 | static const char * const vfe_camif_timer2_groups[] = { | ||
879 | "gpio3" | ||
880 | }; | ||
881 | |||
882 | static const char * const vfe_camif_timer3_a_groups[] = { | ||
883 | "gpio4" | ||
884 | }; | ||
885 | |||
886 | static const char * const vfe_camif_timer3_b_groups[] = { | ||
887 | "gpio151" | ||
888 | }; | ||
889 | |||
890 | static const char * const vfe_camif_timer4_a_groups[] = { | ||
891 | "gpio65" | ||
892 | }; | ||
893 | |||
894 | static const char * const vfe_camif_timer4_b_groups[] = { | ||
895 | "gpio150" | ||
896 | }; | ||
897 | |||
898 | static const char * const vfe_camif_timer4_c_groups[] = { | ||
899 | "gpio10" | ||
900 | }; | ||
901 | |||
902 | static const char * const vfe_camif_timer5_a_groups[] = { | ||
903 | "gpio66" | ||
904 | }; | ||
905 | |||
906 | static const char * const vfe_camif_timer5_b_groups[] = { | ||
907 | "gpio39" | ||
908 | }; | ||
909 | |||
910 | static const char * const vfe_camif_timer6_a_groups[] = { | ||
911 | "gpio71" | ||
912 | }; | ||
913 | |||
914 | static const char * const vfe_camif_timer6_b_groups[] = { | ||
915 | "gpio0" | ||
916 | }; | ||
917 | |||
918 | static const char * const vfe_camif_timer6_c_groups[] = { | ||
919 | "gpio18" | ||
920 | }; | ||
921 | |||
922 | static const char * const vfe_camif_timer7_a_groups[] = { | ||
923 | "gpio67" | ||
924 | }; | ||
925 | |||
926 | static const char * const vfe_camif_timer7_b_groups[] = { | ||
927 | "gpio1" | ||
928 | }; | ||
929 | |||
930 | static const char * const vfe_camif_timer7_c_groups[] = { | ||
931 | "gpio19" | ||
932 | }; | ||
933 | |||
934 | static const char * const wlan_groups[] = { | ||
935 | "gpio84", "gpio85", "gpio86", "gpio87", "gpio88" | ||
936 | }; | ||
937 | |||
938 | static const struct msm_function msm8960_functions[] = { | ||
939 | FUNCTION(audio_pcm), | ||
940 | FUNCTION(bt), | ||
941 | FUNCTION(cam_mclk0), | ||
942 | FUNCTION(cam_mclk1), | ||
943 | FUNCTION(cam_mclk2), | ||
944 | FUNCTION(codec_mic_i2s), | ||
945 | FUNCTION(codec_spkr_i2s), | ||
946 | FUNCTION(ext_gps), | ||
947 | FUNCTION(fm), | ||
948 | FUNCTION(gps_blanking), | ||
949 | FUNCTION(gps_pps_in), | ||
950 | FUNCTION(gps_pps_out), | ||
951 | FUNCTION(gp_clk_0a), | ||
952 | FUNCTION(gp_clk_0b), | ||
953 | FUNCTION(gp_clk_1a), | ||
954 | FUNCTION(gp_clk_1b), | ||
955 | FUNCTION(gp_clk_2a), | ||
956 | FUNCTION(gp_clk_2b), | ||
957 | FUNCTION(gp_mn), | ||
958 | FUNCTION(gp_pdm_0a), | ||
959 | FUNCTION(gp_pdm_0b), | ||
960 | FUNCTION(gp_pdm_1a), | ||
961 | FUNCTION(gp_pdm_1b), | ||
962 | FUNCTION(gp_pdm_2a), | ||
963 | FUNCTION(gp_pdm_2b), | ||
964 | FUNCTION(gsbi1), | ||
965 | FUNCTION(gsbi1_spi_cs1_n), | ||
966 | FUNCTION(gsbi1_spi_cs2a_n), | ||
967 | FUNCTION(gsbi1_spi_cs2b_n), | ||
968 | FUNCTION(gsbi1_spi_cs3_n), | ||
969 | FUNCTION(gsbi2), | ||
970 | FUNCTION(gsbi2_spi_cs1_n), | ||
971 | FUNCTION(gsbi2_spi_cs2_n), | ||
972 | FUNCTION(gsbi2_spi_cs3_n), | ||
973 | FUNCTION(gsbi3), | ||
974 | FUNCTION(gsbi4), | ||
975 | FUNCTION(gsbi4_3d_cam_i2c_l), | ||
976 | FUNCTION(gsbi4_3d_cam_i2c_r), | ||
977 | FUNCTION(gsbi5), | ||
978 | FUNCTION(gsbi5_3d_cam_i2c_l), | ||
979 | FUNCTION(gsbi5_3d_cam_i2c_r), | ||
980 | FUNCTION(gsbi6), | ||
981 | FUNCTION(gsbi7), | ||
982 | FUNCTION(gsbi8), | ||
983 | FUNCTION(gsbi9), | ||
984 | FUNCTION(gsbi10), | ||
985 | FUNCTION(gsbi11), | ||
986 | FUNCTION(gsbi11_spi_cs1a_n), | ||
987 | FUNCTION(gsbi11_spi_cs1b_n), | ||
988 | FUNCTION(gsbi11_spi_cs2a_n), | ||
989 | FUNCTION(gsbi11_spi_cs2b_n), | ||
990 | FUNCTION(gsbi11_spi_cs3_n), | ||
991 | FUNCTION(gsbi12), | ||
992 | FUNCTION(hdmi_cec), | ||
993 | FUNCTION(hdmi_ddc_clock), | ||
994 | FUNCTION(hdmi_ddc_data), | ||
995 | FUNCTION(hdmi_hot_plug_detect), | ||
996 | FUNCTION(hsic), | ||
997 | FUNCTION(mdp_vsync), | ||
998 | FUNCTION(mi2s), | ||
999 | FUNCTION(mic_i2s), | ||
1000 | FUNCTION(pmb_clk), | ||
1001 | FUNCTION(pmb_ext_ctrl), | ||
1002 | FUNCTION(ps_hold), | ||
1003 | FUNCTION(rpm_wdog), | ||
1004 | FUNCTION(sdc2), | ||
1005 | FUNCTION(sdc4), | ||
1006 | FUNCTION(sdc5), | ||
1007 | FUNCTION(slimbus1), | ||
1008 | FUNCTION(slimbus2), | ||
1009 | FUNCTION(spkr_i2s), | ||
1010 | FUNCTION(ssbi1), | ||
1011 | FUNCTION(ssbi2), | ||
1012 | FUNCTION(ssbi_ext_gps), | ||
1013 | FUNCTION(ssbi_pmic2), | ||
1014 | FUNCTION(ssbi_qpa1), | ||
1015 | FUNCTION(ssbi_ts), | ||
1016 | FUNCTION(tsif1), | ||
1017 | FUNCTION(tsif2), | ||
1018 | FUNCTION(ts_eoc), | ||
1019 | FUNCTION(usb_fs1), | ||
1020 | FUNCTION(usb_fs1_oe), | ||
1021 | FUNCTION(usb_fs1_oe_n), | ||
1022 | FUNCTION(usb_fs2), | ||
1023 | FUNCTION(usb_fs2_oe), | ||
1024 | FUNCTION(usb_fs2_oe_n), | ||
1025 | FUNCTION(vfe_camif_timer1_a), | ||
1026 | FUNCTION(vfe_camif_timer1_b), | ||
1027 | FUNCTION(vfe_camif_timer2), | ||
1028 | FUNCTION(vfe_camif_timer3_a), | ||
1029 | FUNCTION(vfe_camif_timer3_b), | ||
1030 | FUNCTION(vfe_camif_timer4_a), | ||
1031 | FUNCTION(vfe_camif_timer4_b), | ||
1032 | FUNCTION(vfe_camif_timer4_c), | ||
1033 | FUNCTION(vfe_camif_timer5_a), | ||
1034 | FUNCTION(vfe_camif_timer5_b), | ||
1035 | FUNCTION(vfe_camif_timer6_a), | ||
1036 | FUNCTION(vfe_camif_timer6_b), | ||
1037 | FUNCTION(vfe_camif_timer6_c), | ||
1038 | FUNCTION(vfe_camif_timer7_a), | ||
1039 | FUNCTION(vfe_camif_timer7_b), | ||
1040 | FUNCTION(vfe_camif_timer7_c), | ||
1041 | FUNCTION(wlan), | ||
1042 | }; | ||
1043 | |||
1044 | static const struct msm_pingroup msm8960_groups[] = { | ||
1045 | PINGROUP(0, mdp_vsync, vfe_camif_timer6_b, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1046 | PINGROUP(1, mdp_vsync, vfe_camif_timer7_b, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1047 | PINGROUP(2, vfe_camif_timer1_a, gp_mn, NA, cam_mclk2, NA, NA, NA, NA, NA, NA, NA), | ||
1048 | PINGROUP(3, vfe_camif_timer2, gp_clk_0a, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1049 | PINGROUP(4, vfe_camif_timer3_a, cam_mclk1, gp_clk_1a, pmb_ext_ctrl, NA, NA, NA, NA, NA, NA, NA), | ||
1050 | PINGROUP(5, cam_mclk0, pmb_ext_ctrl, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1051 | PINGROUP(6, gsbi1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1052 | PINGROUP(7, gsbi1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1053 | PINGROUP(8, gsbi1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1054 | PINGROUP(9, gsbi1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1055 | PINGROUP(10, gsbi2, ssbi_ts, NA, vfe_camif_timer4_c, NA, NA, NA, NA, NA, NA, NA), | ||
1056 | PINGROUP(11, gsbi2, ts_eoc, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1057 | PINGROUP(12, gsbi2, rpm_wdog, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1058 | PINGROUP(13, gsbi2, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1059 | PINGROUP(14, gsbi3, gsbi1_spi_cs1_n, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1060 | PINGROUP(15, gsbi3, gsbi1_spi_cs2a_n, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1061 | PINGROUP(16, gsbi3, gsbi1_spi_cs3_n, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1062 | PINGROUP(17, gsbi3, gsbi1_spi_cs2b_n, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1063 | PINGROUP(18, gsbi4, gsbi11_spi_cs1b_n, NA, NA, gsbi4_3d_cam_i2c_l, vfe_camif_timer6_c, NA, NA, NA, NA, NA), | ||
1064 | PINGROUP(19, gsbi4, gsbi11_spi_cs2b_n, NA, mdp_vsync, NA, gsbi4_3d_cam_i2c_l, vfe_camif_timer7_c, NA, NA, NA, NA), | ||
1065 | PINGROUP(20, gsbi4, gsbi4_3d_cam_i2c_r, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1066 | PINGROUP(21, gsbi4, pmb_clk, gsbi4_3d_cam_i2c_r, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1067 | PINGROUP(22, gsbi5, ext_gps, NA, NA, NA, NA, NA, NA, NA, gsbi5_3d_cam_i2c_l, NA), | ||
1068 | PINGROUP(23, gsbi5, ssbi_ext_gps, NA, NA, NA, NA, NA, NA, NA, gsbi5_3d_cam_i2c_l, NA), | ||
1069 | PINGROUP(24, gsbi5, ext_gps, NA, NA, NA, NA, NA, NA, NA, gsbi5_3d_cam_i2c_r, NA), | ||
1070 | PINGROUP(25, gsbi5, ext_gps, NA, NA, NA, NA, NA, NA, NA, gsbi5_3d_cam_i2c_r, NA), | ||
1071 | PINGROUP(26, fm, gsbi6, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1072 | PINGROUP(27, fm, gsbi6, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1073 | PINGROUP(28, bt, gsbi6, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1074 | PINGROUP(29, bt, gsbi6, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1075 | PINGROUP(30, gsbi7, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1076 | PINGROUP(31, gsbi7, usb_fs1_oe, usb_fs1_oe_n, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1077 | PINGROUP(32, gsbi7, usb_fs1, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1078 | PINGROUP(33, gsbi7, usb_fs1, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1079 | PINGROUP(34, gsbi8, usb_fs2, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1080 | PINGROUP(35, gsbi8, usb_fs2, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1081 | PINGROUP(36, gsbi8, usb_fs2_oe, usb_fs2_oe_n, gsbi11_spi_cs1a_n, NA, NA, NA, NA, NA, NA, NA), | ||
1082 | PINGROUP(37, gsbi8, gps_pps_out, gps_pps_in, gsbi11_spi_cs2a_n, gp_clk_2b, NA, NA, NA, NA, NA, NA), | ||
1083 | PINGROUP(38, gsbi11, NA, NA, NA, NA, NA, NA, NA, NA, vfe_camif_timer1_b, NA), | ||
1084 | PINGROUP(39, gsbi11, gp_pdm_0b, NA, NA, NA, NA, NA, NA, NA, NA, vfe_camif_timer5_b), | ||
1085 | PINGROUP(40, gsbi11, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1086 | PINGROUP(41, gsbi11, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1087 | PINGROUP(42, gsbi12, slimbus2, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1088 | PINGROUP(43, gsbi12, slimbus2, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1089 | PINGROUP(44, gsbi12, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1090 | PINGROUP(45, gsbi12, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1091 | PINGROUP(46, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1092 | PINGROUP(47, mi2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1093 | PINGROUP(48, mi2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1094 | PINGROUP(49, mi2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1095 | PINGROUP(50, mi2s, slimbus1, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1096 | PINGROUP(51, mi2s, slimbus1, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1097 | PINGROUP(52, mi2s, gp_clk_2a, gsbi2_spi_cs1_n, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1098 | PINGROUP(53, mi2s, gp_pdm_2b, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1099 | PINGROUP(54, codec_mic_i2s, gp_clk_0b, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1100 | PINGROUP(55, codec_mic_i2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1101 | PINGROUP(56, codec_mic_i2s, gsbi2_spi_cs3_n, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1102 | PINGROUP(57, codec_mic_i2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1103 | PINGROUP(58, codec_mic_i2s, gp_pdm_0a, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1104 | PINGROUP(59, codec_spkr_i2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1105 | PINGROUP(60, slimbus1, codec_spkr_i2s, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1106 | PINGROUP(61, slimbus1, codec_spkr_i2s, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1107 | PINGROUP(62, codec_spkr_i2s, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1108 | PINGROUP(63, audio_pcm, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1109 | PINGROUP(64, audio_pcm, gp_pdm_1b, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1110 | PINGROUP(65, audio_pcm, vfe_camif_timer4_a, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1111 | PINGROUP(66, audio_pcm, vfe_camif_timer5_a, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1112 | PINGROUP(67, spkr_i2s, vfe_camif_timer7_a, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1113 | PINGROUP(68, spkr_i2s, gsbi2_spi_cs2_n, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1114 | PINGROUP(69, spkr_i2s, gp_pdm_2a, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1115 | PINGROUP(70, spkr_i2s, gp_clk_1b, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1116 | PINGROUP(71, mic_i2s, gsbi10, vfe_camif_timer6_a, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1117 | PINGROUP(72, mic_i2s, gsbi10, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1118 | PINGROUP(73, mic_i2s, gsbi10, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1119 | PINGROUP(74, mic_i2s, gsbi10, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1120 | PINGROUP(75, tsif1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1121 | PINGROUP(76, tsif1, gsbi11_spi_cs3_n, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1122 | PINGROUP(77, tsif1, sdc5, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1123 | PINGROUP(78, tsif2, sdc5, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1124 | PINGROUP(79, tsif2, sdc5, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1125 | PINGROUP(80, tsif2, sdc5, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1126 | PINGROUP(81, tsif2, sdc5, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1127 | PINGROUP(82, tsif1, sdc5, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1128 | PINGROUP(83, bt, sdc4, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1129 | PINGROUP(84, wlan, sdc4, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1130 | PINGROUP(85, wlan, sdc4, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1131 | PINGROUP(86, wlan, sdc4, pmb_clk, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1132 | PINGROUP(87, wlan, sdc4, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1133 | PINGROUP(88, wlan, sdc4, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1134 | PINGROUP(89, sdc2, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1135 | PINGROUP(90, sdc2, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1136 | PINGROUP(91, sdc2, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1137 | PINGROUP(92, sdc2, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1138 | PINGROUP(93, sdc2, gsbi9, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1139 | PINGROUP(94, sdc2, gsbi9, gp_pdm_1a, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1140 | PINGROUP(95, sdc2, gsbi9, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1141 | PINGROUP(96, sdc2, gsbi9, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1142 | PINGROUP(97, sdc2, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1143 | PINGROUP(98, sdc2, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1144 | PINGROUP(99, hdmi_cec, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1145 | PINGROUP(100, hdmi_ddc_clock, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1146 | PINGROUP(101, hdmi_ddc_data, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1147 | PINGROUP(102, hdmi_hot_plug_detect, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1148 | PINGROUP(103, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1149 | PINGROUP(104, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1150 | PINGROUP(105, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1151 | PINGROUP(106, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1152 | PINGROUP(107, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1153 | PINGROUP(108, ps_hold, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1154 | PINGROUP(109, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1155 | PINGROUP(110, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1156 | PINGROUP(111, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1157 | PINGROUP(112, NA, pmb_clk, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1158 | PINGROUP(113, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1159 | PINGROUP(114, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1160 | PINGROUP(115, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1161 | PINGROUP(116, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1162 | PINGROUP(117, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1163 | PINGROUP(118, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1164 | PINGROUP(119, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1165 | PINGROUP(120, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1166 | PINGROUP(121, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1167 | PINGROUP(122, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1168 | PINGROUP(123, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1169 | PINGROUP(124, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1170 | PINGROUP(125, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1171 | PINGROUP(126, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1172 | PINGROUP(127, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1173 | PINGROUP(128, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1174 | PINGROUP(129, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1175 | PINGROUP(130, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1176 | PINGROUP(131, NA, ssbi_qpa1, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1177 | PINGROUP(132, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1178 | PINGROUP(133, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1179 | PINGROUP(134, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1180 | PINGROUP(135, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1181 | PINGROUP(136, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1182 | PINGROUP(137, gps_blanking, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1183 | PINGROUP(138, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1184 | PINGROUP(139, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1185 | PINGROUP(140, ssbi2, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1186 | PINGROUP(141, ssbi1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1187 | PINGROUP(142, ssbi2, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1188 | PINGROUP(143, ssbi1, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1189 | PINGROUP(144, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1190 | PINGROUP(145, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1191 | PINGROUP(146, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1192 | PINGROUP(147, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1193 | PINGROUP(148, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1194 | PINGROUP(149, ssbi_pmic2, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1195 | PINGROUP(150, hsic, NA, vfe_camif_timer4_b, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1196 | PINGROUP(151, hsic, NA, vfe_camif_timer3_b, NA, NA, NA, NA, NA, NA, NA, NA), | ||
1197 | |||
1198 | SDC_PINGROUP(sdc1_clk, 0x20a0, 13, 6), | ||
1199 | SDC_PINGROUP(sdc1_cmd, 0x20a0, 11, 3), | ||
1200 | SDC_PINGROUP(sdc1_data, 0x20a0, 9, 0), | ||
1201 | |||
1202 | SDC_PINGROUP(sdc3_clk, 0x20a4, 14, 6), | ||
1203 | SDC_PINGROUP(sdc3_cmd, 0x20a4, 11, 3), | ||
1204 | SDC_PINGROUP(sdc3_data, 0x20a4, 9, 0), | ||
1205 | }; | ||
1206 | |||
1207 | #define NUM_GPIO_PINGROUPS 152 | ||
1208 | |||
1209 | static const struct msm_pinctrl_soc_data msm8960_pinctrl = { | ||
1210 | .pins = msm8960_pins, | ||
1211 | .npins = ARRAY_SIZE(msm8960_pins), | ||
1212 | .functions = msm8960_functions, | ||
1213 | .nfunctions = ARRAY_SIZE(msm8960_functions), | ||
1214 | .groups = msm8960_groups, | ||
1215 | .ngroups = ARRAY_SIZE(msm8960_groups), | ||
1216 | .ngpios = NUM_GPIO_PINGROUPS, | ||
1217 | }; | ||
1218 | |||
1219 | static int msm8960_pinctrl_probe(struct platform_device *pdev) | ||
1220 | { | ||
1221 | return msm_pinctrl_probe(pdev, &msm8960_pinctrl); | ||
1222 | } | ||
1223 | |||
1224 | static const struct of_device_id msm8960_pinctrl_of_match[] = { | ||
1225 | { .compatible = "qcom,msm8960-pinctrl", }, | ||
1226 | { }, | ||
1227 | }; | ||
1228 | |||
1229 | static struct platform_driver msm8960_pinctrl_driver = { | ||
1230 | .driver = { | ||
1231 | .name = "msm8960-pinctrl", | ||
1232 | .owner = THIS_MODULE, | ||
1233 | .of_match_table = msm8960_pinctrl_of_match, | ||
1234 | }, | ||
1235 | .probe = msm8960_pinctrl_probe, | ||
1236 | .remove = msm_pinctrl_remove, | ||
1237 | }; | ||
1238 | |||
1239 | static int __init msm8960_pinctrl_init(void) | ||
1240 | { | ||
1241 | return platform_driver_register(&msm8960_pinctrl_driver); | ||
1242 | } | ||
1243 | arch_initcall(msm8960_pinctrl_init); | ||
1244 | |||
1245 | static void __exit msm8960_pinctrl_exit(void) | ||
1246 | { | ||
1247 | platform_driver_unregister(&msm8960_pinctrl_driver); | ||
1248 | } | ||
1249 | module_exit(msm8960_pinctrl_exit); | ||
1250 | |||
1251 | MODULE_AUTHOR("Bjorn Andersson <bjorn.andersson@sonymobile.com>"); | ||
1252 | MODULE_DESCRIPTION("Qualcomm MSM8960 pinctrl driver"); | ||
1253 | MODULE_LICENSE("GPL v2"); | ||
1254 | MODULE_DEVICE_TABLE(of, msm8960_pinctrl_of_match); | ||