mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/2] efi: Fixes for EFI_MEMORY_SP memory on RISC-V and ARM64
@ 2024-02-02 16:34 Andrew Bresticker
  2024-02-02 16:34 ` [PATCH 1/2] efi: runtime: Fix potential overflow of soft-reserved region size Andrew Bresticker
  2024-02-02 16:34 ` [PATCH 2/2] efi: Don't add memblocks for unusable memory Andrew Bresticker
  0 siblings, 2 replies; 6+ messages in thread
From: Andrew Bresticker @ 2024-02-02 16:34 UTC (permalink / raw)
  To: Ard Biesheuvel
  Cc: Paul Walmsley, Palmer Dabbelt, Albert Ou, linux-efi,
	linux-kernel, linux-riscv, Andrew Bresticker

Two small fixes to enable the use soft-reserved/special-purpose memory
(EFI_MEMORY_SP) with dax_kmem on RISC-V (and ARM64, I think, though I
don't have a platform to test it on).

Patch 1 fixes a trivial integer narrowing bug. Patch 2 prevents adding
memblocks for unusable memory (including soft-resreved memory) so that it
can later be hotplugged by dax_kmem.

Tested on a RISC-V platform that presents a range of EFI_MEMORY_SP with
Bjorn's MEMORY_HOTPLUG series[0] applied.

[0]: https://lore.kernel.org/lkml/20230512145737.985671-1-bjorn@kernel.org/

Andrew Bresticker (2):
  efi: runtime: Fix potential overflow of soft-reserved region size
  efi: Don't add memblocks for unusable memory

 drivers/firmware/efi/arm-runtime.c   |  2 +-
 drivers/firmware/efi/efi-init.c      | 12 +-----------
 drivers/firmware/efi/riscv-runtime.c |  2 +-
 3 files changed, 3 insertions(+), 13 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2024-02-02 17:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-02-02 16:34 [PATCH 0/2] efi: Fixes for EFI_MEMORY_SP memory on RISC-V and ARM64 Andrew Bresticker
2024-02-02 16:34 ` [PATCH 1/2] efi: runtime: Fix potential overflow of soft-reserved region size Andrew Bresticker
2024-02-02 16:37   ` Ard Biesheuvel
2024-02-02 16:34 ` [PATCH 2/2] efi: Don't add memblocks for unusable memory Andrew Bresticker
2024-02-02 16:45   ` Ard Biesheuvel
2024-02-02 17:41     ` Andrew Bresticker

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®