[PATCH] powerpc: Disable external interrupts in bootwrapper

Mark A. Greer mgreer at mvista.com
Wed Apr 11 08:37:12 EST 2007


On Tue, Mar 27, 2007 at 03:28:40PM -0700, Mark A. Greer wrote:
> Disable external interrupts very early in the bootwrapper in case
> the firmware left a device generating interrupts.
> 
> Signed-off-by: Mark A. Greer <mgreer at mvista.com>
> ---
> 
>  crt0.S |    6 ++++++
>  1 file changed, 6 insertions(+)
> ---
> 
> diff --git a/arch/powerpc/boot/crt0.S b/arch/powerpc/boot/crt0.S
> index 3dc8d8f..f048a46 100644
> --- a/arch/powerpc/boot/crt0.S
> +++ b/arch/powerpc/boot/crt0.S
> @@ -23,6 +23,12 @@ _zimage_start:
>  	   and the address where we're running. */
>  	bl	1f
>  1:	mflr	r0
> +	li	r9,(1<<15)@l	/* Disable external intrs (clear MSR[EE]) */
> +	mfmsr	r10
> +	andc	r10,r10,r9
> +	sync
> +	mtmsr	r10
> +	isync
>  	lis	r9,1b at ha
>  	addi	r9,r9,1b at l
>  	subf.	r0,r9,r0

Paul,

Just in case there is any doubt, please ignore this patch.
I can do what I need to do from my platform file.

Mark



More information about the Linuxppc-dev mailing list