In general you would have to have two copies of NuttX and run them AMP.
A single OS with multiple CPUs would require SMP. SMP generally
requires that the CPUs appear identical in the two CPU address spaces
(with the exception of interrupts).
There was a long email thread discussing this exact topic a couple of
months back. That email list is difficult to search, however.
https://lists.apache.org/list.html?dev@nuttx.apache.org I couldn't find it.
There are lots of issues that you would have to address. Like cache
coherency and that fact that that one CPU is slower than the other
(destroying deterministic, real time behavior). There were other
issues, but I don't recall.
The best solution if the CPUs are not identical is to use AMP. NuttX
supports OpenAMP. you can see that in nuttx/OpenAMP. There are a few
examples in the tree too.
On 1/21/2024 8:22 PM, yfliu2008 wrote:
Dear experts,
The K230 chip I am using has two RISC-V cores with separate L2 cache, CLINT
PLIC, their frequencies are different, the big core has vector extension which
the little one doesn't have. The big core can be turned on/off by the little
core.
How can we manage these two cores with NuttX? do we have to run an instance of
NuttX on each core?
Is OpenAMP also needed?
I guess some other multi-core chips might also have similar questions, so
please teach if there are any ideas.
Regards,
yf