Re: [PATCH v7 10/10] tests: add support for LoongArch

2022-08-08 Thread Xiaotian Wu
在 2022/8/5 下午12:58, Glenn Washburn 写道: On Thu, 4 Aug 2022 21:01:44 +0800 Xiaotian Wu wrote: Signed-off-by: Xiaotian Wu --- tests/ahci_test.in | 2 +- tests/ehci_test.in | 2 +- tests/ohci_test.in | 2 +- tests/pata_test.in | 2 +- tests/uhci_test.in |

Re: [PATCH v2 1/1] Add support for grub-emu to kexec Linux menu entries

2022-08-08 Thread Robbie Harwood
Daniel Kiper writes: > On Tue, Jul 19, 2022 at 04:39:34PM -0400, Robbie Harwood wrote: > >> +static grub_err_t >> +grub_linux_boot (void) >> +{ >> + grub_err_t rc = GRUB_ERR_NONE; >> + char *initrd_param; >> + const char *kexec[] = { "kexec", "-l", kernel_path, boot_cmdline, NULL, >> NULL };

Re: [PATCH v2 1/1] Add support for grub-emu to kexec Linux menu entries

2022-08-08 Thread Vladimir 'phcoder' Serbinenko
I like it in general however I had a comment: in future GRUB could be able to do the same through second approach: load a constructed kexec blob with all the parts. This would allow to e.g. kexec FreeBSD. This didn't have to be implemented now. Meanwhile can we use "kexec" as command name? It's fin

[PATCH 1/2] templates/linux_xen: Properly load multiple initrd files

2022-08-08 Thread Mauricio Faria de Oliveira
The linux_xen template can put multiple initrd files in the same multiboot[2] module[2] command, which is against specs. This causes ONLY the _first_ initrd file to be loaded; other files just have filenames in a "cmdline" string of the first initrd file and are NOT loaded. Fix this by inserting

[PATCH 0/2] templates/linux_xen: Properly handle multiple initrd files

2022-08-08 Thread Mauricio Faria de Oliveira
The linux_xen template seems to be broken for multiple initrd files. Linux fails to boot when it needs a real initrd but early/microcode initrd(s) are found by grub-mkconfig. Patch 1 allows initrd(s) other than the first early/microcode initrd to be loaded at all, fixing an implementation error fo

[PATCH 2/2] templates/linux_xen: Properly order the multiple initrd files

2022-08-08 Thread Mauricio Faria de Oliveira
The linux_xen template orders the "early" initrd file(s) _first_ (i.e., before the "real" initrd files) and that seems reasonable, as microcode updates usually come first. However, this usually breaks Linux boot with initrd under Xen because Xen assumes the real initrd is the first multiboot[2] mo

Re: [PATCH v7 10/10] tests: add support for LoongArch

2022-08-08 Thread Glenn Washburn
On Mon, 8 Aug 2022 16:08:55 +0800 Xiaotian Wu wrote: > > 在 2022/8/5 下午12:58, Glenn Washburn 写道: > > On Thu, 4 Aug 2022 21:01:44 +0800 > > Xiaotian Wu wrote: > > > >> Signed-off-by: Xiaotian Wu > >> --- > >> tests/ahci_test.in | 2 +- > >> tests/ehci_test.in | 2 +- > >> test

[PATCH v8 02/10] Add LoongArch definitions

2022-08-08 Thread Xiaotian Wu
Signed-off-by: Xiaotian Wu Signed-off-by: Zhou Yang --- include/grub/elf.h | 23 +++ 1 file changed, 23 insertions(+) diff --git a/include/grub/elf.h b/include/grub/elf.h index c478933ee..1c8d4f5d5 100644 --- a/include/grub/elf.h +++ b/include/grub/elf.h @@ -248,6 +248,7 @@

[PATCH v8 01/10] PE: Add LoongArch definitions

2022-08-08 Thread Xiaotian Wu
Signed-off-by: Xiaotian Wu Signed-off-by: Zhou Yang --- include/grub/efi/pe32.h | 36 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/include/grub/efi/pe32.h b/include/grub/efi/pe32.h index 0ed8781f0..de56edef6 100644 --- a/include/grub/efi/pe

[PATCH v8 00/10] Add support for LoongArch

2022-08-08 Thread Xiaotian Wu
LoongArch is a new Loongson 3A5000 CPU instruction set, you can read documents[1] or visit the development community[2] to get more information. [1]: https://loongson.github.io/LoongArch-Documentation/README-EN.html [2]: https://github.com/loongson This patch series will add the basic support for

[PATCH v8 03/10] LoongArch: Add setjmp implementation

2022-08-08 Thread Xiaotian Wu
Signed-off-by: Xiaotian Wu Signed-off-by: Zhou Yang Signed-off-by: Sun Haiyong --- grub-core/lib/loongarch64/setjmp.S | 69 ++ grub-core/lib/setjmp.S | 2 + include/grub/loongarch64/setjmp.h | 27 3 files changed, 98 insertions(+) create m

[PATCH v8 08/10] LoongArch: Add to build system

2022-08-08 Thread Xiaotian Wu
Signed-off-by: Xiaotian Wu Signed-off-by: Zhou Yang --- Makefile.util.def | 1 + configure.ac| 22 - gentpl.py | 25 ++- grub-core/Makefile.am | 6 + grub-core/Makefile.core.def | 16 include/gru

[PATCH v8 04/10] LoongArch: Add early startup code

2022-08-08 Thread Xiaotian Wu
Signed-off-by: Xiaotian Wu Signed-off-by: Zhou Yang --- grub-core/kern/loongarch64/efi/startup.S | 34 1 file changed, 34 insertions(+) create mode 100644 grub-core/kern/loongarch64/efi/startup.S diff --git a/grub-core/kern/loongarch64/efi/startup.S b/grub-core/kern/l

[PATCH v8 07/10] LoongArch: Add auxiliary files

2022-08-08 Thread Xiaotian Wu
Signed-off-by: Xiaotian Wu Signed-off-by: Zhou Yang --- grub-core/kern/efi/mm.c | 3 +- grub-core/kern/loongarch64/cache.c | 39 grub-core/kern/loongarch64/cache_flush.S | 33 ++ grub-core/kern/loongarch64/efi/init.c| 77

[PATCH v8 05/10] LoongArch: Add stubs for Linux loading commands

2022-08-08 Thread Xiaotian Wu
Signed-off-by: Xiaotian Wu --- grub-core/loader/loongarch64/linux.c | 59 include/grub/loongarch64/linux.h | 31 +++ 2 files changed, 90 insertions(+) create mode 100644 grub-core/loader/loongarch64/linux.c create mode 100644 include/grub/loongarch64

[PATCH v8 09/10] LoongArch: Support new relocation types

2022-08-08 Thread Xiaotian Wu
Signed-off-by: Xiaotian Wu --- conf/Makefile.common | 3 + configure.ac | 14 +++-- grub-core/kern/dl.c| 9 +-- grub-core/kern/loongarch64/dl.c| 71 - grub-core/kern/loongarch64/dl_helper.c | 68

[PATCH v8 06/10] LoongArch: Add awareness for LoongArch relocations

2022-08-08 Thread Xiaotian Wu
Signed-off-by: Xiaotian Wu Signed-off-by: Zhou Yang --- grub-core/kern/dl.c| 9 +- grub-core/kern/loongarch64/dl.c| 102 + grub-core/kern/loongarch64/dl_helper.c | 202 + include/grub/dl.h | 1 + include/gru

[PATCH v8 10/10] tests: add support for LoongArch

2022-08-08 Thread Xiaotian Wu
Signed-off-by: Xiaotian Wu --- tests/ahci_test.in | 2 +- tests/ehci_test.in | 2 +- tests/ohci_test.in | 2 +- tests/pata_test.in | 2 +- tests/uhci_test.in | 2 +- tests/util/grub-shell.in | 14 ++ 6 files changed, 19 insertions(+), 5 deletions(-)