diff options
author | Uwe Kleine-König <u.kleine-koenig@pengutronix.de> | 2015-02-21 10:08:21 -0500 |
---|---|---|
committer | Shawn Guo <shawn.guo@linaro.org> | 2015-03-02 23:04:41 -0500 |
commit | 9fece9bdabfff12610572a4e5c072bdc043fae9f (patch) | |
tree | d60df332398b5b86fe2fedb8c468d3a97b6d9eb3 | |
parent | c517d838eb7d07bbe9507871fab3931deccff539 (diff) |
ARM: imx/iomux-v3: allow pad_list to be const
Also fix all machine files to make use of it and while at it also make
the pad lists __initconst.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
-rw-r--r-- | arch/arm/mach-imx/eukrea_mbimxsd25-baseboard.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-imx/eukrea_mbimxsd35-baseboard.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-imx/iomux-v3.c | 5 | ||||
-rw-r--r-- | arch/arm/mach-imx/iomux-v3.h | 3 | ||||
-rw-r--r-- | arch/arm/mach-imx/mach-cpuimx35.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-imx/mach-eukrea_cpuimx25.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-imx/mach-mx25_3ds.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-imx/mach-mx35_3ds.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-imx/mach-pcm043.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-imx/mach-vpr200.c | 2 |
10 files changed, 13 insertions, 11 deletions
diff --git a/arch/arm/mach-imx/eukrea_mbimxsd25-baseboard.c b/arch/arm/mach-imx/eukrea_mbimxsd25-baseboard.c index e77cc3af6db2..10e53818e003 100644 --- a/arch/arm/mach-imx/eukrea_mbimxsd25-baseboard.c +++ b/arch/arm/mach-imx/eukrea_mbimxsd25-baseboard.c | |||
@@ -35,7 +35,7 @@ | |||
35 | #include "iomux-mx25.h" | 35 | #include "iomux-mx25.h" |
36 | #include "mx25.h" | 36 | #include "mx25.h" |
37 | 37 | ||
38 | static iomux_v3_cfg_t eukrea_mbimxsd_pads[] = { | 38 | static const iomux_v3_cfg_t eukrea_mbimxsd_pads[] __initconst = { |
39 | /* LCD */ | 39 | /* LCD */ |
40 | MX25_PAD_LD0__LD0, | 40 | MX25_PAD_LD0__LD0, |
41 | MX25_PAD_LD1__LD1, | 41 | MX25_PAD_LD1__LD1, |
diff --git a/arch/arm/mach-imx/eukrea_mbimxsd35-baseboard.c b/arch/arm/mach-imx/eukrea_mbimxsd35-baseboard.c index 14d6c8249b76..6edc940e0865 100644 --- a/arch/arm/mach-imx/eukrea_mbimxsd35-baseboard.c +++ b/arch/arm/mach-imx/eukrea_mbimxsd35-baseboard.c | |||
@@ -100,7 +100,7 @@ static struct mx3fb_platform_data mx3fb_pdata __initdata = { | |||
100 | .num_modes = ARRAY_SIZE(fb_modedb), | 100 | .num_modes = ARRAY_SIZE(fb_modedb), |
101 | }; | 101 | }; |
102 | 102 | ||
103 | static iomux_v3_cfg_t eukrea_mbimxsd_pads[] = { | 103 | static const iomux_v3_cfg_t eukrea_mbimxsd_pads[] __initconst = { |
104 | /* LCD */ | 104 | /* LCD */ |
105 | MX35_PAD_LD0__IPU_DISPB_DAT_0, | 105 | MX35_PAD_LD0__IPU_DISPB_DAT_0, |
106 | MX35_PAD_LD1__IPU_DISPB_DAT_1, | 106 | MX35_PAD_LD1__IPU_DISPB_DAT_1, |
diff --git a/arch/arm/mach-imx/iomux-v3.c b/arch/arm/mach-imx/iomux-v3.c index d61f9606fc56..a53b2e64f98d 100644 --- a/arch/arm/mach-imx/iomux-v3.c +++ b/arch/arm/mach-imx/iomux-v3.c | |||
@@ -56,9 +56,10 @@ int mxc_iomux_v3_setup_pad(iomux_v3_cfg_t pad) | |||
56 | return 0; | 56 | return 0; |
57 | } | 57 | } |
58 | 58 | ||
59 | int mxc_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t *pad_list, unsigned count) | 59 | int mxc_iomux_v3_setup_multiple_pads(const iomux_v3_cfg_t *pad_list, |
60 | unsigned count) | ||
60 | { | 61 | { |
61 | iomux_v3_cfg_t *p = pad_list; | 62 | const iomux_v3_cfg_t *p = pad_list; |
62 | int i; | 63 | int i; |
63 | int ret; | 64 | int ret; |
64 | 65 | ||
diff --git a/arch/arm/mach-imx/iomux-v3.h b/arch/arm/mach-imx/iomux-v3.h index 2fa3b5430102..5f4bbf124832 100644 --- a/arch/arm/mach-imx/iomux-v3.h +++ b/arch/arm/mach-imx/iomux-v3.h | |||
@@ -131,7 +131,8 @@ int mxc_iomux_v3_setup_pad(iomux_v3_cfg_t pad); | |||
131 | * setups mutliple pads | 131 | * setups mutliple pads |
132 | * convenient way to call the above function with tables | 132 | * convenient way to call the above function with tables |
133 | */ | 133 | */ |
134 | int mxc_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t *pad_list, unsigned count); | 134 | int mxc_iomux_v3_setup_multiple_pads(const iomux_v3_cfg_t *pad_list, |
135 | unsigned count); | ||
135 | 136 | ||
136 | /* | 137 | /* |
137 | * Initialise the iomux controller | 138 | * Initialise the iomux controller |
diff --git a/arch/arm/mach-imx/mach-cpuimx35.c b/arch/arm/mach-imx/mach-cpuimx35.c index 62a6e02f4763..922ffd6ca039 100644 --- a/arch/arm/mach-imx/mach-cpuimx35.c +++ b/arch/arm/mach-imx/mach-cpuimx35.c | |||
@@ -75,7 +75,7 @@ static struct i2c_board_info eukrea_cpuimx35_i2c_devices[] = { | |||
75 | }, | 75 | }, |
76 | }; | 76 | }; |
77 | 77 | ||
78 | static iomux_v3_cfg_t eukrea_cpuimx35_pads[] = { | 78 | static const iomux_v3_cfg_t eukrea_cpuimx35_pads[] __initconst = { |
79 | /* UART1 */ | 79 | /* UART1 */ |
80 | MX35_PAD_CTS1__UART1_CTS, | 80 | MX35_PAD_CTS1__UART1_CTS, |
81 | MX35_PAD_RTS1__UART1_RTS, | 81 | MX35_PAD_RTS1__UART1_RTS, |
diff --git a/arch/arm/mach-imx/mach-eukrea_cpuimx25.c b/arch/arm/mach-imx/mach-eukrea_cpuimx25.c index b2ee6e009fe4..026321918843 100644 --- a/arch/arm/mach-imx/mach-eukrea_cpuimx25.c +++ b/arch/arm/mach-imx/mach-eukrea_cpuimx25.c | |||
@@ -45,7 +45,7 @@ static const struct imxuart_platform_data uart_pdata __initconst = { | |||
45 | .flags = IMXUART_HAVE_RTSCTS, | 45 | .flags = IMXUART_HAVE_RTSCTS, |
46 | }; | 46 | }; |
47 | 47 | ||
48 | static iomux_v3_cfg_t eukrea_cpuimx25_pads[] = { | 48 | static const iomux_v3_cfg_t eukrea_cpuimx25_pads[] __initconst = { |
49 | /* FEC - RMII */ | 49 | /* FEC - RMII */ |
50 | MX25_PAD_FEC_MDC__FEC_MDC, | 50 | MX25_PAD_FEC_MDC__FEC_MDC, |
51 | MX25_PAD_FEC_MDIO__FEC_MDIO, | 51 | MX25_PAD_FEC_MDIO__FEC_MDIO, |
diff --git a/arch/arm/mach-imx/mach-mx25_3ds.c b/arch/arm/mach-imx/mach-mx25_3ds.c index 0d01e367b062..584248a5e1e9 100644 --- a/arch/arm/mach-imx/mach-mx25_3ds.c +++ b/arch/arm/mach-imx/mach-mx25_3ds.c | |||
@@ -50,7 +50,7 @@ static const struct imxuart_platform_data uart_pdata __initconst = { | |||
50 | .flags = IMXUART_HAVE_RTSCTS, | 50 | .flags = IMXUART_HAVE_RTSCTS, |
51 | }; | 51 | }; |
52 | 52 | ||
53 | static iomux_v3_cfg_t mx25pdk_pads[] = { | 53 | static const iomux_v3_cfg_t mx25pdk_pads[] __initconst = { |
54 | MX25_PAD_FEC_MDC__FEC_MDC, | 54 | MX25_PAD_FEC_MDC__FEC_MDC, |
55 | MX25_PAD_FEC_MDIO__FEC_MDIO, | 55 | MX25_PAD_FEC_MDIO__FEC_MDIO, |
56 | MX25_PAD_FEC_TDATA0__FEC_TDATA0, | 56 | MX25_PAD_FEC_TDATA0__FEC_TDATA0, |
diff --git a/arch/arm/mach-imx/mach-mx35_3ds.c b/arch/arm/mach-imx/mach-mx35_3ds.c index 72cd77d21f63..7e315f00648d 100644 --- a/arch/arm/mach-imx/mach-mx35_3ds.c +++ b/arch/arm/mach-imx/mach-mx35_3ds.c | |||
@@ -166,7 +166,7 @@ static struct platform_device *devices[] __initdata = { | |||
166 | &mx35pdk_flash, | 166 | &mx35pdk_flash, |
167 | }; | 167 | }; |
168 | 168 | ||
169 | static iomux_v3_cfg_t mx35pdk_pads[] = { | 169 | static const iomux_v3_cfg_t mx35pdk_pads[] __initconst = { |
170 | /* UART1 */ | 170 | /* UART1 */ |
171 | MX35_PAD_CTS1__UART1_CTS, | 171 | MX35_PAD_CTS1__UART1_CTS, |
172 | MX35_PAD_RTS1__UART1_RTS, | 172 | MX35_PAD_RTS1__UART1_RTS, |
diff --git a/arch/arm/mach-imx/mach-pcm043.c b/arch/arm/mach-imx/mach-pcm043.c index b623bcaca76c..e447e59c0604 100644 --- a/arch/arm/mach-imx/mach-pcm043.c +++ b/arch/arm/mach-imx/mach-pcm043.c | |||
@@ -129,7 +129,7 @@ static struct platform_device *devices[] __initdata = { | |||
129 | &pcm043_flash, | 129 | &pcm043_flash, |
130 | }; | 130 | }; |
131 | 131 | ||
132 | static iomux_v3_cfg_t pcm043_pads[] = { | 132 | static const iomux_v3_cfg_t pcm043_pads[] __initconst = { |
133 | /* UART1 */ | 133 | /* UART1 */ |
134 | MX35_PAD_CTS1__UART1_CTS, | 134 | MX35_PAD_CTS1__UART1_CTS, |
135 | MX35_PAD_RTS1__UART1_RTS, | 135 | MX35_PAD_RTS1__UART1_RTS, |
diff --git a/arch/arm/mach-imx/mach-vpr200.c b/arch/arm/mach-imx/mach-vpr200.c index 97836e94451c..27a8f7e3ec08 100644 --- a/arch/arm/mach-imx/mach-vpr200.c +++ b/arch/arm/mach-imx/mach-vpr200.c | |||
@@ -161,7 +161,7 @@ static struct i2c_board_info vpr200_i2c_devices[] = { | |||
161 | } | 161 | } |
162 | }; | 162 | }; |
163 | 163 | ||
164 | static iomux_v3_cfg_t vpr200_pads[] = { | 164 | static const iomux_v3_cfg_t vpr200_pads[] __initconst = { |
165 | /* UART1 */ | 165 | /* UART1 */ |
166 | MX35_PAD_TXD1__UART1_TXD_MUX, | 166 | MX35_PAD_TXD1__UART1_TXD_MUX, |
167 | MX35_PAD_RXD1__UART1_RXD_MUX, | 167 | MX35_PAD_RXD1__UART1_RXD_MUX, |