Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1odqhH-0007Tj-Ob for mharc-grub-devel@gnu.org; Thu, 29 Sep 2022 06:23:15 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34248) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1odqhG-0007SC-8R for grub-devel@gnu.org; Thu, 29 Sep 2022 06:23:14 -0400 Received: from mail-pj1-x102e.google.com ([2607:f8b0:4864:20::102e]:42972) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1odqhE-0001cN-JK for grub-devel@gnu.org; Thu, 29 Sep 2022 06:23:13 -0400 Received: by mail-pj1-x102e.google.com with SMTP id r8-20020a17090a560800b00205eaaba073so912408pjf.1 for ; Thu, 29 Sep 2022 03:23:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:to:from:date:from:to:cc:subject:date; bh=BOFcvw9Se9tuP0NRUO5BwR5FBI1ehyM+JofzHLtcs30=; b=Aql2qb12LoFYimn+1JvBL7h0stlTRZS/RtYabVGE8QGRMk7na/wuenH6z19Q9UCzIH DXU5VfmPoL6cG0WbbqhkCg5OjOWIbEAhAtx2QqscqTxkPbCMIeviR8X8t/a288oYlZN0 o81u0as4zHeH7TCwVFZsqD9oFizZ7LV7yRpdIr2H1aPnBIyTZux0suY/SdS5eT5ocAxu l2wJdi5t41PsYiyeSM/oL3C2QGeLfXaKOdbSJPaRkBD0B8ibdDI6/QJDX2Z1s2++sbhh RFI7e+hzM2E/6+H9vncBpFSzWNAgrQWoBTcIQ/mzMAINSqPOWvZQ9vMdWegkGioc8bS/ FDOg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:to:from:date:x-gm-message-state:from:to:cc:subject:date; bh=BOFcvw9Se9tuP0NRUO5BwR5FBI1ehyM+JofzHLtcs30=; b=5kIAF+h0ovaSNJYmRqcnnsWcJrZZgiqYiWD0+aP6fjWmPSDbZPv59qoDHRcczhLONJ BwEPuT/2rkyL/e0edJKoio9fYDFbXqHXYirfeJfU0lXU1CZywVfZlWmAtQ7roGwQj+bk xJa8yEYZG5fVDFykA6aJzsE4wvMlhbT5a0IweVUy93DVvMKQ4Fx2YQfMwe+4kG/qhgok 52FcQnQcOZ4b1OYf9rq0lEzlQkeJjgZjqel4+xgprFgiWBymefitv2lAS4+20dxAl5dQ Tvy1fmpc1FTHMCh1SXRgATSno2J7LBqFv6CNeGo7a8JR55fmWJsalYkHRGE7/M6XFsY0 s3Sg== X-Gm-Message-State: ACrzQf2CcmCIHLf7WtwM8G/dQpX6TK4qRW6ygGjbqlq2Z/06TeEbSnMl fJn/57HEeZHha/mdJcGaCx1sKkSRf1Q= X-Google-Smtp-Source: AMsMyM5AGsjE9GttDqaQzZBYMMKlYQc0wnWiA0f+efZeRibGcW12Vj+MeykTN8SEHIgVbSCHVc7o4Q== X-Received: by 2002:a17:902:e807:b0:179:fc64:7288 with SMTP id u7-20020a170902e80700b00179fc647288mr2688919plg.137.1664446989578; Thu, 29 Sep 2022 03:23:09 -0700 (PDT) Received: from generichostname (136-25-1-99.cab.webpass.net. [136.25.1.99]) by smtp.gmail.com with ESMTPSA id z14-20020a170903018e00b00177c488fea5sm5540258plg.12.2022.09.29.03.23.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 29 Sep 2022 03:23:09 -0700 (PDT) Date: Thu, 29 Sep 2022 03:23:07 -0700 From: Denton Liu To: The development of GNU GRUB , Daniel Kiper Subject: Re: [RESEND RESEND RESEND PATCH] templates: introduce GRUB_TOP_LEVEL_* vars Message-ID: References: <20220921112225.145616-1-liu.denton@gmail.com> <20220927123045.100271-1-liu.denton@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Received-SPF: pass client-ip=2607:f8b0:4864:20::102e; envelope-from=liu.denton@gmail.com; helo=mail-pj1-x102e.google.com 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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 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: Thu, 29 Sep 2022 10:23:14 -0000 Thanks for the response, Oskari! On Thu, Sep 29, 2022 at 01:08:03AM -0500, Oskari Pirhonen wrote: > On Tue, Sep 27, 2022 at 05:30:45 -0700, Denton Liu wrote: > > A user may wish to use an image that is not sorted as the "latest" > > version as the top-level entry. For example, in Arch Linux, if a user > > has the LTS and regular kernels installed, `/boot/vmlinuz-linux-lts` > > gets sorted as the "latest" compared to `/boot/vmlinuz-linux`. However, > > a user may wish to use the regular kernel as the default with the LTS > > only existing as a backup. > > > > Introduce the GRUB_TOP_LEVEL_LINUX and GRUB_TOP_LEVEL_XEN variables to > > allow users to specify the top-level entry. > > > > A couple questions: > > - If all you're looking for is /boot/vmlinuz-linux to be booted, is > setting GRUB_DEFAULT in /etc/default/grub "good enough" for your use > case? I think it is "good enough" for what I need but it feels a little bit weird that grub doesn't give the user any choice as to what the top-level kernel is. > - Is it possible to make this solution more universal? Maybe BSD users > would like to set their top level entry. I'm not too familiar with what end-users might want. If we want to make this more universal, we could either do GRUB_TOP_LEVEL_KERNEL and have that shared amongst all of the 10_* files or we could have multiple variables, e.g. GRUB_TOP_LEVEL_LINUX, GRUB_TOP_LEVEL_BSD, etc. > - What about for os-prober? My understanding is that it creates its own > top level entries as well. The same thing could work with os-prober, although it wouldn't be a cut-and-paste. I'm open to all ideas here and I can cook up the patches. The thing is that I'm not sure what the project's conventions are regarding too-granular/not-granular-enough configurations so some advice here would be very much appreciated! -Denton