[PATCH 8/10] powerpc: Set entry point and text address in linker script

Michael Ellerman michael at ellerman.id.au
Sun Oct 16 21:38:57 EST 2005


On Sat, 15 Oct 2005 16:48, Paul Mackerras wrote:
> Michael Ellerman writes:
> > Currently we set the kernel entry point and the address of the text
> > section in the Makefile, using CONFIG_KERNEL_START.
> >
> > But we've already got <asm/page.h> in the linker script, so we can just
> > use KERNELBASE directly. That means if we ever change KERNELBASE there's
> > one less place to change it.
>
> Well yes, on ppc64 we have asm/page.h, but not on ppc32, not yet
> anyway.  We need to get a merged page.h.

Dang, you're right. I'll have a stab at merging page.h sometime.

> On ppc32, CONFIG_KERNEL_START affects both PAGE_OFFSET and KERNELBASE,
> whereas I think you're talking about changing only KERNELBASE, not
> PAGE_OFFSET.

For Kdump I'm changing KERNELBASE only. I hadn't really thought about
PPC32, but it should be pretty straight forward to make something that
could work for both 32 & 64.

I'd suggest PAGE_OFFSET := CONFIG_KERNEL_START, and then KERNELBASE :=
PAGE_OFFSET, except for Kdump where KERNELBASE := PAGE_OFFSET + 32 MB.

> > Apart from linux_banner, there are zero differences from "readelf -a
> > vmlinux" before and after this patch.
>
> Did you test any ppc32 configs?

Got me again.

-- 
Michael Ellerman
IBM OzLabs

email: michael:ellerman.id.au
inmsg: mpe:jabber.org
wwweb: http://michael.ellerman.id.au
phone: +61 2 6212 1183 (tie line 70 21183)

We do not inherit the earth from our ancestors,
we borrow it from our children. - S.M.A.R.T Person

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://ozlabs.org/pipermail/linuxppc64-dev/attachments/20051016/c8dfb09e/attachment.pgp 


More information about the Linuxppc64-dev mailing list