Skip to content

Add support for Smepmp

Himanshu Chauhan opensbi 3 versions – New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest10 patches 0 repliesNew
  2. v28 patches 0 repliesSuperseded
  3. v16 patches 0 repliesSuperseded

Changes in v3 from the cover letter

* Split "Add smepmp support" patch into subpatches
- Root domain permission change is different patch
- Ordering change in PMP configuration is a different patch.

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/10include: sbi: Add macro definitions for mseccfg CSRinclude/sbi/riscv_encoding.h+12 -00 replies
2/10lib: sbi: Add functions to manipulate PMP entriesinclude/sbi/riscv_asm.h lib/sbi/riscv_asm.c+48 -00 replies
3/10include: sbi: Add Smepmp specific access flags for PMP entriesinclude/sbi/sbi_domain.h+78 -60 replies
4/10lib: sbi: Add smepmp in hart extensionsinclude/sbi/sbi_hart.h lib/sbi/sbi_hart.c+5 -01 reply
5/10lib: utils: Add detection of Smepmp from ISA string in FDTinclude/sbi_utils/fdt/fdt_helper.h lib/utils/fdt/fdt_helper.c platform/generic/platform.c+123 -01 reply
6/10lib: sbi: Grant SU R/W/X permissions to whole memorylib/sbi/sbi_domain.c+10 -41 reply
7/10lib: sbi: Add support for Smepmpinclude/sbi/sbi_hart.h lib/sbi/sbi_hart.c+128 -191 reply
8/10lib: sbi: Change the order of PMP initializationlib/sbi/sbi_init.c+17 -91 reply
9/10lib: sbi: Add functions to map/unmap shared memoryinclude/sbi/sbi_hart.h lib/sbi/sbi_hart.c+44 -01 reply
10/10lib: sbi: Map/Unmap debug console shared memory bufferslib/sbi/sbi_ecall_dbcn.c+3 -00 replies

Reviews trailers per patch

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

PatchAnup Patel
1/10R-b
2/10R-b
3/10R-b
4/10R-b
5/10R-b
6/10R-b
7/10R-b
8/10R-b
9/10R-b
10/10R-b

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

Read the v3 thread

Cover letter [PATCH v3 00/10] Add support for Smepmp

This patch series adds support for the Smepmp specification. The detection of Smepmp support in platform depends on the ISA string present in the FDT. If "smepmp" is present in ISA string in FDT, Smepmp is enabled.

When Smepmp is enabled, the M-mode software's free access to S/U memory region is revoked. Hence, all the shared memory access between M-mode and S/U-mode must be done only after mapping the shared memory.

changes in v3:
* Split "Add smepmp support" patch into subpatches
- Root domain permission change is different patch
- Ordering change in PMP configuration is a different patch.

changes in v2:
* Split into futher patches
- FDT ISA string parsing is now separate patch
- Map/Unmap functions for shared memory are in different patch
* Addressed other general comments.

Himanshu Chauhan (10):
include: sbi: Add macro definitions for mseccfg CSR
lib: sbi: Add functions to manipulate PMP entries
include: sbi: Add Smepmp specific access flags for PMP entries
lib: sbi: Add smepmp in hart extensions
lib: utils: Add detection of Smepmp from ISA string in FDT
lib: sbi: Grant SU R/W/X permissions to whole memory
lib: sbi: Add support for Smepmp
lib: sbi: Change the order of PMP initialization
lib: sbi: Add functions to map/unmap shared memory
lib: sbi: Map/Unmap debug console shared memory buffers

 include/sbi/riscv_asm.h            |   6 +
 include/sbi/riscv_encoding.h       |  12 ++
 include/sbi/sbi_domain.h           |  84 +++++++++++++-
 include/sbi/sbi_hart.h             |  19 ++++
 include/sbi_utils/fdt/fdt_helper.h |   3 +
 lib/sbi/riscv_asm.c                |  42 +++++++
 lib/sbi/sbi_domain.c               |  14 ++-
 lib/sbi/sbi_ecall_dbcn.c           |   3 +
 lib/sbi/sbi_hart.c                 | 177 +++++++++++++++++++++++++----
 lib/sbi/sbi_init.c                 |  26 +++--
 lib/utils/fdt/fdt_helper.c         | 111 ++++++++++++++++++
 platform/generic/platform.c        |   9 ++
 12 files changed, 468 insertions(+), 38 deletions(-)
Signature · 1 line
2.34.1