From: Ahmad Fatoum <a.fatoum@barebox.org>
To: barebox@lists.infradead.org
Subject: [PATCH v2 0/6] resource: record memory type/attrs on all SDRAM
Date: Mon, 26 May 2025 16:19:08 +0200 [thread overview]
Message-ID: <20250526141914.185212-1-a.fatoum@barebox.org> (raw)
When running as EFI loader, barebox is expected to provide a virtual
memory map that describes the memory regions known to barebox as well as
attributes like whether regions are write-back cached (usable as normal
memory) or reserved (e.g., for OP-TEE).
>From a security point of view, it's useful to have this information
always to inform MMU attributes, so let's make it mandatory.
v1 -> v2:
- replace !IS_ERR check with !NULL check for __request_sdram_region
Ahmad Fatoum (6):
memory: export inside_barebox_area
resource: record EFI memory type and attributes
resource: add MEMATTRS_ definitions for common attribute sets
drivers: tee: optee: separate local variables for each resource
resource: supply memory type/attrs on all SDRAM requests
resource: retire IORESOURCE_BUSY in favor of resource::type
arch/arm/cpu/armv7r-mpu.c | 5 ++-
arch/arm/cpu/bootm-fip.c | 3 +-
arch/arm/cpu/cpu.c | 3 +-
arch/arm/cpu/mmu_32.c | 13 ++++--
arch/arm/cpu/mmu_64.c | 7 ++-
arch/arm/cpu/start.c | 3 +-
arch/arm/lib32/bootm.c | 18 +++++---
arch/arm/lib32/bootz.c | 4 +-
arch/mips/lib/cpu-probe.c | 3 +-
arch/powerpc/mach-mpc5xxx/cpu.c | 3 +-
arch/powerpc/mach-mpc85xx/cpu.c | 2 +-
arch/riscv/boot/start.c | 2 +-
arch/riscv/cpu/core.c | 2 +-
commands/iomemport.c | 2 +-
common/bootm.c | 9 ++--
common/elf.c | 3 +-
common/memory.c | 57 +++++++++++++++++-------
common/memtest.c | 4 +-
common/oftree.c | 2 +-
common/pe.c | 4 +-
common/uimage.c | 6 ++-
drivers/tee/optee/of_fixup.c | 33 +++++++-------
fs/pstore/ram_core.c | 6 ++-
include/efi.h | 37 +--------------
include/efi/memtype.h | 79 +++++++++++++++++++++++++++++++++
include/linux/ioport.h | 67 +++++++++++++++++++++++++++-
include/memory.h | 33 +++++++++++---
lib/Kconfig.hardening | 7 +++
lib/libfile.c | 13 +++++-
pbl/handoff-data.c | 3 +-
30 files changed, 320 insertions(+), 113 deletions(-)
create mode 100644 include/efi/memtype.h
--
2.39.5
next reply other threads:[~2025-05-26 14:19 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-26 14:19 Ahmad Fatoum [this message]
2025-05-26 14:19 ` [PATCH v2 1/6] memory: export inside_barebox_area Ahmad Fatoum
2025-05-26 14:19 ` [PATCH v2 2/6] resource: record EFI memory type and attributes Ahmad Fatoum
2025-05-26 14:19 ` [PATCH v2 3/6] resource: add MEMATTRS_ definitions for common attribute sets Ahmad Fatoum
2025-05-26 14:19 ` [PATCH v2 4/6] drivers: tee: optee: separate local variables for each resource Ahmad Fatoum
2025-05-26 14:19 ` [PATCH v2 5/6] resource: supply memory type/attrs on all SDRAM requests Ahmad Fatoum
2025-05-26 14:19 ` [PATCH v2 6/6] resource: retire IORESOURCE_BUSY in favor of resource::type Ahmad Fatoum
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250526141914.185212-1-a.fatoum@barebox.org \
--to=a.fatoum@barebox.org \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox