[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
Wed Apr 10 10:18:40 CEST 2013

On 10/04/13 00:43, Tarl Neustaedter wrote:

> That shouldn't matter - as far as .properties is concerned, the /chosen
> properties are ints, and are printed out as such.
> The bug seemed to be the sequence:
> active-package ( phandle ) ihandle>phandle
> You can't feed a phandle into ihandle>phandle.

Hmmm the source looks like this:

" /chosen" find-dev if
   " mmu" rot get-package-property 0= if
     decode-int nip nip ihandle>phandle active-package = if

AFAICT the code should get the chosen package "mmu" property, decode it, 
remove the remainder, convert to a phandle and then do the comparison to 
active-package which should be valid?



More information about the OpenBIOS mailing list