guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#48880] [PATCH] gnu: Respect ‘rootdelay’ kernel command-line argumen


From: Tobias Geerinckx-Rice
Subject: [bug#48880] [PATCH] gnu: Respect ‘rootdelay’ kernel command-line argument.
Date: Sun, 6 Jun 2021 21:04:30 +0200

* gnu/build/linux-boot.scm (boot-system): Sleep for "rootdelay=SECONDS"
when specified on the kernel command line.
---

 gnu/build/linux-boot.scm | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/gnu/build/linux-boot.scm b/gnu/build/linux-boot.scm
index 37c0dcb265..e1014c7efe 100644
--- a/gnu/build/linux-boot.scm
+++ b/gnu/build/linux-boot.scm
@@ -594,6 +594,14 @@ upon error."
           (unless (configure-qemu-networking)
             (display "network interface is DOWN\n")))
 
+        (let ((root-delay (and=> (find-long-option "rootdelay" args)
+                                 string->number)))
+          (when root-delay
+            (format #t
+                    "Pausing for rootdelay=~a seconds before mounting the root 
file system...\n"
+                    root-delay)
+            (sleep root-delay)))
+
         ;; Prepare the real root file system under /root.
         (unless (file-exists? "/root")
           (mkdir "/root"))
-- 
2.32.0






reply via email to

[Prev in Thread] Current Thread [Next in Thread]