diff --git a/fedac/native/Dockerfile.builder b/fedac/native/Dockerfile.builder index 6e833126e..d9d8fb39c 100644 --- a/fedac/native/Dockerfile.builder +++ b/fedac/native/Dockerfile.builder @@ -22,6 +22,7 @@ RUN dnf install -y --setopt=install_weak_deps=False \ iwlwifi-mvm-firmware wireless-regdb \ linux-firmware linux-firmware-whence \ intel-gpu-firmware \ + realtek-firmware \ alsa-sof-firmware \ busybox mtools dosfstools hfsplus-tools hfsutils gdisk parted \ mesa-libgbm mesa-libgbm-devel \ diff --git a/fedac/native/docker-build.sh b/fedac/native/docker-build.sh index dcf9b911d..d310f8b8d 100644 --- a/fedac/native/docker-build.sh +++ b/fedac/native/docker-build.sh @@ -429,14 +429,21 @@ if [ -n "$FWDIR" ]; then # (Jasper Lake, Alder Lake, Tiger Lake…) and many modern laptops where # audio doesn't go through plain HDA. Need the main .ri blob per # platform plus the matching topology under sof-tplg/. + # + # Recurse: Fedora's alsa-sof-firmware puts sof-.ri under + # intel/sof/community/ and intel/sof/intel-signed/ (not directly under + # intel/sof/), so a flat glob misses them. We preserve relative paths + # so the kernel's firmware loader still finds them along the standard + # SOF_FW_PATH search (which covers both community and intel-signed). for subdir in intel/sof intel/sof-tplg intel/sof-ace-tplg; do src="$FWDIR/$subdir" if [ -d "$src" ]; then mkdir -p "$IROOT/lib/firmware/$subdir" - for fw in "$src"/*.ri "$src"/*.tplg "$src"/*.tplg.xz "$src"/*.ri.xz \ - "$src"/*.ri.zst "$src"/*.tplg.zst; do - [ -f "$fw" ] && cp -L "$fw" "$IROOT/lib/firmware/$subdir/" - done + (cd "$src" && find . -type f \ + \( -name '*.ri' -o -name '*.tplg' \ + -o -name '*.ri.xz' -o -name '*.tplg.xz' \ + -o -name '*.ri.zst' -o -name '*.tplg.zst' \) \ + -exec cp --parents -L {} "$IROOT/lib/firmware/$subdir/" \;) || true fi done else diff --git a/fedac/native/kernel/config-minimal b/fedac/native/kernel/config-minimal index 833ebf267..892d01e77 100644 --- a/fedac/native/kernel/config-minimal +++ b/fedac/native/kernel/config-minimal @@ -424,7 +424,7 @@ CONFIG_HOTPLUG_CPU=y CONFIG_LEGACY_VSYSCALL_XONLY=y # CONFIG_LEGACY_VSYSCALL_NONE is not set CONFIG_CMDLINE_BOOL=y -CONFIG_CMDLINE="console=tty0 quiet loglevel=3 vt.global_cursor_default=0 init=/init mitigations=off snd_hda_intel.power_save=0 nmi_watchdog=0 tsc=reliable no_timer_check acpi_backlight=native thinkpad_acpi.brightness_enable=1 i8042.reset i8042.nomux" +CONFIG_CMDLINE="console=tty0 quiet loglevel=3 vt.global_cursor_default=0 init=/init mitigations=off snd_hda_intel.power_save=0 nmi_watchdog=0 tsc=reliable no_timer_check acpi_backlight=native thinkpad_acpi.brightness_enable=1 i8042.reset i8042.nomux reboot=efi,cold" # CONFIG_CMDLINE_OVERRIDE is not set CONFIG_MODIFY_LDT_SYSCALL=y # CONFIG_STRICT_SIGALTSTACK_SIZE is not set diff --git a/fedac/native/src/ac-native.c b/fedac/native/src/ac-native.c index 4e5109594..0f50667cc 100644 --- a/fedac/native/src/ac-native.c +++ b/fedac/native/src/ac-native.c @@ -1506,6 +1506,25 @@ static int auto_install_to_hd(ACGraph *graph, ACFramebuffer *screen, DLOG, parent_blk, DLOG, parent_blk, DLOG, parent_blk, DLOG, parent_blk, DLOG); system(rcmd); + // sfdisk wrote a single partition → the new ESP is p1 on + // the parent disk, regardless of what partition index we + // entered this branch with. Chromebook case: we arrived + // via devpath=/dev/mmcblk1p12 (existing 16MB EFI-SYSTEM), + // sfdisk rewrote the table to a single 1024MB entry at + // p1 and wiped p12 entirely — so mkfs + mount need to + // target the new partition, not the old devpath. + char new_devpath[48]; + if (parent_blk[0] == 'n' || strncmp(parent_blk, "mmcblk", 6) == 0) { + snprintf(new_devpath, sizeof(new_devpath), "/dev/%sp1", parent_blk); + } else { + snprintf(new_devpath, sizeof(new_devpath), "/dev/%s1", parent_blk); + } + if (strcmp(new_devpath, devpath) != 0) { + ac_log("[install] canonicalizing devpath %s → %s after sfdisk\n", + devpath, new_devpath); + strncpy(devpath, new_devpath, sizeof(devpath) - 1); + devpath[sizeof(devpath) - 1] = '\0'; + } // Wait for partition device node to appear (up to 10s) int devpath_ready = 0; for (int wait = 0; wait < 20; wait++) {