Re: [PATCH] Generalize MD_MAX_DISKS to GRUB_MDRAID_MAX_DISKS

2023-06-13 Thread Kees Cook
On Tue, Jun 13, 2023 at 02:54:48PM +0200, Julian Andres Klode wrote: > Move the constant from getroot.c to disk.h and then reuse > it place of the hardcoded 1024 limit in diskfilter. > > Fixes: 2a5e3c1f2 (disk/diskfilter: Don't make a RAID array with more than > 1024 disks) > Cc: Daniel Axtens >

Re: [PATCH v2 0/5] loongarch: add relaxation support

2023-06-13 Thread Didier Spaier
Le 12/06/2023 à 15:29, Daniel Kiper a écrit : > I am going to do code freeze this week... Will the Argon2i and Argon2id key derival functions be supported in the new release? I have not be able to find a commit about that, maybe I missed it? ___ Grub-d

[PATCH] Generalize MD_MAX_DISKS to GRUB_MDRAID_MAX_DISKS

2023-06-13 Thread Julian Andres Klode
Move the constant from getroot.c to disk.h and then reuse it place of the hardcoded 1024 limit in diskfilter. Fixes: 2a5e3c1f2 (disk/diskfilter: Don't make a RAID array with more than 1024 disks) Cc: Daniel Axtens Cc: Kees Cook --- grub-core/disk/diskfilter.c | 4 ++-- grub-core/osdep/lin

Re: [PATCH v3 5/5] loongarch: Use the -mno-relax cflags for gcc

2023-06-13 Thread Xi Ruoyao via Grub-devel
On Tue, 2023-06-13 at 13:39 +0200, Daniel Kiper wrote: > On Tue, Jun 13, 2023 at 05:06:35PM +0800, Xiaotian Wu wrote: > > Because the binutils of the loongarch architecture adds relaxation > > support [1], > > the next version of binutils will not be able to build grub. > > > > So we use the -mno-

Re: [PATCH v2] commands/acpi: use xsdt_addr if present

2023-06-13 Thread Daniel Kiper
On Tue, Jun 13, 2023 at 11:17:36AM +0800, Qiumiao Zhang via Grub-devel wrote: > According to the ACPI specification, in ACPI 2.0 or later, an ACPI-compatible > OS must use the XSDT if present. > So, we should use xsdt_addr instead of rsdt_addr if xsdt_addr is valid. > > Signed-off-by: Qiumiao Zhan

Re: [PATCH v3 5/5] loongarch: Use the -mno-relax cflags for gcc

2023-06-13 Thread Daniel Kiper
On Tue, Jun 13, 2023 at 05:06:35PM +0800, Xiaotian Wu wrote: > Because the binutils of the loongarch architecture adds relaxation support > [1], > the next version of binutils will not be able to build grub. > > So we use the -mno-relax cflags to disable gcc to generate relaxation > relocations to

Re: [PATCH] kern/acpi: use xsdt_addr if present

2023-06-13 Thread Daniel Kiper
On Tue, Jun 13, 2023 at 11:20:51AM +0800, Qiumiao Zhang via Grub-devel wrote: > According to the ACPI specification, in ACPI 2.0 or later, an ACPI-compatible > OS must use the XSDT if present. > So, we should use xsdt_addr instead of rsdt_addr if xsdt_addr is valid. > > Signed-off-by: Qiumiao Zhan

Re: [PATCH v3 5/5] loongarch: Use the -mno-relax cflags for gcc

2023-06-13 Thread WANG Xuerui
On 2023/6/13 17:06, Xiaotian Wu wrote: Because the binutils of the loongarch architecture adds relaxation support [1], the next version of binutils will not be able to build grub. We can simplify the sentence a bit, like "A working grub cannot be built with upcoming binutils and gcc, because

[PATCH v3 1/5] Use the correct format specifier for formatted output

2023-06-13 Thread Xiaotian Wu
Use "PRIxGRUB_INT64_T" format specifier for "grub_int64_t" type, and drop the casts code. Signed-off-by: Xiaotian Wu Reviewed-by: Daniel Kiper --- grub-core/kern/arm64/dl_helper.c | 4 ++-- grub-core/kern/loongarch64/dl_helper.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-)

[PATCH v3 4/5] loongarch: Add ELF relocation types documentation and comments

2023-06-13 Thread Xiaotian Wu
see https://github.com/loongson/la-abi-specs/blob/release/laelf.adoc#relocations Signed-off-by: Xiaotian Wu Reviewed-by: Daniel Kiper --- grub-core/kern/loongarch64/dl_helper.c | 25 + 1 file changed, 25 insertions(+) diff --git a/grub-core/kern/loongarch64/dl_helper.c

[PATCH v3 2/5] loongarch: Optimize code using pc variable

2023-06-13 Thread Xiaotian Wu
We already have the pc variable, no need to calculate it again. Signed-off-by: Xiaotian Wu Reviewed-by: Daniel Kiper --- util/grub-mkimagexx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/grub-mkimagexx.c b/util/grub-mkimagexx.c index e7d5bc631..a3ab04eb1 100644 ---

[PATCH v3 0/5] loongarch: Disable relaxation for grub

2023-06-13 Thread Xiaotian Wu
Because the binutils of the loongarch architecture adds relaxation support [1], the next version of binutils will not be able to build grub. So we use the -mno-relax cflags to disable gcc to generate relaxation relocations to enhance the compatibility of grub. [1]: https://sourceware.org/git/?p=

[PATCH v3 3/5] loongarch: Rename function names

2023-06-13 Thread Xiaotian Wu
According to the relocation documentation, the following function names are renamed to show their exact meaning: - from grub_loongarch64_xxx64_hi12() to grub_loongarch64_abs64_hi12() - from grub_loongarch64_xxx64_hi12() to grub_loongarch64_abs64_lo20() Signed-off-by: Xiaotian Wu Reviewed-by: Dan

[PATCH v3 5/5] loongarch: Use the -mno-relax cflags for gcc

2023-06-13 Thread Xiaotian Wu
Because the binutils of the loongarch architecture adds relaxation support [1], the next version of binutils will not be able to build grub. So we use the -mno-relax cflags to disable gcc to generate relaxation relocations to enhance the compatibility of grub. [1]: https://sourceware.org/git/?p=

Re: [PATCH v2 0/5] loongarch: add relaxation support

2023-06-13 Thread mengqinggang
Just like Xi Ruoyao said, just pass -mno-relax option to gcc. 在 2023/6/13 下午3:22, Xiaotian Wu 写道: Maybe you can tell me how to add compiler options, thank you. 在 2023-06-13星期二的 14:54 +0800,Xiaotian Wu写道: 在 2023-06-13星期二的 14:33 +0800,mengqinggang写道: LDFLAGS do not affect relocations generatio

Re: [PATCH v2 0/5] loongarch: add relaxation support

2023-06-13 Thread Xiaotian Wu
Maybe you can tell me how to add compiler options, thank you. 在 2023-06-13星期二的 14:54 +0800,Xiaotian Wu写道: > 在 2023-06-13星期二的 14:33 +0800,mengqinggang写道: > > LDFLAGS do not affect relocations generation. If just modify > > LDFLAGS, > > grub still needs to process relaxation relocations. > >   > >