linux-mips
[Top] [All Lists]

Re: _stext is ill-defined / SysRq-T broken

To: "Maciej W. Rozycki" <macro@ds2.pg.gda.pl>
Subject: Re: _stext is ill-defined / SysRq-T broken
From: Johannes Stezenbach <js@convergence.de>
Date: Thu, 25 Jul 2002 13:05:38 +0200
Cc: linux-mips@oss.sgi.com
In-reply-to: <Pine.GSO.3.96.1020725114648.27463B-100000@delta.ds2.pg.gda.pl>
Mail-followup-to: Johannes Stezenbach <js@convergence.de>, "Maciej W. Rozycki" <macro@ds2.pg.gda.pl>, linux-mips@oss.sgi.com
References: <20020724181708.GA5399@convergence.de> <Pine.GSO.3.96.1020725114648.27463B-100000@delta.ds2.pg.gda.pl>
Sender: owner-linux-mips@oss.sgi.com
User-agent: Mutt/1.4i
On Thu, Jul 25, 2002 at 12:08:15PM +0200, Maciej W. Rozycki wrote:
> 
>  I think the intent is to skip initial parts of .text, specifically the
> exception handlers (if linked at KSEG0).  kernel_entry is in .text.init
> deliberately, as it's not needed except early in the boot process.  I
> propose the following change.  Does it work for you? 
> 
> diff -up --recursive --new-file 
> linux-mips-2.4.19-rc1-20020719.macro/arch/mips/kernel/head.S 
> linux-mips-2.4.19-rc1-20020719/arch/mips/kernel/head.S
> --- linux-mips-2.4.19-rc1-20020719.macro/arch/mips/kernel/head.S      
> 2002-06-04 03:04:12.000000000 +0000
> +++ linux-mips-2.4.19-rc1-20020719/arch/mips/kernel/head.S    2002-07-25 
> 10:03:16.000000000 +0000
> @@ -35,6 +35,10 @@
>                */
>               .fill   0x400
>  
> +             /* The following two symbols are used for kernel profiling. */
> +             EXPORT(stext)
> +             EXPORT(_stext)
> +
>               __INIT
>  
>               /* Cache Error */
> @@ -144,9 +148,6 @@ ejtag_return:
>                */
>               NESTED(kernel_entry, 16, sp)
>               .set    noreorder
> -             /* The following two symbols are used for kernel profiling. */
> -             EXPORT(stext)
> -             EXPORT(_stext)
>  
>               /*
>                * Stack for kernel and init, current variable
> 

Yes, works.

Just one nit while we're at it:
On most systems the .fill 0x400 is unnecessary  and wastes 1KB (more
than the .text.init size of head.o). Wouldn't it be better to remove the
.fill and require the LOADADDR in arch/mips/Makefile to be >= 0x80000400?


Johannes


<Prev in Thread] Current Thread [Next in Thread>