Re: [PATCH v9 02/11] Unify GUID types

2023-08-31 Thread Ard Biesheuvel
On Wed, 30 Aug 2023 at 21:07, Vladimir 'phcoder' Serbinenko wrote: > > > > Le mer. 30 août 2023, 16:38, Daniel Kiper a écrit : >> >> On Wed, Aug 30, 2023 at 04:23:36PM +0200, Ard Biesheuvel wrote: >> > On Wed, 30 Aug 2023 at 16:18, Daniel Kiper wrote: >> > > >> > > On Fri, Aug 25, 2023 at 05:50:

Re: [PATCH v5 00/16] Support searching by PARTUUID and PARTLABEL

2023-08-31 Thread Vitaly Kuzmichev
Hi Daniel, On Wed, 2023-08-30 at 16:26 +0200, Daniel Kiper wrote: > Adding Daan who sent similar patch a day earlier... > > On Tue, Aug 22, 2023 at 11:39:08PM +0200, Vitaly Kuzmichev wrote: > > Improve 'search' grub-shell command with functionality to search > > for > > a partition by PARTUUID an

Re: [PATCH v5 04/16] include/grub/misc.h: Fix edge case in grub_uuidcasecmp()

2023-08-31 Thread Daniel Kiper
On Tue, Aug 22, 2023 at 11:39:12PM +0200, Vitaly Kuzmichev wrote: > Fix comparison of two identical UUID strings ending with dash '-'. > > In this case grub_uuidcasecmp() passes through the null terminators > and actual result depends on whatever garbage follows them. > > So break immediately when

Re: [PATCH v5 00/16] Support searching by PARTUUID and PARTLABEL

2023-08-31 Thread Daniel Kiper
On Thu, Aug 31, 2023 at 09:53:54AM +, Vitaly Kuzmichev wrote: > Hi Daniel, > > On Wed, 2023-08-30 at 16:26 +0200, Daniel Kiper wrote: > > Adding Daan who sent similar patch a day earlier... > > > > On Tue, Aug 22, 2023 at 11:39:08PM +0200, Vitaly Kuzmichev wrote: > > > Improve 'search' grub-she

Re: [PATCH v5 04/16] include/grub/misc.h: Fix edge case in grub_uuidcasecmp()

2023-08-31 Thread Vitaly Kuzmichev
Hi Daniel, On Thu, 2023-08-31 at 19:09 +0200, Daniel Kiper wrote: > On Tue, Aug 22, 2023 at 11:39:12PM +0200, Vitaly Kuzmichev wrote: > > Fix comparison of two identical UUID strings ending with dash '-'. > > > > In this case grub_uuidcasecmp() passes through the null terminators > > and actual r

Re: [PATCH] templates/linux_xen: Fix XSM entries generation

2023-08-31 Thread Daniel Kiper
On Tue, Aug 15, 2023 at 03:00:53PM +0100, Anthony PERARD via Grub-devel wrote: > It turns out that setting $xen_version in linux_entry_xsm() override > $xen_version in the loop over $xen_list. This means that only one s/xen_list/reverse_sorted_xen_list/? I expect you based your patch on earlier v

Re: [PATCH v5 04/16] include/grub/misc.h: Fix edge case in grub_uuidcasecmp()

2023-08-31 Thread Daniel Kiper
On Thu, Aug 31, 2023 at 05:32:14PM +, Vitaly Kuzmichev wrote: > Hi Daniel, > > On Thu, 2023-08-31 at 19:09 +0200, Daniel Kiper wrote: > > On Tue, Aug 22, 2023 at 11:39:12PM +0200, Vitaly Kuzmichev wrote: > > > Fix comparison of two identical UUID strings ending with dash '-'. > > > > > > In thi

Re: [PATCH] efi: Change grub_efi_boolean_t from char to enum

2023-08-31 Thread Daniel Kiper
On Mon, Aug 14, 2023 at 04:38:40PM -0500, Glenn Washburn wrote: > This allows using GRUB_EFI_TRUE and GRUB_EFI_FALSE with proper type and > value checking. The UEFI 2.10 specification, in section 2.3.1, table 2.3, > says the size of the boolean is 1 byte and may only contain the values 0 or > 1. In

Re: [PATCH] efi: Change grub_efi_boolean_t from char to enum

2023-08-31 Thread Vladimir 'phcoder' Serbinenko
I see little value in using enum here and too much compiler variance about how it's handled. Compiler is pretty much allowed to choose any type for enum. If we go this route at all we should at very least do a compile time assert. Ideally I would keep it as-is. C unlike C++ does nothing to enforce

[PATCH] tests/util/grub-shell: Enable RNG device to better test stack smashing

2023-08-31 Thread Glenn Washburn
In certain firmwares, eg. OVMF, the RNG protocol is not enabled unless there is an RNG device. When not enabled, GRUB fails to initialize the stack guard with random bytes. For testing, this is not a big issue, but there have been bugs found in the initialization. So turn this on for EFI platforms

Re: [PATCH] efi: Change grub_efi_boolean_t from char to enum

2023-08-31 Thread Glenn Washburn
On Thu, 31 Aug 2023 20:05:37 +0200 Daniel Kiper wrote: > On Mon, Aug 14, 2023 at 04:38:40PM -0500, Glenn Washburn wrote: > > This allows using GRUB_EFI_TRUE and GRUB_EFI_FALSE with proper type and > > value checking. The UEFI 2.10 specification, in section 2.3.1, table 2.3, > > says the size of t