From patchwork Tue Oct 10 16:29:26 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gabriel Wicki X-Patchwork-Id: 54719 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 629A427BBE2; Tue, 10 Oct 2023 17:31:12 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id D8D9E27BBE9 for ; Tue, 10 Oct 2023 17:31:09 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qqFd8-0001c5-0j; Tue, 10 Oct 2023 12:30:46 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qqFd4-0001be-2W for guix-patches@gnu.org; Tue, 10 Oct 2023 12:30:42 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qqFd2-0000ab-PL for guix-patches@gnu.org; Tue, 10 Oct 2023 12:30:41 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qqFdO-0007tL-0Q for guix-patches@gnu.org; Tue, 10 Oct 2023 12:31:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#66448] [PATCH] image: Add 'lba partition label. Resent-From: Gabriel Wicki Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 10 Oct 2023 16:31:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 66448 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 66448@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.169695544230299 (code B ref -1); Tue, 10 Oct 2023 16:31:01 +0000 Received: (at submit) by debbugs.gnu.org; 10 Oct 2023 16:30:42 +0000 Received: from localhost ([127.0.0.1]:36811 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qqFd3-0007sd-JL for submit@debbugs.gnu.org; Tue, 10 Oct 2023 12:30:42 -0400 Received: from lists.gnu.org ([2001:470:142::17]:44440) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qqFcz-0007sJ-6A for submit@debbugs.gnu.org; Tue, 10 Oct 2023 12:30:40 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qqFcV-0001Wv-OL for guix-patches@gnu.org; Tue, 10 Oct 2023 12:30:08 -0400 Received: from chimborazo.ee.ethz.ch ([129.132.2.15]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qqFcT-0000II-10 for guix-patches@gnu.org; Tue, 10 Oct 2023 12:30:07 -0400 Received: from localhost (antispam.ee.ethz.ch [129.132.2.16]) by chimborazo.ee.ethz.ch (Postfix) with ESMTP id 453014016E for ; Tue, 10 Oct 2023 18:29:30 +0200 (CEST) X-Virus-Scanned: by amavisd at antispam.ee.ethz.ch Received: from chimborazo.ee.ethz.ch ([129.132.2.15]) by localhost (antispam.ee.ethz.ch [129.132.2.16]) (amavisd-new, port 10026) with ESMTP id 9EFF0I8rWwtt for ; Tue, 10 Oct 2023 18:29:29 +0200 (CEST) Received: from blackbox (212-51-128-25.fiber7.init7.net [212.51.128.25]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: gabriel) by chimborazo.ee.ethz.ch (Postfix) with ESMTPSA for ; Tue, 10 Oct 2023 18:29:29 +0200 (CEST) Date: Tue, 10 Oct 2023 18:29:26 +0200 From: Gabriel Wicki Message-ID: MIME-Version: 1.0 Content-Disposition: inline Received-SPF: pass client-ip=129.132.2.15; envelope-from=gabriel@erlikon.ch; helo=chimborazo.ee.ethz.ch X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches Some (embedded) system create FAT32/LBA partitions first, i thought this is too easy to not include in Guix. Please let me know if I can improve anything! TIA for review and merge From c5080162e8a77f60aaf9a967a896f57c113dde47 Mon Sep 17 00:00:00 2001 Message-ID: From: Gabriel Wicki Date: Tue, 10 Oct 2023 18:02:04 +0200 Subject: [PATCH] image: Add 'lba partition label. * gnu/image.scm (validate-partition-flags): Add lba to the valid flags. * doc/guix.texi ('partition' Reference): Document it. --- doc/guix.texi | 10 ++++++---- gnu/image.scm | 2 +- 2 files changed, 7 insertions(+), 5 deletions(-) base-commit: f4e8baf3806e79d7111d2943859865ae4ee0b59d diff --git a/doc/guix.texi b/doc/guix.texi index ad26a29513..95aae6ac02 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -45590,10 +45590,12 @@ partition Reference @item @code{flags} (default: @code{'()}) The partition flags as a list of symbols. Possible values are -@code{'boot} and @code{'esp}. The @code{'boot} flags should be set if -you want to boot from this partition. Exactly one partition should have -this flag set, usually the root one. The @code{'esp} flag identifies a -UEFI System Partition. +@code{'boot}, @code{'esp} and @code{'lba}. The @code{'boot} flags +should be set if you want to boot from this partition. Exactly one +partition should have this flag set, usually the root one. The +@code{'esp} flag identifies a UEFI System Partition. The @code{'lba} +flag @acronym{LBA, Local Block Addressing} allows for bigger FAT +partitions than 8GiB. @item @code{initializer} (default: @code{#false}) The partition initializer procedure as a gexp. This procedure is called diff --git a/gnu/image.scm b/gnu/image.scm index 523653dd77..493aea94cd 100644 --- a/gnu/image.scm +++ b/gnu/image.scm @@ -100,7 +100,7 @@ (define-with-syntax-properties (validate-partition-offset (value properties)) ;; The supported partition flags. (define-with-syntax-properties (validate-partition-flags (value properties)) - (let ((bad-flags (lset-difference eq? value '(boot esp)))) + (let ((bad-flags (lset-difference eq? value '(boot esp lba)))) (unless (and (list? value) (null? bad-flags)) (raise (make-compound-condition