aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChanho Park <chanho61.park@samsung.com>2012-01-03 02:47:51 -0500
committerLinus Walleij <linus.walleij@linaro.org>2012-01-03 03:10:09 -0500
commit0d2006bbf09e817f125ba1e42b2549bc2c5d7351 (patch)
treef452f0a77705139763448c5676f6118270285439
parent706e8520e8450a631ca6f798f8c811faf56f0a59 (diff)
pinctrl: remove unnecessary max pin number
This patch removes maxpin member in the pin control descriptor because we don't need this value as we enumerate a pin space using offset. Signed-off-by: Chanho Park <chanho61.park@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
-rw-r--r--drivers/pinctrl/core.c1
-rw-r--r--drivers/pinctrl/pinctrl-sirf.c1
-rw-r--r--drivers/pinctrl/pinctrl-u300.c1
-rw-r--r--include/linux/pinctrl/pinctrl.h5
4 files changed, 0 insertions, 8 deletions
diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c
index 79c56d90fcc5..569bdb3ef104 100644
--- a/drivers/pinctrl/core.c
+++ b/drivers/pinctrl/core.c
@@ -354,7 +354,6 @@ static int pinctrl_pins_show(struct seq_file *s, void *what)
354 unsigned i, pin; 354 unsigned i, pin;
355 355
356 seq_printf(s, "registered pins: %d\n", pctldev->desc->npins); 356 seq_printf(s, "registered pins: %d\n", pctldev->desc->npins);
357 seq_printf(s, "max pin number: %d\n", pctldev->desc->maxpin);
358 357
359 /* The pin number can be retrived from the pin controller descriptor */ 358 /* The pin number can be retrived from the pin controller descriptor */
360 for (i = 0; i < pctldev->desc->npins; i++) { 359 for (i = 0; i < pctldev->desc->npins; i++) {
diff --git a/drivers/pinctrl/pinctrl-sirf.c b/drivers/pinctrl/pinctrl-sirf.c
index 99e688e07ea0..6b3534cc051a 100644
--- a/drivers/pinctrl/pinctrl-sirf.c
+++ b/drivers/pinctrl/pinctrl-sirf.c
@@ -1086,7 +1086,6 @@ static struct pinctrl_desc sirfsoc_pinmux_desc = {
1086 .name = DRIVER_NAME, 1086 .name = DRIVER_NAME,
1087 .pins = sirfsoc_pads, 1087 .pins = sirfsoc_pads,
1088 .npins = ARRAY_SIZE(sirfsoc_pads), 1088 .npins = ARRAY_SIZE(sirfsoc_pads),
1089 .maxpin = SIRFSOC_NUM_PADS - 1,
1090 .pctlops = &sirfsoc_pctrl_ops, 1089 .pctlops = &sirfsoc_pctrl_ops,
1091 .pmxops = &sirfsoc_pinmux_ops, 1090 .pmxops = &sirfsoc_pinmux_ops,
1092 .owner = THIS_MODULE, 1091 .owner = THIS_MODULE,
diff --git a/drivers/pinctrl/pinctrl-u300.c b/drivers/pinctrl/pinctrl-u300.c
index 7e89b367a7e5..c8d02f1c2b5e 100644
--- a/drivers/pinctrl/pinctrl-u300.c
+++ b/drivers/pinctrl/pinctrl-u300.c
@@ -1048,7 +1048,6 @@ static struct pinctrl_desc u300_pmx_desc = {
1048 .name = DRIVER_NAME, 1048 .name = DRIVER_NAME,
1049 .pins = u300_pads, 1049 .pins = u300_pads,
1050 .npins = ARRAY_SIZE(u300_pads), 1050 .npins = ARRAY_SIZE(u300_pads),
1051 .maxpin = U300_NUM_PADS-1,
1052 .pctlops = &u300_pctrl_ops, 1051 .pctlops = &u300_pctrl_ops,
1053 .pmxops = &u300_pmx_ops, 1052 .pmxops = &u300_pmx_ops,
1054 .owner = THIS_MODULE, 1053 .owner = THIS_MODULE,
diff --git a/include/linux/pinctrl/pinctrl.h b/include/linux/pinctrl/pinctrl.h
index 9809a94f151b..8bd22ee7aa09 100644
--- a/include/linux/pinctrl/pinctrl.h
+++ b/include/linux/pinctrl/pinctrl.h
@@ -92,10 +92,6 @@ struct pinctrl_ops {
92 * this pin controller 92 * this pin controller
93 * @npins: number of descriptors in the array, usually just ARRAY_SIZE() 93 * @npins: number of descriptors in the array, usually just ARRAY_SIZE()
94 * of the pins field above 94 * of the pins field above
95 * @maxpin: since pin spaces may be sparse, there can he "holes" in the
96 * pin range, this attribute gives the maximum pin number in the
97 * total range. This should not be lower than npins for example,
98 * but may be equal to npins if you have no holes in the pin range.
99 * @pctlops: pin control operation vtable, to support global concepts like 95 * @pctlops: pin control operation vtable, to support global concepts like
100 * grouping of pins, this is optional. 96 * grouping of pins, this is optional.
101 * @pmxops: pinmux operations vtable, if you support pinmuxing in your driver 97 * @pmxops: pinmux operations vtable, if you support pinmuxing in your driver
@@ -107,7 +103,6 @@ struct pinctrl_desc {
107 const char *name; 103 const char *name;
108 struct pinctrl_pin_desc const *pins; 104 struct pinctrl_pin_desc const *pins;
109 unsigned int npins; 105 unsigned int npins;
110 unsigned int maxpin;
111 struct pinctrl_ops *pctlops; 106 struct pinctrl_ops *pctlops;
112 struct pinmux_ops *pmxops; 107 struct pinmux_ops *pmxops;
113 struct pinconf_ops *confops; 108 struct pinconf_ops *confops;