[U-Boot] [PATCH V2] i.MX: iomux: input pad array can be const

Stefano Babic sbabic at denx.de
Wed Oct 10 13:54:27 CEST 2012


From: Eric Nelson <eric.nelson at boundarydevices.com>

Signed-off-by: Eric Nelson <eric.nelson at boundarydevices.com>
Signed-off-by: Stefano Babic <sbabic at denx.de>
---

Changes since V1:
- stack variable must be also declared const to avoid
gcc warnings (Stefano Babic)

 arch/arm/imx-common/iomux-v3.c             |    5 +++--
 arch/arm/include/asm/imx-common/iomux-v3.h |    3 ++-
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/arch/arm/imx-common/iomux-v3.c b/arch/arm/imx-common/iomux-v3.c
index da093fb..08fad78 100644
--- a/arch/arm/imx-common/iomux-v3.c
+++ b/arch/arm/imx-common/iomux-v3.c
@@ -54,9 +54,10 @@ int imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad)
 	return 0;
 }
 
-int imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t *pad_list, unsigned count)
+int imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t const *pad_list,
+				     unsigned count)
 {
-	iomux_v3_cfg_t *p = pad_list;
+	iomux_v3_cfg_t const *p = pad_list;
 	int i;
 	int ret;
 
diff --git a/arch/arm/include/asm/imx-common/iomux-v3.h b/arch/arm/include/asm/imx-common/iomux-v3.h
index 4558f4f..c34bb76 100644
--- a/arch/arm/include/asm/imx-common/iomux-v3.h
+++ b/arch/arm/include/asm/imx-common/iomux-v3.h
@@ -98,6 +98,7 @@ typedef u64 iomux_v3_cfg_t;
 #define MUX_CONFIG_SION		(0x1 << 4)
 
 int imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad);
-int imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t *pad_list, unsigned count);
+int imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t const *pad_list,
+				     unsigned count);
 
 #endif	/* __MACH_IOMUX_V3_H__*/
-- 
1.7.9.5



More information about the U-Boot mailing list