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

   > 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
   
   Thanks for the detail - this explains the differences we've been observing 
between Vexriscv and qemu. We are still learning how this works and appreciate 
the information.


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to