[PATCH v2 0/8] XN Support for reserved-memory areas

Rouven Czerwinski r.czerwinski at pengutronix.de
Tue Aug 3 02:44:10 PDT 2021


This is v2 of a series to properly handle reserved memory areas with the
no-map property. This allows us to early load OP-TEE, while also
prohibiting the CPU from speculating into the OP-TEE area by mapping the
OP-TEE area as uncached and eXecute Never. We also parse the device tree
reserved memory areas from the DT passed into barebox proper, to also
remove no-map entries from the MMU there.

Rouven Czerwinski (8):
  of: reserve: add xn flag mem entries
  of: add of_get_reserve_map stub for !CONFIG_OFTREE
  ARM: mmu: use reserve mem entries to modify maps
  of: add flag to not create resmem DT entries
  of: add reserved_mem_read initcall
  pbl: fdt: add support to parse reserved mem
  ARM: mmu-early: map no-map entries XN & uncached
  PBL: enable LIBFDT for OP-TEE early loading

 arch/arm/cpu/mmu-early.c       |  13 +++++
 arch/arm/cpu/mmu.c             |  34 ++++++++++-
 arch/arm/cpu/sm.c              |   2 +-
 arch/arm/cpu/start.c           |   2 +-
 arch/arm/mach-layerscape/ppa.c |   2 +-
 common/Kconfig                 |   1 +
 common/bootm.c                 |   3 +-
 drivers/of/Makefile            |   1 +
 drivers/of/fdt.c               |  16 +++--
 drivers/of/reserved-mem.c      |  43 ++++++++++++++
 drivers/video/fb.c             |   3 +-
 drivers/video/simplefb-fixup.c |   2 +-
 fs/pstore/ram.c                |   3 +-
 include/of.h                   |  14 ++++-
 include/pbl.h                  |  25 ++++++++
 pbl/fdt.c                      | 103 ++++++++++++++++++++++++++++-----
 16 files changed, 237 insertions(+), 30 deletions(-)
 create mode 100644 drivers/of/reserved-mem.c

-- 
2.32.0




More information about the barebox mailing list