From: Herman Rimm via Guix-patches via <guix-patches@gnu.org>
To: 73202@debbugs.gnu.org
Cc: Lilah Tascheter <lilah@lunabee.space>
Subject: [bug#73202] [PATCH v3 02/14] gnu: system: Remove useless boot parameters.
Date: Thu, 26 Sep 2024 12:08:59 +0200 [thread overview]
Message-ID: <c0d6bcb2d8c56569b96ac9674de337188dd77c0b.1727345067.git.herman@rimm.ee> (raw)
In-Reply-To: <74c789e74594d538308d33633ed8540283dcde49.1727345067.git.herman@rimm.ee>
From: Lilah Tascheter <lilah@lunabee.space>
* gnu/system.scm (operating-system-boot-parameters,
operating-system-boot-parameters-file): Delete bootloader-menu-entries.
* gnu/system/boot.scm (boot-parameters)[bootloader-menu-entries]: Delete
field.
(read-boot-parameters): Don't read bootloader-menu-entries.
* tests/boot-parameters.scm (%grub-boot-parameters,
test-read-boot-parameters, test-read-boot-parameters): Don't include
bootloader-menu-entries.
("read, bootloader-menu-entries, default value"): Delete test.
Change-Id: I46d9cff4604dbfcf654b0820fdb77e72aecffbb4
---
gnu/system.scm | 7 -------
gnu/system/boot.scm | 8 --------
tests/boot-parameters.scm | 18 +++++-------------
3 files changed, 5 insertions(+), 28 deletions(-)
diff --git a/gnu/system.scm b/gnu/system.scm
index 25afa96295..a3eee5aa24 100644
--- a/gnu/system.scm
+++ b/gnu/system.scm
@@ -1298,8 +1298,6 @@ (define* (operating-system-boot-parameters os root-device
(initrd initrd)
(multiboot-modules multiboot-modules)
(bootloader-name bootloader-name)
- (bootloader-menu-entries
- (bootloader-configuration-menu-entries (operating-system-bootloader os)))
(locale locale)
(store-device (ensure-not-/dev (file-system-device store)))
(store-directory-prefix (btrfs-store-subvolume-file-name file-systems))
@@ -1341,11 +1339,6 @@ (define* (operating-system-boot-parameters-file os)
#$(boot-parameters-multiboot-modules params)))
#~())
(bootloader-name #$(boot-parameters-bootloader-name params))
- (bootloader-menu-entries
- #$(map menu-entry->sexp
- (or (and=> (operating-system-bootloader os)
- bootloader-configuration-menu-entries)
- '())))
(locale #$(boot-parameters-locale params))
(store
(device
diff --git a/gnu/system/boot.scm b/gnu/system/boot.scm
index de312c7208..54e5673a54 100644
--- a/gnu/system/boot.scm
+++ b/gnu/system/boot.scm
@@ -51,7 +51,6 @@ (define-module (gnu system boot)
boot-parameters-label
boot-parameters-root-device
boot-parameters-bootloader-name
- boot-parameters-bootloader-menu-entries
boot-parameters-store-crypto-devices
boot-parameters-store-device
boot-parameters-store-directory-prefix
@@ -110,8 +109,6 @@ (define-record-type* <boot-parameters>
;; partition.
(root-device boot-parameters-root-device)
(bootloader-name boot-parameters-bootloader-name)
- (bootloader-menu-entries ;list of <menu-entry>
- boot-parameters-bootloader-menu-entries)
(store-device boot-parameters-store-device)
(store-mount-point boot-parameters-store-mount-point)
(store-directory-prefix boot-parameters-store-directory-prefix)
@@ -172,11 +169,6 @@ (define (read-boot-parameters port)
((_ args) args)
(#f 'grub))) ; for compatibility reasons.
- (bootloader-menu-entries
- (match (assq 'bootloader-menu-entries rest)
- ((_ entries) (map sexp->menu-entry entries))
- (#f '())))
-
;; In the past, we would store the directory name of linux instead of
;; the absolute file name of its image. Detect that and correct it.
(kernel (if (string=? kernel (direct-store-path kernel))
diff --git a/tests/boot-parameters.scm b/tests/boot-parameters.scm
index 2e7976aa6c..e1dc4620c3 100644
--- a/tests/boot-parameters.scm
+++ b/tests/boot-parameters.scm
@@ -1,6 +1,7 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2019, 2020 Miguel Ángel Arruga Vivas <rosen644835@gmail.com>
;;; Copyright © 2022 Josselin Poiret <dev@jpoiret.xyz>
+;;; Copyright © 2024 Herman Rimm <herman@rimm.ee>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -34,6 +35,7 @@ (define-module (test-boot-parameters)
#:use-module (guix gexp)
#:use-module (guix store)
#:use-module (guix tests)
+ #:use-module (ice-9 format)
#:use-module (srfi srfi-34)
#:use-module (srfi srfi-64)
#:use-module (rnrs bytevectors))
@@ -64,7 +66,6 @@ (define %root-path "/")
(define %grub-boot-parameters
(boot-parameters
(bootloader-name 'grub)
- (bootloader-menu-entries '())
(root-device %default-root-device)
(label %default-label)
(kernel %default-kernel)
@@ -107,7 +108,6 @@ (define* (test-read-boot-parameters
#:key
(version %boot-parameters-version)
(bootloader-name 'grub)
- (bootloader-menu-entries '())
(label %default-label)
(root-device (quote-uuid %default-root-device))
(kernel %default-kernel)
@@ -127,7 +127,7 @@ (define* (test-read-boot-parameters
(cond ((eq? 'false val) (format #false fmt #false))
(val (format #false fmt val))
(else "")))
- (format #false "(boot-parameters~a~a~a~a~a~a~a~a~a~a)"
+ (format #f "(boot-parameters~@{~a~})"
(sexp-or-nothing " (version ~S)" version)
(sexp-or-nothing " (label ~S)" label)
(sexp-or-nothing " (root-device ~S)" root-device)
@@ -135,7 +135,7 @@ (define* (test-read-boot-parameters
(sexp-or-nothing " (kernel-arguments ~S)" kernel-arguments)
(sexp-or-nothing " (initrd ~S)" initrd)
(if with-store
- (format #false " (store~a~a~a~a)"
+ (format #f " (store~@{~a~})"
(sexp-or-nothing " (device ~S)" store-device)
(sexp-or-nothing " (mount-point ~S)"
store-mount-point)
@@ -145,9 +145,7 @@ (define* (test-read-boot-parameters
store-crypto-devices))
"")
(sexp-or-nothing " (locale ~S)" locale)
- (sexp-or-nothing " (bootloader-name ~a)" bootloader-name)
- (sexp-or-nothing " (bootloader-menu-entries ~S)"
- bootloader-menu-entries)))
+ (sexp-or-nothing " (bootloader-name ~a)" bootloader-name)))
(let ((str (generate-boot-parameters)))
(call-with-input-string str read-boot-parameters)))
@@ -170,7 +168,6 @@ (define* (test-read-boot-parameters
(test-assert "read, construction, optional fields"
(and (test-read-boot-parameters #:bootloader-name #false)
- (test-read-boot-parameters #:bootloader-menu-entries #false)
(test-read-boot-parameters #:kernel-arguments #false)
(test-read-boot-parameters #:with-store #false)
(test-read-boot-parameters #:store-device #false)
@@ -223,11 +220,6 @@ (define* (test-read-boot-parameters
(boot-parameters-bootloader-name
(test-read-boot-parameters #:bootloader-name #false)))
-(test-eq "read, bootloader-menu-entries, default value"
- '()
- (boot-parameters-bootloader-menu-entries
- (test-read-boot-parameters #:bootloader-menu-entries #false)))
-
(test-eq "read, kernel-arguments, default value"
'()
(boot-parameters-kernel-arguments
--
2.45.2
next prev parent reply other threads:[~2024-09-26 10:12 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-12 16:58 [bug#73202] [PATCH] guix: scripts: Rewrite reinstall-bootloader to use provenance data Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 00/15] Preparation for bootloader rewrite Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 01/15] gnu: bootloader: Remove deprecated bootloader-configuration field Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 02/15] gnu: system: Remove useless boot parameters Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 03/15] gnu: tests: reconfigure: Remove bootloader install test Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 04/15] guix: scripts: Remove unused code Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 05/15] guix: scripts: Rewrite reinstall-bootloader to use provenance data Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 06/15] guix: utils: Add flatten and flat-map from haunt Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 07/15] guix: records: Add wrap-element procedure Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 08/15] gnu: bootloader: Add bootloader-target record and infastructure Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 09/15] gnu: bootloader: Add bootloader-configurations->gexp Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 10/15] gnu: bootloader: Add device-subvol field to menu-entry record Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 11/15] gnu: build: bootloader: Add efi-bootnums procedure Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 12/15] gnu: bootloader: Install any bootloader to ESP Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 13/15] gnu: bootloader: Match records outside the module Herman Rimm via Guix-patches via
2024-09-20 10:37 ` [bug#73202] [PATCH v2 14/15] gnu: system: boot: Add procedure Herman Rimm via Guix-patches via
2024-09-20 10:38 ` [bug#73202] [PATCH v2 15/15] teams: Add bootloading team Herman Rimm via Guix-patches via
2024-09-21 10:57 ` [bug#73202] [PATCH v2 00/15] Preparation for bootloader rewrite Herman Rimm via Guix-patches via
2024-09-25 20:58 ` Lilah Tascheter via Guix-patches
2024-09-26 10:08 ` [bug#73202] [PATCH v3 01/14] gnu: bootloader: Remove deprecated bootloader-configuration field Herman Rimm via Guix-patches via
2024-09-26 10:08 ` Herman Rimm via Guix-patches via [this message]
2024-09-26 10:09 ` [bug#73202] [PATCH v3 03/14] gnu: tests: reconfigure: Remove bootloader install test Herman Rimm via Guix-patches via
2024-09-26 10:09 ` [bug#73202] [PATCH v3 04/14] guix: scripts: Remove unused code Herman Rimm via Guix-patches via
2024-09-26 10:09 ` [bug#73202] [PATCH v3 05/14] guix: scripts: Rewrite reinstall-bootloader to use provenance data Herman Rimm via Guix-patches via
2024-09-26 10:09 ` [bug#73202] [PATCH v3 06/14] guix: utils: Add flatten and flat-map from haunt Herman Rimm via Guix-patches via
2024-09-26 10:09 ` [bug#73202] [PATCH v3 07/14] guix: records: Add wrap-element procedure Herman Rimm via Guix-patches via
2024-09-26 10:09 ` [bug#73202] [PATCH v3 08/14] gnu: bootloader: Add bootloader-target record and infastructure Herman Rimm via Guix-patches via
2024-09-26 10:09 ` [bug#73202] [PATCH v3 09/14] gnu: bootloader: Add bootloader-configurations->gexp Herman Rimm via Guix-patches via
2024-09-26 10:09 ` [bug#73202] [PATCH v3 10/14] gnu: bootloader: Add device-subvol field to menu-entry record Herman Rimm via Guix-patches via
2024-09-26 10:09 ` [bug#73202] [PATCH v3 11/14] gnu: build: bootloader: Add efi-bootnums procedure Herman Rimm via Guix-patches via
2024-09-26 10:09 ` [bug#73202] [PATCH v3 12/14] gnu: bootloader: Install any bootloader to ESP Herman Rimm via Guix-patches via
2024-09-26 10:09 ` [bug#73202] [PATCH v3 13/14] gnu: bootloader: Match records outside the module Herman Rimm via Guix-patches via
2024-09-26 10:09 ` [bug#73202] [PATCH v3 14/14] teams: Add bootloading team Herman Rimm via Guix-patches via
2024-10-03 20:32 ` [bug#73202] [PATCH] Preparation for bootloader rewrite Herman Rimm via Guix-patches via
2024-10-04 5:07 ` Lilah Tascheter via Guix-patches
2024-10-04 13:55 ` Herman Rimm via Guix-patches via
2024-10-07 16:59 ` Ryan via Guix-patches via
2024-10-07 19:23 ` Herman Rimm via Guix-patches via
2024-10-08 14:37 ` Ryan via Guix-patches via
2024-10-08 17:23 ` Lilah Tascheter via Guix-patches
2024-10-08 18:05 ` Lilah Tascheter via Guix-patches
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=c0d6bcb2d8c56569b96ac9674de337188dd77c0b.1727345067.git.herman@rimm.ee \
--to=guix-patches@gnu.org \
--cc=73202@debbugs.gnu.org \
--cc=herman@rimm.ee \
--cc=lilah@lunabee.space \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.