aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pinctrl/pinctrl-msm8x74.c
diff options
context:
space:
mode:
authorBjorn Andersson <bjorn.andersson@sonymobile.com>2014-03-31 17:49:55 -0400
committerLinus Walleij <linus.walleij@linaro.org>2014-04-22 02:41:34 -0400
commit3c25381f9b3375c326f5ead194cb91b5ac181f08 (patch)
treeb13b9ecf342307ba0666a4f47569660ab09f7648 /drivers/pinctrl/pinctrl-msm8x74.c
parent130cbe3082a1d69e7009b8c1dabb44babedd9269 (diff)
pinctrl: msm: Make number of functions variable
The various pins may have different number of functions defined, so make this number definable per pin instead of just increasing it to the largest one for all of the platforms. Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/pinctrl-msm8x74.c')
-rw-r--r--drivers/pinctrl/pinctrl-msm8x74.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/pinctrl/pinctrl-msm8x74.c b/drivers/pinctrl/pinctrl-msm8x74.c
index dde5529807aa..57766d56e257 100644
--- a/drivers/pinctrl/pinctrl-msm8x74.c
+++ b/drivers/pinctrl/pinctrl-msm8x74.c
@@ -341,7 +341,7 @@ static const unsigned int sdc2_data_pins[] = { 151 };
341 .name = "gpio" #id, \ 341 .name = "gpio" #id, \
342 .pins = gpio##id##_pins, \ 342 .pins = gpio##id##_pins, \
343 .npins = ARRAY_SIZE(gpio##id##_pins), \ 343 .npins = ARRAY_SIZE(gpio##id##_pins), \
344 .funcs = { \ 344 .funcs = (int[]){ \
345 MSM_MUX_NA, /* gpio mode */ \ 345 MSM_MUX_NA, /* gpio mode */ \
346 MSM_MUX_##f1, \ 346 MSM_MUX_##f1, \
347 MSM_MUX_##f2, \ 347 MSM_MUX_##f2, \
@@ -351,6 +351,7 @@ static const unsigned int sdc2_data_pins[] = { 151 };
351 MSM_MUX_##f6, \ 351 MSM_MUX_##f6, \
352 MSM_MUX_##f7 \ 352 MSM_MUX_##f7 \
353 }, \ 353 }, \
354 .nfuncs = 8, \
354 .ctl_reg = 0x1000 + 0x10 * id, \ 355 .ctl_reg = 0x1000 + 0x10 * id, \
355 .io_reg = 0x1004 + 0x10 * id, \ 356 .io_reg = 0x1004 + 0x10 * id, \
356 .intr_cfg_reg = 0x1008 + 0x10 * id, \ 357 .intr_cfg_reg = 0x1008 + 0x10 * id, \