summary refs log tree commit diff
path: root/gnu/build/image.scm
diff options
context:
space:
mode:
authorEfraim Flashner <efraim@flashner.co.il>2022-12-12 10:27:40 +0200
committerEfraim Flashner <efraim@flashner.co.il>2022-12-12 10:47:59 +0200
commit45f5feb279860cde0d8032f05c3e5b45588b9609 (patch)
treefafb77bfd181c4a5bdfe52f621ae4998cb37af5f /gnu/build/image.scm
parent2d989ad59793e10c6fef94d9eaa51be91469318a (diff)
downloadguix-45f5feb279860cde0d8032f05c3e5b45588b9609.tar.gz
image: Use 512 byte blocks for EFI partitions.
Addresses <https://issues.guix.gnu.org/59695>.

* gnu/build/image.scm (make-vfat-image): When creating a fat filesystem
for UEFI bootable partition use 512 byte blocks.
Diffstat (limited to 'gnu/build/image.scm')
-rw-r--r--gnu/build/image.scm5
1 files changed, 4 insertions, 1 deletions
diff --git a/gnu/build/image.scm b/gnu/build/image.scm
index 2327cfbb45..65a0373980 100644
--- a/gnu/build/image.scm
+++ b/gnu/build/image.scm
@@ -111,7 +111,10 @@ turn doesn't take any constant overhead into account, force a 1-MiB minimum."
                            (if (eq? size 'guess)
                                (estimate-partition-size root)
                                size))
-                    (if (member 'esp flags) (list "-S" "1024") '()))
+                    ;; u-boot in particular needs the formatted block
+                    ;; size and the physical block size to be equal.
+                    ;; TODO: What about 4k blocks?
+                    (if (member 'esp flags) (list "-S" "512") '()))
     (for-each (lambda (file)
                 (unless (member file '("." ".."))
                   (invoke "mcopy" "-bsp" "-i" target