[PATCH 4/7] ARM: Thumb-2: Correct data alignment for CONFIG_THUMB2_KERNEL in kernel/head.S

Russell King - ARM Linux linux at arm.linux.org.uk
Tue Nov 16 13:22:57 EST 2010


On Tue, Nov 16, 2010 at 01:14:34PM +0000, Dave Martin wrote:
> Directives such as .long and .word do not magically cause the
> assembler location counter to become aligned in gas.  As a
> result, using these directives in code sections can result in
> misaligned data words when building a Thumb-2 kernel
> (CONFIG_THUMB2_KERNEL).

> @@ -413,6 +416,7 @@ __fixup_smp_on_up:
>  	mov	pc, lr
>  ENDPROC(__fixup_smp)
>  
> +	.align
>  1:	.word	.
>  	.word	__smpalt_begin
>  	.word	__smpalt_end

This one is technically bogus because this feature is disabled (and
incompatible) with Thumb-2 kernels.  So it never gets built for a T2
kernel.



More information about the linux-arm-kernel mailing list