diff mbox

[3/4] pinctrl: tegra: reduce size of data table fields

Message ID 1397511222-28533-3-git-send-email-swarren@wwwdotorg.org (mailing list archive)
State New, archived
Headers show

Commit Message

Stephen Warren April 14, 2014, 9:33 p.m. UTC
From: Stephen Warren <swarren@nvidia.com>

The range of npins and function ID values is small enough to fit into a
u8. Use this type rather than unsigned to shrink the pinmux data tables.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
---
 drivers/pinctrl/pinctrl-tegra.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Laxman Dewangan April 15, 2014, 12:31 p.m. UTC | #1
On Tuesday 15 April 2014 03:03 AM, Stephen Warren wrote:
> From: Stephen Warren <swarren@nvidia.com>
>
> The range of npins and function ID values is small enough to fit into a
> u8. Use this type rather than unsigned to shrink the pinmux data tables.
>
For 3 and 4, also
Acked-by: Laxman Dewangan <ldewangan@nvidia.com>
Linus Walleij April 22, 2014, 2:53 p.m. UTC | #2
On Mon, Apr 14, 2014 at 11:33 PM, Stephen Warren <swarren@wwwdotorg.org> wrote:

> From: Stephen Warren <swarren@nvidia.com>
>
> The range of npins and function ID values is small enough to fit into a
> u8. Use this type rather than unsigned to shrink the pinmux data tables.
>
> Signed-off-by: Stephen Warren <swarren@nvidia.com>

Applied with Laxman's ACK.

Yours,
Linus Walleij
diff mbox

Patch

diff --git a/drivers/pinctrl/pinctrl-tegra.h b/drivers/pinctrl/pinctrl-tegra.h
index c60ad4cf971c..9052c1f8a59b 100644
--- a/drivers/pinctrl/pinctrl-tegra.h
+++ b/drivers/pinctrl/pinctrl-tegra.h
@@ -131,8 +131,8 @@  struct tegra_function {
 struct tegra_pingroup {
 	const char *name;
 	const unsigned *pins;
-	unsigned npins;
-	unsigned funcs[4];
+	u8 npins;
+	u8 funcs[4];
 	s16 mux_reg;
 	s16 pupd_reg;
 	s16 tri_reg;