From e07ad9d0654d4bf887757160355abbd33b3b0d39 Mon Sep 17 00:00:00 2001 From: OPNA2608 Date: Tue, 3 Feb 2026 15:24:14 +0100 Subject: [PATCH 1/2] linux: Build-in HFS+ support on POWER To get an installer ISO recognised on some systems (Apple PowerMac G5 is what I'm working with), it must be made with certain flags to xorriso that make the ISO9660 filesystem accessible as an HFS+ partition, to allow HFS+ blessing of the boot files. Changes for that will be submitted at a later date. When such an image is booted with the current kernel settings (DVD/USB, doesn't matter), GRUB works fine, but the kernel gets stuck. There is no textual boot output on the machine at the point where it gets stuck, so I can't really debug. A basic ISO9660 image (booted directly via firmware commands) goes all the way to the shell without issues, so the issue is with the HFS+ partition format. Building the HFS+ module into the kernel seems to fix this. Some older machines are supposedly unable to read HFS+ and may instead need HFS. Such a disc setup might not be producable with xorriso (haven't played around with that), and I don't have one of those machines to test anything on, so I won't include HFS_FS for now. --- pkgs/os-specific/linux/kernel/common-config.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkgs/os-specific/linux/kernel/common-config.nix b/pkgs/os-specific/linux/kernel/common-config.nix index d1734a2b32c5..4fa7506f842f 100644 --- a/pkgs/os-specific/linux/kernel/common-config.nix +++ b/pkgs/os-specific/linux/kernel/common-config.nix @@ -786,6 +786,10 @@ let DEVTMPFS = yes; UNICODE = yes; # Casefolding support for filesystems + } + // lib.optionalAttrs stdenv.hostPlatform.isPower { + # Needed to use the installation iso image formatted for tbxi booting (ISO9660 w/ hybrid HFS+ partition). + HFSPLUS_FS = yes; }; security = { From 48d00af90d7012116805d5f8e2756c79f7c5c917 Mon Sep 17 00:00:00 2001 From: OPNA2608 Date: Sun, 8 Feb 2026 17:50:55 +0100 Subject: [PATCH 2/2] linux: Build-in IDE & MacIO support on POWER The built-in graphical boot manager on PowerMacs usually doesn't acknowledge USBs. If one wants to boot an installer without messing around in Open Firmware, then a disc must be used. The disc drives in PowerMacs are connected via IDE, and will get stuck during early boot if IDE/ATA support is not built into the kernel. The PATA_MACIO option is also needed to handle the particular controller used on Macs. --- pkgs/os-specific/linux/kernel/common-config.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkgs/os-specific/linux/kernel/common-config.nix b/pkgs/os-specific/linux/kernel/common-config.nix index 4fa7506f842f..b9fbf238c996 100644 --- a/pkgs/os-specific/linux/kernel/common-config.nix +++ b/pkgs/os-specific/linux/kernel/common-config.nix @@ -1615,6 +1615,12 @@ let # > round to working out why. The workaround is to build it in[…]. # > (It won't do any harm on non-Mac systems.) I2C_POWERMAC = yes; + } + // lib.optionalAttrs stdenv.hostPlatform.isPower { + # Needed for booting PowerMacs from disc + # (the only nice way that doesn't involve messing around with internal drives or in Open Firmware) + ATA = yes; + PATA_MACIO = yes; }; accel = {