RTEMS | RISC-V: add support for using the MMU in S-Mode (!1182)
Kinsey Moore (@opticron)
gitlab at rtems.org
Sat Apr 4 02:54:26 UTC 2026
Kinsey Moore started a new discussion on bsps/riscv/shared/mmu/mmu-setup.c: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1182#note_148026
> +
> + return ppn2 | ppn1 | ppn0 | flags;
> +}
> +
> +BSP_START_TEXT_SECTION static inline uint32_t riscv_mmu_get_index(
> + uintptr_t address,
> + int level
> +)
> +{
> + uint32_t shift_bits;
> + uint32_t mask;
> +
> + switch (level) {
> + case 2:
> +#if __riscv_xlen == 32
> + shift_bits = 20;
Are you sure this number is correct? Documentation suggests it should be 22, but I could be misreading.
--
View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1182#note_148026
You're receiving this email because of your account on gitlab.rtems.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20260404/b85397ca/attachment-0001.htm>
More information about the bugs
mailing list