From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59589) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eqgbu-0006zf-3L for guix-patches@gnu.org; Tue, 27 Feb 2018 09:52:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eqgbq-0006cO-Mo for guix-patches@gnu.org; Tue, 27 Feb 2018 09:52:06 -0500 Received: from debbugs.gnu.org ([208.118.235.43]:54969) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eqgbq-0006bK-IT for guix-patches@gnu.org; Tue, 27 Feb 2018 09:52:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1eqgbq-0004BF-CW for guix-patches@gnu.org; Tue, 27 Feb 2018 09:52:02 -0500 Subject: [bug#30604] [PATCH v5 7/7] linux-boot: Call make-static-device-nodes much earlier. Resent-Message-ID: From: Danny Milosavljevic Date: Tue, 27 Feb 2018 16:50:51 +0100 Message-Id: <20180227155051.1141-8-dannym@scratchpost.org> In-Reply-To: <20180227155051.1141-1-dannym@scratchpost.org> References: <20180227112619.5071-1-dannym@scratchpost.org> <20180227155051.1141-1-dannym@scratchpost.org> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: 30604@debbugs.gnu.org * gnu/system/linux-initrd.scm (expression->initrd): Store data files for make-static-device-nodes. * gnu/build/linux-boot.scm (boot-system): Call make-static-device-nodes. Delete lookup-module. --- gnu/build/linux-boot.scm | 13 +++++++++---- gnu/system/linux-initrd.scm | 3 ++- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/gnu/build/linux-boot.scm b/gnu/build/linux-boot.scm index 6d00ea9be..1b16f267a 100644 --- a/gnu/build/linux-boot.scm +++ b/gnu/build/linux-boot.scm @@ -469,10 +469,6 @@ upon error." mounts) "ext4")) - (define (lookup-module name) - (string-append linux-module-directory "/" - (ensure-dot-ko name))) - (define (load-kernel-modules) "Examine /sys/devices to find out which modules to load and load them." (define enter? @@ -512,6 +508,15 @@ upon error." (when (member "--repl" args) (start-repl)) + (let* ((kernel-release + (utsname:release (uname))) + (directory + (string-append linux-module-directory "/lib/modules/" + kernel-release)) + (old-umask (umask #o022))) + (make-static-device-nodes directory) + (umask old-umask)) + (load-kernel-modules) (when qemu-guest-networking?