2003-03-04 17:45:41

by ravikumar.chakaravarthy

[permalink] [raw]
Subject: RE: Loading and executing kernel from a non-standard address usin g SY SLINUX

Yes the kernel is uncompressed to the right location (0x200000), in my case. When I try to uncompress it to a non standard address (other than 0x100000), the address mapping is affected. Thats why I tried to change the PAGE_OFFSET value to 0xc0100000, which should be the right value corresponding to (0x200000).
So the problem now is that, when a function is invoked it is unable to fetch the right physical address, since my address mapping (System.map) does not change when I change the value of PAGE_OFFSET and recompile the kernel.

-Ravi


-----Original Message-----
From: Martin J. Bligh [mailto:[email protected]]
Sent: Tuesday, March 04, 2003 11:35 AM
To: Chakaravarthy, Ravikumar; [email protected]
Subject: Re: Loading and executing kernel from a non-standard address using SY SLINUX

> I am trying to load and boot the kernel from a non-standard address
> (0x200000). I am using the SYSLINUX boot loader, which loads the
> kernel at that address. I have also made changes to the kernel to
> setup code and startup_32() function to effect the same. When I boot
> the system It says
>
> Loading.......... Ready
> Uncompressing Linux... OK Booting the kernel
>
> and then hangs.
>
> I guess the reason being the System.map entries are still using the
> PAGE_OFFSET = 0xc0000000, as opposed to 0xc0100000.
> I have the following questions??
>
> 1. How do i change the System.map to get the right PAGE_OFFSET.
> 2. Will it work if I load and boot the kernel from a different address
> like (0xdf000000)??
>
> 3. Am I in the right track or missing something.

The kernel should decompress itself to the right space anyway ... check
arch/i386/boot/compressed/head.S ... should be minimal changes needed,
if any.

M.


2003-03-04 18:02:28

by Martin J. Bligh

[permalink] [raw]
Subject: RE: Loading and executing kernel from a non-standard address usin g SY SLINUX

> Yes the kernel is uncompressed to the right location (0x200000), in my
> case. When I try to uncompress it to a non standard address (other than
> 0x100000), the address mapping is affected.

Why would you need to uncompress it to a different address? You mention
that your bootloader does something odd, but that should only affect the
address of the compressed bzImage, not the decompressed kernel ...

M.

2003-03-05 21:29:31

by Kai Germaschewski

[permalink] [raw]
Subject: RE: Loading and executing kernel from a non-standard address usin g SY SLINUX

On Tue, 4 Mar 2003 [email protected] wrote:

> Yes the kernel is uncompressed to the right location (0x200000), in my
> case. When I try to uncompress it to a non standard address (other than
> 0x100000), the address mapping is affected. Thats why I tried to change
> the PAGE_OFFSET value to 0xc0100000, which should be the right value
> corresponding to (0x200000).

> So the problem now is that, when a function is invoked it is unable to
> fetch the right physical address, since my address mapping (System.map)
> does not change when I change the value of PAGE_OFFSET and recompile the
> kernel.

Well, this sounds very much like your vmlinux is relocated to the wrong
adresses, and then it's not surprising it doesn't work. You definitely
want to change arch/i386/vmlinux.lds.S. I'm not sure if you actually want
to change PAGE_OFFSET, but I don't see a fundamental reason why it should
be needed, so I think you should try as-is.

--Kai