Re: [Patchv3][ 5/6] cryptodisk: enable the backends to implement key files

2020-05-23 Thread Patrick Steinhardt
On Fri, May 08, 2020 at 01:19:42AM +0200, Denis 'GNUtoo' Carikli wrote: > From: John Lane > > Signed-off-by: John Lane > gnu...@cyberdimension.org: rebase, patch split, small fixes, commit message > Signed-off-by: Denis 'GNUtoo' Carikli > --- > ChangeLog: > In addition to the requested changes

Re: Multiboot 2 Header Alignment: implementation contradicts specification

2020-05-23 Thread Hans Ulrich Niedermann
On Sat, 23 May 2020 21:24:32 +0200 Jacob Paul via Grub-devel wrote: > On 2020-05-23 20:33, Hans Ulrich Niedermann wrote: > > The comment is valid for MB1, but not for MB2. Both regarding the > > alignment and regarding the size. And regarding the size, this > > actually means there is a bug in

[PATCH] mb2 loader: Fix header size, alignment for Multiboot 2

2020-05-23 Thread Hans Ulrich Niedermann
Change the old Multiboot 1 header size both in the explanatory comment and in the for loop condition actually looking for a Multiboot 2 header to the actual Multiboot 2 header size. This also fixes the old Multiboot 1 alignment copied over in the comment to reflect the Multiboot 2 specification.

[PATCH] doc: Reference configure.ac instead of configure.in

2020-05-23 Thread Hans Ulrich Niedermann
Change the textual reference in the INSTALL file to configure.in to refer to configure.ac instead. The grub configure.in has been renamed to configure.ac in 2003. Signed-off-by: Hans Ulrich Niedermann diff --git a/INSTALL b/INSTALL index e490d22d3..7eb0bd1cc 100644 --- a/INSTALL +++ b/INSTALL

[PATCH RFC] mb2 loader: Use the same iteration code for MB2 as for MB1

2020-05-23 Thread Hans Ulrich Niedermann
This avoids the divisions by 4 to compensate for using an array of 32bit values instead of bytes in MB2 find_header(), just like the MB1 find_header() does it. Also uses the same principle for iterating through the MB2 header tags. Why not use the same code for iterating over memory locations in

Re: Multiboot 2 Header Alignment: implementation contradicts specification

2020-05-23 Thread Jacob Paul via Grub-devel
On 2020-05-23 20:33, Hans Ulrich Niedermann wrote: The comment is valid for MB1, but not for MB2. Both regarding the alignment and regarding the size. And regarding the size, this actually means there is a bug in the code here: An MB2 header is at least 16 bytes for the header magic plus at

Re: Multiboot 2 Header Alignment: implementation contradicts specification

2020-05-23 Thread Hans Ulrich Niedermann
On Sat, 23 May 2020 18:50:09 +0200 Jacob Paul via Grub-devel wrote: > The Multiboot2 specification specifies that the Multiboot2 header > should be 8-byte (64-bit) aligned: > >An OS image must contain an additional header called Multiboot2 > >header, besides the headers of the format used by

Multiboot 2 Header Alignment: implementation contradicts specification

2020-05-23 Thread Jacob Paul via Grub-devel
The Multiboot2 specification specifies that the Multiboot2 header should be 8-byte (64-bit) aligned: >An OS image must contain an additional header called Multiboot2 header, >besides the headers of the format used by the OS image. The Multiboot2 >header must be contained completely within the

Re: Bug#912846: grub2: stop depending on ttf-dejavu-core

2020-05-23 Thread Fabian Greffrath
Control: forwarded -1 grub-devel@gnu.org Control: tags -1 upstream Hi grub devs, the attached patch adds /usr/share/fonts/truetype/dejavu to the DejaVu font search path in configure.ac. This is the directory where the fonts-dejavu-core package in Debian installs its fonts. Thanks! - Fabian

Re: [PATCH] multiboot: Add support for program headers at "strange" locations

2020-05-23 Thread John Paul Adrian Glaubitz
On 5/23/20 5:30 PM, Jacob Paul via Grub-devel wrote: > Currently, grub_multiboot_load_elf() will throw an error if the program > header is at a too high offset (since it would be outside the allocated > buffer space of MULTIBOOT_SEARCH bytes). It is understandable why it does > this, since

[PATCH] multiboot: Add support for program headers at "strange" locations

2020-05-23 Thread Jacob Paul via Grub-devel
Currently, grub_multiboot_load_elf() will throw an error if the program header is at a too high offset (since it would be outside the allocated buffer space of MULTIBOOT_SEARCH bytes). It is understandable why it does this, since 99.99% of all cases e_phoff has a value of 0x34 or 0x40. So, to

Re: Multiboot2 on aarch64: Alignment of ELF Headers

2020-05-23 Thread Hans Ulrich Niedermann
On Sat, 23 May 2020 12:21:27 +0100 Chris Plant via Grub-devel wrote: > On Sat, 2020-05-23 at 12:43 +0200, Hans Ulrich Niedermann wrote: > > On Fri, 22 May 2020 17:23:35 +0100 > > Chris Plant via Grub-devel wrote: > > > > > I'm continuing to work on Multiboot2 support on aarch64, and I'm > >

Re: Multiboot2 on aarch64: Alignment of ELF Headers

2020-05-23 Thread Chris Plant via Grub-devel
On Sat, 2020-05-23 at 12:43 +0200, Hans Ulrich Niedermann wrote: > On Fri, 22 May 2020 17:23:35 +0100 > Chris Plant via Grub-devel wrote: > > > I'm continuing to work on Multiboot2 support on aarch64, and I'm > > looking at the alignment of the ELF headers which are passed > > through > > MB2.

MB2 spec: Endianness weirdness in definition of terms

2020-05-23 Thread Hans Ulrich Niedermann
The MB2 spec "definition of terms used through the specification" defines terms like "must", "should", but also "u8", "u16", "u32", and "u64": > "u8" > The type of unsigned 8-bit data. > > "u16" > The type of unsigned 16-bit data. Because the target architecture > is little-endian,

Re: Multiboot2 on aarch64: Alignment of ELF Headers

2020-05-23 Thread Hans Ulrich Niedermann
On Fri, 22 May 2020 17:23:35 +0100 Chris Plant via Grub-devel wrote: > I'm continuing to work on Multiboot2 support on aarch64, and I'm > looking at the alignment of the ELF headers which are passed through > MB2. At the risk of me sounding stupid... Having read the MB2 specs quite thoroughly

Multiboot2 Header Tags: Unclear definition of type

2020-05-23 Thread Hans Ulrich Niedermann
Quoting the Multiboot2 specification: > 3.1.3 General tag structure > --- > > Tags constitutes a buffer of structures following each other padded > when necessary in order for each tag to start at 8-bytes aligned > address. Tags are terminated by a tag of type '0' and

Multiboot 2 Header Tags: How many and in what sequence?

2020-05-23 Thread Hans Ulrich Niedermann
The Multiboot2 specification specifies a number of header tags which an OS image can define and which the bootloader needs to parse. However, the spec does not mention in which order an OS image should contain MB2 header tags: * Ascending numerical order of the 'type' value? (This could only