a loose pile of links, notes, and things worth keeping.
QEMU SPARC64 - the first touch

For more than a decade I’ve followed QEMU SPARC emulation with hope, especially Artyom Tarasenko’s experiments. Claude has helped unlock a lot of possibilities for progressing the SPARC64 emulation project, for a relatively small fee.

When I started reviewing the possibilities, it seemed like a good idea to test bootability across [Open]Solaris releases, from the earliest to the latest, and systematically track the status of each one. It’s a relatively small cost of effort — you just need a list of [Open]Solaris builds and check each one for progress.

Most of Artyom’s blog intensive work is based on Solaris Express images (or “snv” in Sun-era terminology), built for the Sun OpenSPARC project. All of these OpenSPARC images use ufs ramdrive with relatively tiny sizes, hundreds of megabytes. At this time, two well-known bootable drives are disk.s10hw2 from the OpenSPARC T1 emulator archive dated circa 2006, and another one, ramdisk.snv-b77-nd.no-boot-time-network.gz. With b77 it should be not too late than mid 2007.

When trying to load a full-capable ISO image, i.e. Solaris 10, it looks like this:

/home/dpim/build/qemu-sparc64/qemu-system-sparc64 -M niagara -L /home/dpim/images/S10image -nographic -m 256 -drive if=pflash,readonly=on,file=/zroot/iso/s10u11/V36434-01.iso

qemu-system-sparc64: could not load ram disk '/zroot/iso/s10u11/V36434-01.iso'

Our first touch of the code directly unlocked the ability to use >2GB vdisks during the copy into memory. It just prevents large (>2 GiB) vdisk images from silently getting corrupted or truncated when copied into the ramdisk region.

And now we’re able to boot, i.e.:

/home/dpim/build/qemu-sparc64/qemu-system-sparc64 -M niagara -L /home/dpim/images/S10image -nographic -m 256 -drive if=pflash,readonly=on,file=/zroot/iso/s10u11/V36434-01.iso
<..>
cpu Probing I/O buses
Sun Fire T2000, No Keyboard
Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
OpenBoot 4.20.0, 256 MB memory available, Serial #1122867.
[mo23723 obp4.20.0 #0]
Ethernet address 0:80:3:de:ad:3, Host ID: 80112233.
ok boot /virtual-devices/disk@0:f
Boot device: /virtual-devices/disk@0:f  File and args:
hsfs-file-system
Loading: /platform/sun4v/boot_archive
<...>

The qemu now starts successfully and recognizes the iso image for booting!