<html><head></head><body><div style="font-family:Helvetica Neue, Helvetica, Arial, sans-serif;font-size:13px;"><div></div>
<div><br></div><div>Ok, here's what I'm getting now:</div><div><br></div><div>C>> annot manage 'VGA controller' PCI device type 'display':<br>>> 10de 141 (3 0 0)<br><br>>> =============================================================<br>>> OpenBIOS 1.1 [Dec 17 2017 13:36]<br>>> Configuration device id QEMU version 1 machine id 2<br>>> CPUs: 1<br>>> Memory: 128M<br>>> UUID: 00000000-0000-0000-0000-000000000000<br>>> CPU type PowerPC,750<br>milliseconds isn't unique.<br>Welcome to OpenBIOS v1.1 built on Dec 17 2017 13:36<br><br>0 > load hd:,\ppc\6600.fcode ok<br>0 > 4000000 400 dump <br>4000000 55 aa 40 00 00 00 00 00 00 00 00 00 00 00 00 00 U�@.............<br>4000010 00 00 00 00 00 00 00 00 20 00 00 00 00 00 00 00 ........ .......<br>4000020 50 43 49 52 de 10 41 01 00 00 20 00 00 00 00 03 PCIR�.A... .....<br>4000030 84 00 00 00 01 80 00 00 00 00 00 00 00 00 00 00 �....�..........<br>4000040 f1 08 17 0f 00 01 06 55 12 2a 00 00 00 00 00 00 �......U.*......<br>4000050 00 00 00 00 de 10 50 00 3e 00 21 00 81 90 40 a3 ....�.P.>.!.��@�<br>4000060 00 00 00 00 90 04 00 80 00 00 a5 f4 00 00 00 00 ....�..�..��....<br>4000070 00 00 00 00 52 a5 b5 08 00 ba a5 10 00 00 00 08 ....R��..��.....<br>4000080 b5 08 01 be a7 b5 08 02 be a7 b5 08 03 be 10 00 �..���..���..�..<br>4000090 00 00 04 b5 08 04 be a7 b5 08 05 be a6 b5 08 06 ...�..���..���..<br>40000a0 be a6 b5 08 07 be a6 b5 08 08 be a6 b5 08 09 be ���..���..���..�<br>40000b0 a6 b5 08 0a be a6 b5 08 0b be a6 b5 08 0c be 10 ��..���..���..�.<br>40000c0 00 00 00 0a b5 08 0d be a5 b5 08 0e be a6 b5 08 ....�..���..���.<br>40000d0 0f be a6 b5 08 10 be a6 b5 08 11 be 10 00 00 00 .���..���..�....<br>40000e0 10 b5 08 12 be 10 00 00 00 48 b5 08 13 be a6 b5 .�..�....H�..���<br>40000f0 08 14 be a6 b5 08 15 be b5 08 16 ba a5 a7 b5 08 ..���..��..����.<br>4000100 17 be a6 b5 08 18 be a6 b5 08 19 be a6 b5 08 1a .���..���..���..<br>4000110 be a6 b5 08 1b be a6 b5 08 1c be a6 b5 08 1d be ���..���..���..�<br>4000120 a6 b5 08 1e be a6 b5 08 1f be a6 b5 08 20 be a6 ��..���..���. ��<br>4000130 b5 08 21 be a6 b5 08 22 be a6 b5 08 23 be a6 b5 �.!���."���.#���<br>4000140 08 24 be a6 b5 08 25 be a6 b5 08 26 be a6 b5 08 .$���.%���.&���.<br>4000150 27 be b5 08 28 ba a5 a6 b5 08 29 be a6 b5 08 2a '��.(����.)���.*<br>4000160 be a5 b5 08 2b be a6 b5 08 2c be 10 00 00 00 04 ���.+���.,�.....<br>4000170 b5 08 2d be a6 b5 08 2e be a6 b5 08 2f be a6 b5 �.-���..���./���<br>4000180 08 30 be a7 b5 08 31 be a7 b5 08 32 be 10 00 00 .0���.1���.2�...<br>4000190 00 06 b5 08 33 be 10 00 00 00 23 b5 08 34 be 10 ..�.3�....#�.4�.<br>40001a0 00 00 00 11 b5 08 35 be 10 00 00 00 09 b5 08 36 ....�.5�.....�.6<br>40001b0 be 10 00 00 00 2e b5 08 37 be a6 b5 08 38 be b5 �.....�.7���.8��<br>40001c0 08 39 ba a5 a6 b5 08 3a be a6 b5 08 3b be a6 b5 .9����.:���.;���<br>40001d0 08 3c be a6 b5 08 3d be a7 b5 08 3e be a7 b5 08 .<���.=���.>���.<br>40001e0 3f be a7 b5 08 40 be a7 b5 08 41 be a7 b5 08 42 ?���.@���.A���.B<br>40001f0 be a7 b5 08 43 be a7 b5 08 44 be a7 b5 08 45 be ���.C���.D���.E�<br>4000200 a7 b5 08 46 be a7 b5 08 47 be a7 b5 08 48 be a7 ��.F���.G���.H��<br>4000210 b5 08 49 be 10 00 00 00 04 b5 08 4a be a6 b5 08 �.I�.....�.J���.<br>4000220 4b be a6 b5 08 4c be a6 b5 08 4d be a6 b5 08 4e K���.L���.M���.N<br>4000230 be a6 b5 08 4f be a6 b5 08 50 be a6 b5 08 51 be ���.O���.P���.Q�<br>4000240 a6 b5 08 52 be 10 00 00 00 04 b5 08 53 be 10 00 ��.R�.....�.S�..<br>4000250 00 00 18 b5 08 54 be a6 b5 08 55 be a6 b5 08 56 ...�.T���.U���.V<br>4000260 be a6 b5 08 57 be a6 b5 08 58 be a6 b5 08 59 be ���.W���.X���.Y�<br>4000270 a6 b5 08 5a be a6 b5 08 5b be a6 b5 08 5c be 10 ��.Z���.[���.\�.<br>4000280 00 00 00 04 b5 08 5d be a6 b5 08 5e be a6 b5 08 ....�.]���.^���.<br>4000290 5f be a6 b5 08 60 be a6 b5 08 61 be a6 b5 08 62 _���.`���.a���.b<br>40002a0 be a6 b5 08 63 be a6 b5 08 64 be a6 b5 08 65 be ���.c���.d���.e�<br>40002b0 a7 b5 08 66 be a7 b5 08 67 be b5 08 68 ba a5 a6 ��.f���.g��.h���<br>40002c0 b5 08 69 be a6 b5 08 6a be a6 b5 08 6b be a6 b5 �.i���.j���.k���<br>40002d0 08 6c be a7 b5 08 6d be a7 b5 08 6e be a7 b5 08 .l���.m���.n���.<br>40002e0 6f be a7 b5 08 70 be a7 b5 08 71 be a6 b5 08 72 o���.p���.q���.r<br>40002f0 be a6 b5 08 73 be a6 b5 08 74 be a6 b5 08 75 be ���.s���.t���.u�<br>4000300 a6 b5 08 76 be b5 08 77 ba a5 a6 b5 08 78 be a6 ��.v��.w����.x��<br>4000310 b5 08 79 be a6 b5 08 7a be a6 b5 08 7b be 10 00 �.y���.z���.{�..<br>4000320 00 00 04 b5 08 7c be 10 00 00 00 04 b5 08 7d be ...�.|�.....�.}�<br>4000330 10 00 00 00 04 b5 08 7e be 10 00 00 00 04 b5 08 .....�.~�.....�.<br>4000340 7f be 10 00 00 00 04 b5 08 80 be 10 00 00 00 04 �.....�.��.....<br>4000350 b5 08 81 be b5 08 82 ba a5 10 00 00 00 04 b5 08 �.���.���.....�.<br>4000360 83 be 10 00 00 00 04 b5 08 84 be 10 00 00 00 04 ��.....�.��.....<br>4000370 b5 08 85 be 10 00 00 00 04 b5 08 86 be 10 00 00 �.��.....�.��...<br>4000380 00 04 b5 08 87 be 10 00 00 00 04 b5 08 88 be 10 ..�.��.....�.��.<br>4000390 00 00 00 04 b5 08 89 be 10 00 00 00 04 b5 08 8a ....�.��.....�.�<br>40003a0 be 10 00 00 00 04 b5 08 8b be 10 00 00 00 04 b5 �.....�.��.....�<br>40003b0 08 8c be 10 00 00 00 04 b5 08 8d be 10 00 00 00 .��.....�.��....<br>40003c0 04 b5 08 8e be b5 08 8f ba a5 a6 b5 08 90 be a6 .�.���.�����.���<br>40003d0 b5 08 91 be a6 b5 08 92 be a6 b5 08 93 be b5 08 �.����.����.���.<br>40003e0 94 ba a5 a6 b5 08 95 be a6 b5 08 96 be a7 b5 08 �����.����.����.<br>40003f0 97 be 10 00 00 00 04 b5 08 98 be 10 00 00 00 04 ��.....�.��.....<br> ok<br>0 > 0 0 " 4,0" " /pci@80000000" begin-package ok<br>0 > dev /pci ls <br>fff8043c QEMU,VGA@1<br>fff84a84 NE2000@2<br>fff84e5c mac-io@3<br>fff878ac pci10de,141@4<br>fff884f4 <noname><br> ok<br>0 > setenv focde-debug? true ok<br>0 > 4000020 1 byte-load ok<br>0 > dev /pci ls <br>fff8043c QEMU,VGA@1<br>fff84a84 NE2000@2<br>fff84e5c mac-io@3<br>fff878ac pci10de,141@4<br>fff884f4 <noname><br> ok<br>0 > printenv <br>name "options"<br>boot-args ""<br>boot-device "hd:,\\:tbxi hd:,\ppc\bootinfo.txt hd:,%BOOT"<br>use-generic? "false"<br>boot-script ""<br>boot-screen ""<br>vga-ndrv? "true"<br>virt-size "-1"<br>virt-base "-1"<br>load-base "4000000"<br>real-size "-1"<br>real-base "-1"<br>real-mode? "false"<br>little-endian? "false"<br>scroll-lock "true"<br>skip-netboot? "false"<br>default-mac-address "false"<br>pci-probe-mask "-1"<br>selftest-#megs "0"<br>screen-#rows "75"<br>screen-#columns "100"<br>output-device "/pci@80000000/mac-io@3/escc/ch-a"<br>input-device "/pci@80000000/mac-io@3/escc/ch-a"<br>use-nvramrc? "false"<br>oem-logo? "false"<br>oem-banner ""<br>oem-banner? "false"<br>nvramrc ""<br>fcode-debug? "false"<br>diag-switch? "false"<br>boot-file ""<br>boot-command "boot"<br>auto-boot? "false"<br>focde-debug? "true"<br> ok<br>0 > setenv fcode-debug? true ok<br>0 > 4000020 1 byte-load <br>byte-load: warning stack overflow, diff -3 <br> ok<br>0 > <br><br><div>I'm not sure, I'm assuming something in the Rom is casing a stack overflow?</div><div><br></div><div>Does openbios support fcode-verbose?</div><div><br></div><div>gdb '/home/jam/os9.2/obj-ppc/openbios-qemu.elf.nostrip' <br>GNU gdb (Debian 7.12-6) 7.12.0.20161007-git<br>Copyright (C) 2016 Free Software Foundation, Inc.<br>License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html><br>This is free software: you are free to change and redistribute it.<br>There is NO WARRANTY, to the extent permitted by law. Type "show copying"<br>and "show warranty" for details.<br>This GDB was configured as "x86_64-linux-gnu".<br>Type "show configuration" for configuration details.<br>For bug reporting instructions, please see:<br><http://www.gnu.org/software/gdb/bugs/>.<br>Find the GDB manual and other documentation resources online at:<br><http://www.gnu.org/software/gdb/documentation/>.<br>For help, type "help".<br>Type "apropos word" to search for commands related to "word"...<br>Reading symbols from /home/jam/os9.2/obj-ppc/openbios-qemu.elf.nostrip...done.<br>(gdb) target remote :1234<br>Remote debugging using :1234<br>warning: while parsing target description (at line 1): Target description specified unknown architecture "powerpc:common"<br>warning: Could not load XML target description; ignoring<br>0x00000000 in ?? ()<br>(gdb) b load<br>Breakpoint 1 at 0xfff16f7c: file /Users/jam/OpenBios/master/libopenbios/load.c, line 55.<br>(gdb) c<br>Continuing.<br><br>gdb isn't breaking at the load command, but I'm not sure that matters anymore, as it's working, anyway.<br></div></div>
<div id="yahoo_quoted_3587335112" class="yahoo_quoted">
<div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:13px;color:#26282a;">
<div>
On Sunday, December 17, 2017, 9:44:34 AM EST, Jd Lyons <lyons_dj@yahoo.com> wrote:
</div>
<div><br></div>
<div><br></div>
<div><div dir="ltr">Sorry, I forgot I remained the Rom file and was trying to load a file that didn’t exist, lead us down a false path.<br clear="none"><br clear="none">Loading the correct file and dumping the load base address does yell the Rom.<br clear="none"><br clear="none"><br clear="none"><div class="yqt5591216189" id="yqtfd28021"><br clear="none">> On Dec 17, 2017, at 9:02 AM, Mark Cave-Ayland <<a shape="rect" ymailto="mailto:mark.cave-ayland@ilande.co.uk" href="mailto:mark.cave-ayland@ilande.co.uk">mark.cave-ayland@ilande.co.uk</a>> wrote:<br clear="none">> <br clear="none">> On 17/12/17 13:53, Jd Lyons wrote:<br clear="none">> <br clear="none">>>> On Dec 17, 2017, at 7:56 AM, Mark Cave-Ayland <<a shape="rect" ymailto="mailto:mark.cave-ayland@ilande.co.uk" href="mailto:mark.cave-ayland@ilande.co.uk">mark.cave-ayland@ilande.co.uk</a>> wrote:<br clear="none">>>> <br clear="none">>>> On 17/12/17 12:41, Jd Lyons wrote:<br clear="none">>>> <br clear="none">>>>>>>> Also what FS is your HD image? HFS/HFS+ should work best on qemu-system-ppc, ISO9660 works but is case-sensitive from memory.<br clear="none">>>>>>> FS is HFS+, when I execute:<br clear="none">>>>>>>> dir hd:,\<br clear="none">>>>>>> I get the list of files, so I know I’m trying to load the Rom from the correct place, and OB can read the drive. I can:<br clear="none">>>>>>>> 4000 load hd:,\System\Library\CoreServices\BootX<br clear="none">>>>>>> And the system boots.<br clear="none">>>>>> <br clear="none">>>>>> Which version of QEMU/OpenBIOS are you using? load should only copy the code and run init-program, rather than set up a CPU context and execute go.<br clear="none">>>>>> <br clear="none">>>>>> Presumably you are building OpenBIOS from git master to get extra debugging information?<br clear="none">>>>> git clone <a shape="rect" href="https://github.com/openbios/openbios.git. " target="_blank">https://github.com/openbios/openbios.git. </a>?????<br clear="none">>>> <br clear="none">>>> Yes, that looks correct.<br clear="none">>>> <br clear="none">>>>> Not sure I’m pulling from the master or not.<br clear="none">>>>> Is there anything I need to do to enable extra debugging when I build?<br clear="none">>>>> PATH=:/usr/local/ppcelf/ppcelf/bin:/users/hsp/src/fcode-utils-devel/toke:$PATH<br clear="none">>>>> export PATH<br clear="none">>>>> Make -j8<br clear="none">>>> <br clear="none">>>> My normal build process for debugging OpenBIOS looks like this:<br clear="none">>>> <br clear="none">>>> vi Makefile.target<br clear="none">>>> <br clear="none">>>> (alter line 28 to build a debug ELF executable by changing the -Os option in CFLAGS to -O0)<br clear="none">>>> <br clear="none">>>> rm -rf obj-*;<br clear="none">>>> ./config/scripts/switch-arch ppc<br clear="none">>>> <br clear="none">>>> Then start QEMU from a separate terminal like this:<br clear="none">>>> <br clear="none">>>> ./qemu-system-ppc -bios /patch/to/openbios/obj-pp/openbios-qemu.elf.nostrip -s -S<br clear="none">>> Seems to fail here, never boots with -S?<br clear="none">> <br clear="none">> Yes indeed. -s -S tell QEMU to wait until the remote gdb connects to QEMU before starting the VM.<br clear="none">> <br clear="none">>>> <br clear="none">>>> Swtich back to your OpenBIOS terminal and then do:<br clear="none">>>> <br clear="none">>>> powerpc-linux-gdb obj-ppc/openbios-qemu.elf.nostrip<br clear="none">>>> target remote :1234 (connect to QEMU gdbstub)<br clear="none">>>> b load (set breakpoint in libopenbios/load.c's load() function)<br clear="none">>>> c<br clear="none">>>> <br clear="none">>>> You should then find that when you type load into OpenBIOS gdb hits the breakpoint and you can step through the C parts of the code to see what happens. Sadly gdb doesn't have support for debugging Forth, but if you can get this working it will help a lot since all of the ELF/load/init-program and PCI routines are all in C.<br clear="none">>>> <br clear="none">>>>> I didn’t thing the 4000 load hd:,\bootx should boot the system, yet it does. Assuming I put BootX at the root of my drive, I was thinking it should just load it into system memory at the address 4000. Adding -h doesn’t help, nor does adding -h to the boot command, I’m assuming -h is unemiplmented in Openbios.<br clear="none">>>> <br clear="none">>>> You actually don't need the 4000 since according to the specification "load" places the resulting image at the location specified by load-base:<br clear="none">>>> <br clear="none">>>> 0 > cd /options ok<br clear="none">>>> 0 > .properties<br clear="none">>>> name "options"<br clear="none">>>> boot-args ""<br clear="none">>>> boot-device "hd:,\\:tbxi hd:,\ppc\bootinfo.txt hd:,%BOOT"<br clear="none">>>> use-generic? "false"<br clear="none">>>> boot-script ""<br clear="none">>>> boot-screen ""<br clear="none">>>> vga-ndrv? "true"<br clear="none">>>> virt-size "-1"<br clear="none">>>> virt-base "-1"<br clear="none">>>> load-base "4000000"<br clear="none">>>> real-size "-1"<br clear="none">>>> real-base "-1"<br clear="none">>>> real-mode? "false"<br clear="none">>>> little-endian? "false"<br clear="none">>>> scroll-lock "true"<br clear="none">>>> skip-netboot? "false"<br clear="none">>>> default-mac-address "false"<br clear="none">>>> pci-probe-mask "-1"<br clear="none">>>> selftest-#megs "0"<br clear="none">>>> screen-#rows "75"<br clear="none">>>> screen-#columns "100"<br clear="none">>>> output-device "/<a shape="rect" ymailto="mailto:pci@80000000" href="mailto:pci@80000000">pci@80000000</a>/<a shape="rect" ymailto="mailto:mac-io@3" href="mailto:mac-io@3">mac-io@3</a>/escc/ch-a"<br clear="none">>>> input-device "/<a shape="rect" ymailto="mailto:pci@80000000" href="mailto:pci@80000000">pci@80000000</a>/<a shape="rect" ymailto="mailto:mac-io@3" href="mailto:mac-io@3">mac-io@3</a>/escc/ch-a"<br clear="none">>>> use-nvramrc? "false"<br clear="none">>>> oem-logo? "false"<br clear="none">>>> oem-banner ""<br clear="none">>>> oem-banner? "false"<br clear="none">>>> nvramrc ""<br clear="none">>>> fcode-debug? "false"<br clear="none">>>> diag-switch? "false"<br clear="none">>>> boot-file ""<br clear="none">>>> boot-command "boot"<br clear="none">>>> auto-boot? "true"<br clear="none">>>> ok<br clear="none">>>> 0 ><br clear="none">>>> <br clear="none">>>> Ahhh so wait a second - load-base is set to 0x4000000 rather than 0x4000 which is the default in SPARC. So how about something like:<br clear="none">>>> <br clear="none">>>> load hd:,\6600.fcode<br clear="none">>>> 4000000 40 dump<br clear="none">> <br clear="none">> Any luck with this bit on your existing setup?<br clear="none">> <br clear="none">> <br clear="none">> ATB,<br clear="none">> <br clear="none">> Mark.<br clear="none"></div></div></div>
</div>
</div></div></body></html>