From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1nFH7g-0003XY-QS for mharc-grub-devel@gnu.org; Wed, 02 Feb 2022 10:00:40 -0500 Received: from eggs.gnu.org ([209.51.188.92]:40384) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nFH7X-0003St-9v for grub-devel@gnu.org; Wed, 02 Feb 2022 10:00:35 -0500 Received: from mail-40136.proton.ch ([185.70.40.136]:20786) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nFH7M-0003nQ-DT for grub-devel@gnu.org; Wed, 02 Feb 2022 10:00:25 -0500 Date: Wed, 02 Feb 2022 15:00:10 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fomin.one; s=protonmail2; t=1643814012; bh=smODsToDpiwLGlQwIL/s3cefDDNEccpLxBixdnJBX9g=; h=Date:To:From:Reply-To:Subject:Message-ID:In-Reply-To:References: From:To:Cc; b=JROG3Gz1Do/oV4AdP1lvxjW0XwGxKgl57k7DBhZroZYq7tQZaPnKDYLcnQA69MeHA 7lkGm4skqyN+dkHQoFfGXyKVo2OgQnju9VymZ1D2A5AOyDcV+uL1VV3+eRApdlqd+Q TtVAkPLWyiDYJyHby9mShlyQ5hFg/vl3vSZyrUSGKs1lbTkDoT4eA9RXgipjYPnl/j GzD0BFKo2q0fUCnyYORzwVRE9wksO8Q0gRJSEx4MQlBLg4YJXKkJxuDNyIAOpoHdag 2AIUcNsSehJnQjpT+oPqBet3+URpff3F5SF2Wcndn5y7LChIy5JmKkTiHTdYG6WG+G yLENdzmHMAUtA== To: "grub-devel@gnu.org" From: Maxim Fomin Reply-To: Maxim Fomin Subject: Re: [PATCH 0/2] Support plain encryption mode. Message-ID: <-eJYlKGmo1nQYwTI-XEex96pH74k1pxOCOKbu_YI-kTR0NsUxcrgq1r4Ex13cN0s2HbMHo67e5kH4t6rNsBY2L5-K6qq3OCDDxCDDNFlbns=@fomin.one> In-Reply-To: <20220201185106.4be9b679@crass-HP-ZBook-15-G2> References: <-gYg2fhNOHhD_BSgH0s5jno5SmqrQC7rpo6mu3cT1I0XzEv5SUsXeyONbFy4g_LouLwZSzn2s0dFhHvvVw9_HNpJPIRp1d3eZCBGXCJPD4g=@fomin.one> <20220131144018.7592f807@crass-HP-ZBook-15-G2> <20220201185106.4be9b679@crass-HP-ZBook-15-G2> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=185.70.40.136; envelope-from=maxim@fomin.one; helo=mail-40136.proton.ch X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Feb 2022 15:00:36 -0000 ------- Original Message ------- > > > > Plainmount can work with '(hdX,gptY)' syntax in config or shell (actual= ly, this > > > > is the base syntax) and thus it is not limited to GPT paritions, what i= s limited > > > > is the ability to use UUID - currently only on GPT. If partition scheme= does not > > > > have UUID then UUID as a convenience feature cannot be supported - inco= nvenient, > > > > but technically fair. I will take a look at MBR UUID and see whether th= ey can be > > > > supported. Possible situations (under current implementaion) are follow= s: > > > > a) GPT disk, multi-disk environment, disks map unpredictably: can name = partitions > > > > by GPT UUID in config file/shell, no problem, ability to name by UUID h= as value > > I agree that searching by partition UUID is useful and desirable. > > However, I don't think this is the right approach. GRUB should have > > generic searching by partition UUID. There is already a patch for > > this[1]. Perhaps you can test/review this patch to help it gain more > > visibility and advocate for it being accepted. > > Glenn > > [1] https://lists.gnu.org/archive/html/grub-devel/2021-04/msg00055.html > Such function (or several functions) should be added into grub 'library', s= o it can be used to search disk by PART UUID in different places. The patch you refer t= o seems to add this functionality only to 'search' grub command via 'void grub_search_= partuuid' function. Can it be reused on other places? It seems in oder to use it, gru= b code must call 'search' command and receive the result from grub environment variable= which is not convinient for other grub code interested in this feature. I think the = proper way to do it is to write some library function which can be used by search, pro= be (btw I borrowed some details from it - so there is code duplication in search/prob= e), plainmount commands and other commands in grub. Best regards, Maxim Fomin