Skip to content

RISC-V: Fix a few kexec_file_load(2) failures

Petr Tesarik kexec linux-riscv lkml 2 versions – Applied

Status from this message: Applied, thanks!

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 9 repliesApplied 2/3
  2. v13 patches 3 repliesSuperseded

Changes in v2 from the cover letter

- Replace memcmp() with a for loop.
- Drop handling of 16-bit add/subtract relocations. They were used only by alternatives in strcmp(), which was referenced only by string.o.
- Add the initrd placement fix.

Patches in v2 Applied · 2/3

#Subject and filesSizeRepliesApplied
1/3riscv/kexec: handle R_RISCV_CALL_PLT relocation typearch/riscv/kernel/elf_kexec.c+1 -01 replyApplied
2/3riscv/purgatory: do not link with string.o and its dependenciesarch/riscv/purgatory/Makefile arch/riscv/purgatory/purgatory.c+5 -274 replies
3/3riscv/kexec: load initrd high in available memoryarch/riscv/kernel/elf_kexec.c+1 -12 repliesApplied

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchConor Dooley
1/3R-b
2/3A-b
3/3R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/3] RISC-V: Fix a few kexec_file_load(2) failures

From: Petr Tesarik <[email protected]>

The kexec_file_load(2) syscall does not work at least in some kernel builds. For details see the relevant section in this blog post:

https://sigillatum.tesarici.cz/2023-07-21-state-of-riscv64-kdump.html

This patch series handles an additional relocation types, removes the need to implement a Global Offset Table (GOT) for the purgatory and fixes the placement of initrd.

Changelog
=========

Changes from v1:
- Replace memcmp() with a for loop.
- Drop handling of 16-bit add/subtract relocations. They were used only by alternatives in strcmp(), which was referenced only by string.o.
- Add the initrd placement fix.

Petr Tesarik (1):
riscv/purgatory: do not link with string.o and its dependencies

Torsten Duwe (2):
riscv/kexec: handle R_RISCV_CALL_PLT relocation type riscv/kexec: load initrd high in available memory

 arch/riscv/kernel/elf_kexec.c    |  3 ++-
 arch/riscv/purgatory/Makefile    | 26 +-------------------------
 arch/riscv/purgatory/purgatory.c |  6 ++++--
 3 files changed, 7 insertions(+), 28 deletions(-)
Signature · 7 lines
2.25.1


_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec