[okl4-developer] Roottask pagefault
Nelson Tam
nelson at ok-labs.com
Thu Feb 21 12:35:46 EST 2008
Hi Ryan,
On 20/02/2008, at 18:37, Ryan Heffernan wrote:
> vbase is 0xa4000000, vend is 0xcfffffff
> addr is 0xa4000000, vbase is 0xa4000000
> roottask read pagefault at 33cc33c8, ip=800023e0 - deny
In addition to what Geoff said, the pointer that Iguana is
dereferencing looks like it was taken from uninitialised bss.
Normally the bootloader should zero-out the bss, and passing a pointer
from a properly-initialised bss would yield a NULL pointer which will
be caught by get_pd(), thus avoiding the bogus pagefault you're seeing.
Can you check whether your bss is initialised properly? Although this
is the responsibility of the bootloader to zero-out memory within the
nobits sections of an elf file, sometimes lousy bootloaders don't do
that, and you have to do tricks within the elf file to make sure the
memory is zeroed. What we do here is manipulate the elf so that
nobits sections are replaced by progbits sections that contain all
zeros.
For now probably the easiest way is to get OKL4 to manually zero-out
the bss during system bootup.
Nelson.
More information about the Developer
mailing list