You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by "masayuki2009 (via GitHub)" <gi...@apache.org> on 2023/03/10 03:54:04 UTC

[GitHub] [nuttx] masayuki2009 commented on pull request #8762: Support for Kernel build with vexriscv-smp.

masayuki2009 commented on PR #8762:
URL: https://github.com/apache/nuttx/pull/8762#issuecomment-1463213402

   >qemu for whatever reason allows/handles the access from S -> M mode, maybe @masayuki2009 can explain how that >actually works. I think there is something in the command line options that allows this.
   
   In qemu-rv implementation with BUILD_KERNEL, we call `up_mtimer_initialize()` before transiting to S-mode.
   In addition, I added `qemu_rv_exception_m.S` to handle `qemu_rv_mtimer_interrupt()` which sends an S-mode software interrupt. In `qemu_rv_ssoft_interupt(), it calls `nxsched_process_timer()` if g_stimer_pending is true.
   
   As you can see in the `qemu_rv_ssoft_interupt()`, it also needs to handle IPI (Inter-Processor Interrupt) for SMP which we assume to use ACLINT instead of CLINT. Because ACLINT can send IPI in S-mode directly.
   
   https://github.com/riscv/riscv-aclint/blob/main/riscv-aclint.adoc 
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org