I have begun doing work with OpenBIOS. I was wondering if it is
possible to compile OpenBIOS for PowerPC on Mac OS X? If not, what
Linux distro should I use? Any advice would really help.
Hi all,
So given that the Fcode evaluator is sorted for Solaris 10, I thought
I'd try my original Solaris 9 disk image again and was surprised to find
that it didn't boot.
Further investigation seems to show that strangely encoded device names
are being passed into cif-open which is failing:
: get-file ( 6000 ffe35870 27 )
00000000ffe36378: fname>devname$
3 > 2dup type /platform/OpenBiosTeam,OpenBIOS/ufsboot ok
3 > resume ok
( 6000 ffe35870 27 )
00000000ffe36378: fname>devname$ ( 6000 ffe35ee8 2f )
00000000ffe36380: ufs-fopen
3 > 2dup type cdrom:a,|platform|OpenBiosTeam,OpenBIOS|ufsboot ok
3 > resume ok
( 6000 ffe35ee8 2f )
00000000ffe36380: ufs-fopen
: ufs-fopen ( 6000 ffe35ee8 2f )
00000000ffe360e8: drop ( 6000 ffe35ee8 )
00000000ffe360f0: cif-open ( 6000 0 )
00000000ffe360f8: (semis)
: get-file ( 6000 ffe35870 17 )
00000000ffe36378: fname>devname$
3 > 2dup type /platform/sun4u/ufsboot ok
3 > resume ok
( 6000 ffe35870 17 )
00000000ffe36378: fname>devname$ ( 6000 ffe35ee8 1f )
00000000ffe36380: ufs-fopen
3 > 2dup type cdrom:a,|platform|sun4u|ufsboot ok
3 > resume ok
( 6000 ffe35ee8 1f )
00000000ffe36380: ufs-fopen
: ufs-fopen ( 6000 ffe35ee8 1f )
00000000ffe360e8: drop ( 6000 ffe35ee8 )
00000000ffe360f0: cif-open OFMEM: ofmem_claim_virt virt=ffffffffffffffff
size=0000000000000200 align=0000000000000001
( 6000 0 )
00000000ffe360f8: (semis)
It looks as if a special type of device-specifier is being passed into
cif-open consisting of a device and argument, a comma, then the actual
filename required with /s replaced by |s.
Is this some kind of special syntax that needs to be taught to the dev
word and/or cif-open words?
ATB,
Mark.
--
Mark Cave-Ayland - Senior Technical Architect
PostgreSQL - PostGIS
Sirius Corporation plc - control through freedom
http://www.siriusit.co.uk
t: +44 870 608 0063
Sirius Labs: http://www.siriusit.co.uk/labs
Hi all,
Having struggled to get hold of an old Debian ISO for SPARC32 testing,
I'm wondering would it be worth setting up a download area on
www.openfirmware.info for storing ISOs for OpenBIOS testing? We could
then setup a new page on the wiki which links to each ISO grouped by
platform (which would act as a rough regression checklist for patches).
Thoughts?
ATB,
Mark.
--
Mark Cave-Ayland - Senior Technical Architect
PostgreSQL - PostGIS
Sirius Corporation plc - control through freedom
http://www.siriusit.co.uk
t: +44 870 608 0063
Sirius Labs: http://www.siriusit.co.uk/labs
Author: mcayland
Date: Mon Jun 28 07:16:15 2010
New Revision: 803
URL: http://tracker.coreboot.org/trac/openbios/changeset/803
Log:
Fix up parse word so that it can correctly handle empty arguments and (encode-bootpath) word so that it can handle optional
arguments. With these fixes in place we can now switch the boot word to use (encode-bootpath) which means that the bootpath and
bootarg properties are now set exactly the same when executing boot and/or load.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland(a)siriusit.co.uk>
Modified:
trunk/openbios-devel/forth/admin/userboot.fs
trunk/openbios-devel/forth/bootstrap/bootstrap.fs
trunk/openbios-devel/forth/debugging/client.fs
Modified: trunk/openbios-devel/forth/admin/userboot.fs
==============================================================================
--- trunk/openbios-devel/forth/admin/userboot.fs Sun Jun 27 22:08:21 2010 (r802)
+++ trunk/openbios-devel/forth/admin/userboot.fs Mon Jun 28 07:16:15 2010 (r803)
@@ -1,7 +1,7 @@
\ 7.4.3.5 User commands for booting
: boot ( "{param-text}<cr>" -- )
- linefeed parse cr
+ (encode-bootpath)
s" platform-boot" $find if
execute
else
Modified: trunk/openbios-devel/forth/bootstrap/bootstrap.fs
==============================================================================
--- trunk/openbios-devel/forth/bootstrap/bootstrap.fs Sun Jun 27 22:08:21 2010 (r802)
+++ trunk/openbios-devel/forth/bootstrap/bootstrap.fs Mon Jun 28 07:16:15 2010 (r803)
@@ -704,6 +704,11 @@
>r \ save delimiter
ib >in @ +
span @ >in @ - \ ib+offs len-offset.
+ dup 0 < if \ if we are already at the end of the string, return an empty string
+ + 0 \ move to end of input string
+ r> drop
+ exit
+ then
2dup r> \ ib+offs len-offset ib+offs len-offset delim
findchar if \ look for the delimiter.
nip dup 1+
Modified: trunk/openbios-devel/forth/debugging/client.fs
==============================================================================
--- trunk/openbios-devel/forth/debugging/client.fs Sun Jun 27 22:08:21 2010 (r802)
+++ trunk/openbios-devel/forth/debugging/client.fs Mon Jun 28 07:16:15 2010 (r803)
@@ -56,13 +56,21 @@
;
: (encode-bootpath) ( "{params}<cr>" -- bootpath-str bootpath-len)
- bl parse 2dup encode-string
- " /chosen" (find-dev) if
- " bootpath" rot (property)
+ \ Parse the current input buffer of a load/boot command and set both
+ \ the bootargs and bootpath properties as appropriate.
+ bl parse dup if
+ 2dup encode-string
+ " /chosen" (find-dev) if
+ " bootpath" rot (property)
+ then
then
- linefeed parse encode-string
- " /chosen" (find-dev) if
- " bootargs" rot (property)
+ linefeed parse dup if
+ encode-string
+ " /chosen" (find-dev) if
+ " bootargs" rot (property)
+ then
+ else
+ 2drop
then
;