summaryrefslogtreecommitdiff
path: root/gnu/installer/parted.scm
diff options
context:
space:
mode:
authorMathieu Othacehe <othacehe@gnu.org>2022-08-05 08:50:51 +0200
committerMathieu Othacehe <othacehe@gnu.org>2022-08-05 08:57:20 +0200
commit3c381af76a144a4dc3d0f9269f43ee2ec501b538 (patch)
treedfd21da54a5d81385be4cd205c88bc91f191e495 /gnu/installer/parted.scm
parenteb0277e7e391319a5377084dd2d18c7114ec9a8a (diff)
installer: parted: Call set-system before set-flags.
Parted 3.5 introduces the following regression: - partition-set-flag sets the BIOS_GRUB flag. The partition type is set to PARTITION_BIOS_GRUB_GUID. - partition-set-system resets the partition type to PARTITION_LINUX_DATA_GUID undoing what's done by partition-set-flag. To prevent it, reverse the call order. Fixes: <https://issues.guix.gnu.org/55549>. * gnu/installer/parted.scm (mkpart): Call partition-set-system before partition-set-flag.
Diffstat (limited to 'gnu/installer/parted.scm')
-rw-r--r--gnu/installer/parted.scm11
1 files changed, 7 insertions, 4 deletions
diff --git a/gnu/installer/parted.scm b/gnu/installer/parted.scm
index 6c823e77eb6..ba0a38fff8f 100644
--- a/gnu/installer/parted.scm
+++ b/gnu/installer/parted.scm
@@ -845,15 +845,18 @@ cause them to cross."
845 (when (and partition-ok? has-name? name) 845 (when (and partition-ok? has-name? name)
846 (partition-set-name partition name)) 846 (partition-set-name partition name))
847 847
848 ;; Set flags is required. 848 ;; Both partition-set-system and partition-set-flag calls can affect
849 ;; the partition type. Their order is important, see:
850 ;; https://issues.guix.gnu.org/55549.
851 (partition-set-system partition filesystem-type)
852
853 ;; Set flags if required.
849 (for-each (lambda (flag) 854 (for-each (lambda (flag)
850 (and (partition-is-flag-available? partition flag) 855 (and (partition-is-flag-available? partition flag)
851 (partition-set-flag partition flag 1))) 856 (partition-set-flag partition flag 1)))
852 flags) 857 flags)
853 858
854 (and partition-ok? 859 (and partition-ok? partition))))))
855 (partition-set-system partition filesystem-type)
856 partition))))))
857 860
858 861
859;; 862;;