From ad331efcaf680eb1c838cb339472399ea7b3cdab Mon Sep 17 00:00:00 2001 From: John Titor <50095635+JohnRTitor@users.noreply.github.com> Date: Mon, 26 May 2025 13:35:23 +0530 Subject: [PATCH] nixos/qemu-vm: useBootPartition -> useBIOSBoot useBootPartition was ambiguous, this makes the option more like useEFIBoot Signed-off-by: John Titor <50095635+JohnRTitor@users.noreply.github.com> --- nixos/modules/virtualisation/qemu-vm.nix | 14 +++++++------- nixos/tests/limine/bios.nix | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/nixos/modules/virtualisation/qemu-vm.nix b/nixos/modules/virtualisation/qemu-vm.nix index ce1773a2f86c..02f653922c34 100644 --- a/nixos/modules/virtualisation/qemu-vm.nix +++ b/nixos/modules/virtualisation/qemu-vm.nix @@ -65,12 +65,12 @@ let { useEFIBoot, useDefaultFilesystems, - useBootPartition, + useBIOSBoot, }: if useDefaultFilesystems then if useEFIBoot then "efi" - else if useBootPartition then + else if useBIOSBoot then "legacy+boot" else "legacy" @@ -350,7 +350,7 @@ let onlyNixStore = false; label = rootFilesystemLabel; partitionTableType = selectPartitionTableLayout { - inherit (cfg) useBootPartition useDefaultFilesystems useEFIBoot; + inherit (cfg) useBIOSBoot useDefaultFilesystems useEFIBoot; }; installBootLoader = cfg.installBootLoader; touchEFIVars = cfg.useEFIBoot; @@ -448,13 +448,13 @@ in default = if cfg.useEFIBoot then "/dev/disk/by-label/${espFilesystemLabel}" - else if cfg.useBootPartition then + else if cfg.useBIOSBoot then "/dev/disk/by-label/BOOT" else null; defaultText = literalExpression '' if cfg.useEFIBoot then "/dev/disk/by-label/${espFilesystemLabel}" - else if cfg.useBootPartition then "/dev/disk/by-label/BOOT" + else if cfg.useBIOSBoot then "/dev/disk/by-label/BOOT" else null''; example = "/dev/disk/by-label/esp"; description = '' @@ -952,11 +952,11 @@ in ''; }; - virtualisation.useBootPartition = mkEnableOption null // { + virtualisation.useBIOSBoot = mkEnableOption null // { description = '' If enabled for legacy MBR VMs, the VM image will have a separate boot partition mounted at /boot. - useBootPartition is ignored if useEFIBoot == true. + useBIOSBoot is ignored if useEFIBoot == true. ''; }; diff --git a/nixos/tests/limine/bios.nix b/nixos/tests/limine/bios.nix index bc22af764c66..5d367934b660 100644 --- a/nixos/tests/limine/bios.nix +++ b/nixos/tests/limine/bios.nix @@ -14,7 +14,7 @@ { ... }: { virtualisation.useBootLoader = true; - virtualisation.useBootPartition = true; + virtualisation.useBIOSBoot = true; boot.loader.limine.enable = true; boot.loader.limine.efiSupport = false; boot.loader.timeout = 0;