[OpenBIOS] [PATCH 2/2] Don't map the page 0 to make NULL-dereferencing more obvious
Mark Cave-Ayland
mark.cave-ayland at ilande.co.uk
Tue Apr 9 21:27:09 CEST 2013
On 08/04/13 21:25, Artyom Tarasenko wrote:
>> You're probably calling ihandle>phandle with a phandle. I would expect the
>> return from active-package to be a phandle, not an ihandle.
>
> You are absolutely right. Removing ihandle>phandle helped.
> Thanks a lot!
Actually the fix is much easier than this:
Configuration device id QEMU version 1 machine id 32
CPUs: 1 x FMI,MB86904
UUID: 00000000-0000-0000-0000-000000000000
Welcome to OpenBIOS v1.0 built on Apr 9 2013 18:40
Type 'help' for detailed information
0 > cd /chosen ok
0 > .properties
name "chosen"
stdin ffce26f4
stdout ffce278c
memory ffce29c4
mmu 0
screen ffce2610
ok
0 >
According to the sample prtconf output, SPARC32 doesn't have an "mmu"
chosen handle so we should just remove it. Now currently the property
lives in forth/device/tree.fs so it exists across all architectures,
however SPARC64 and PPC are fine because they create the property on
demand during initialisation.
I've just committed a patch to fix this (on a second attempt as I
accidentally caught the NULL dereference patch in there too) so please
feel free to test.
ATB,
Mark.
More information about the OpenBIOS
mailing list