summaryrefslogtreecommitdiff
path: root/board/ti
diff options
context:
space:
mode:
authorAlbert ARIBAUD <albert.u.boot@aribaud.net>2012-10-09 09:28:15 +0000
committerTom Rini <trini@ti.com>2012-10-15 11:53:07 -0700
commitb823fd9ba56d56e3cbb5b05e7a4815fb0914204a (patch)
treeb93f7f8ba2874cd0478aee2f96718aedf4031ce7 /board/ti
parent6528ff0109d81c1f21d20f9f1370782bccf87bcb (diff)
downloadu-boot-imx-b823fd9ba56d56e3cbb5b05e7a4815fb0914204a.zip
u-boot-imx-b823fd9ba56d56e3cbb5b05e7a4815fb0914204a.tar.gz
u-boot-imx-b823fd9ba56d56e3cbb5b05e7a4815fb0914204a.tar.bz2
ARM: prevent misaligned array inits
Under option -munaligned-access, gcc can perform local char or 16-bit array initializations using misaligned native accesses which will throw a data abort exception. Fix files where these array initializations were unneeded, and for files known to contain such initializations, enforce gcc option -mno-unaligned-access. Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net> [trini: Switch to usign call cc-option for -mno-unaligned-access as Albert had done previously as that's really correct] Signed-off-by: Tom Rini <trini@ti.com>
Diffstat (limited to 'board/ti')
-rw-r--r--board/ti/omap2420h4/sys_info.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/board/ti/omap2420h4/sys_info.c b/board/ti/omap2420h4/sys_info.c
index a9f7241..b12011e 100644
--- a/board/ti/omap2420h4/sys_info.c
+++ b/board/ti/omap2420h4/sys_info.c
@@ -237,20 +237,20 @@ u32 wait_on_value(u32 read_bit_mask, u32 match_value, u32 read_addr, u32 bound)
*********************************************************************/
void display_board_info(u32 btype)
{
- char cpu_2420[] = "2420"; /* cpu type */
- char cpu_2422[] = "2422";
- char cpu_2423[] = "2423";
- char db_men[] = "Menelaus"; /* board type */
- char db_ip[] = "IP";
- char mem_sdr[] = "mSDR"; /* memory type */
- char mem_ddr[] = "mDDR";
- char t_tst[] = "TST"; /* security level */
- char t_emu[] = "EMU";
- char t_hs[] = "HS";
- char t_gp[] = "GP";
- char unk[] = "?";
-
- char *cpu_s, *db_s, *mem_s, *sec_s;
+ static const char cpu_2420 [] = "2420"; /* cpu type */
+ static const char cpu_2422 [] = "2422";
+ static const char cpu_2423 [] = "2423";
+ static const char db_men [] = "Menelaus"; /* board type */
+ static const char db_ip [] = "IP";
+ static const char mem_sdr [] = "mSDR"; /* memory type */
+ static const char mem_ddr [] = "mDDR";
+ static const char t_tst [] = "TST"; /* security level */
+ static const char t_emu [] = "EMU";
+ static const char t_hs [] = "HS";
+ static const char t_gp [] = "GP";
+ static const char unk [] = "?";
+
+ const char *cpu_s, *db_s, *mem_s, *sec_s;
u32 cpu, rev, sec;
rev = get_cpu_rev();