[U-Boot] [RFC] ARM: prevent misaligned array inits

Thierry Reding thierry.reding at avionic-design.de
Thu Oct 4 14:02:06 CEST 2012


On Tue, Oct 02, 2012 at 08:46:04PM +0200, Albert ARIBAUD wrote:
> 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 at aribaud.net>
> ---
> Please test this patch with gcc 4.7 on boards which do data aborts
> or resets due to misaligned accesses and report result to me.

I've tested this on TEC, on top of Tom's tegra/next branch. Without the
patch, U-Boot hangs right after:

	Loading Device Tree to 010f9000, end 010ff2d4 ... OK

With the patch applied the system boots to the login prompt, so:

Tested-by: Thierry Reding <thierry.reding at avionic-design.de>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20121004/c51258b7/attachment.pgp>


More information about the U-Boot mailing list