Sound support in PS2 Linux (BlackRhino, Kernel 2.4.17)

Thu, 11 May 2023 12:00:00 +0000

Linux can run on the PS2, and with some additional firmware modules for the IOP, even sound support can work on Kernel 2.4.17. Newer ports of Linux (e.g. version 5.4) also exist, but are currently lacking driver support for the sound hardware.

Using FreeMCBoot, Kernelloader 3.0, a suitable kernel and the BlackRhino Linux Live DVD v3, one can easily boot Linux on PS2 consoles.

The Kernelloader is also included in the ISO image as KLOADER.ELF, you might need to copy it to your Memory Card or USB Mass Storage for uLaunchELF to find it, and Kernel 2.4.17 is available on the DVD as BOOT/VMLINUX.GZ (if you are using kernelloader to boot from DVD, it will find the kernel from there), so practically all you need is the ISO burned to a DVD (I downloaded and extracted ps2linux_live_v3_pal_large_no_modchip.7z), then copy KLOADER.ELF to a USB mass storage device (uLaunchELF wasn't able to "see" any files on cdrom0:) and launch KLOADER.ELF and let it boot.

You can probably also use the Live USB and boot this way if you don't want to burn optical media and/or your optical drive is broken, but I haven't tested this.

If you have a Fat PS2 and a HDD, installing of the distro to the HDD (and booting off the HDD) is described very well in this YouTube tutorial.

Additional sound support IRX files

What does not work out of the box is sound output, due to missing modules for the IOP (this is described in the kernelloader README as well as the README of the Live DVD).

The two files that worked for me were (with shasum):

b5cb57dba538cd8d4c794710ce8bb2623c3cd14f LIBSD.IRX
1b7f990b666ed750c4fab870d763379df1f854eb SDRDRV.IRX

MD5 sums for the same files:

a85051a7ddad7e255d06f6532db1f982 LIBSD.IRX
0c282b102cea27664a7ae9dc12a87af6 SDRDRV.IRX

The files can be extracted from the stock PS2 Linux installation discs, as shipped with the Linux Kit (expensive on eBay these days), or on archive.org: PS2 Linux PAL Installation Discs.

For the archive.org link, if you click on "Show All" for the download options and then click on "View Contents" for DISC1.iso, you can directly download MODULES/MOD203/LIBSD.IRX and MODULES/MOD203/SDRDRV.IRX without having to download the full 1 GB ISO.

Once you have the files, place them in mc0:/kloader/ (all-uppercase filenames are fine here). Then, when in the kernelloader menu, there are two checkmarks that you need to tick to enable loading of those modules. Save the configuration, reboot and the next time to boot into PS2 Linux, the OSS-based sound driver should be working, and you can use xmms and other tools for background music :)

Sound support in newer kernels

A more modern port of Linux to the PS2 is maintained by Fredrik Noring on Github.

There was even an attempt to mainline the changes in 2019, and the Git repository itself has commits up to late 2022.

A build of Linux 5.4.221+ is available on the releases page, the vmlinuz-pal-ps2-main-fc13b3ef.elf can be launched directly with uLaunchELF and contains the kernel and the initramfs, but there's no sound support yet.