The feature depends on ARCH_USE_SEPARATED_SECTION
the different memory area has different access speed and cache
capability, so the arch can custom allocate them based on
section names to achieve performance optimization
test:
sim:elf
sim:sotest
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
reason:
Currently, if we need to schedule a task to another CPU, we have to completely halt the other CPU,
manipulate the scheduling linked list, and then resume the operation of that CPU. This process is both time-consuming and unnecessary.
During this process, both the current CPU and the target CPU are inevitably subjected to busyloop.
The improved strategy is to simply send a cross-core interrupt to the target CPU.
The current CPU continues to run while the target CPU responds to the interrupt, eliminating the certainty of a busyloop occurring.
Signed-off-by: hujun5 <hujun5@xiaomi.com>
To align with the implementation of ARMv7-A, remove the operation of clearing
interrupts during GIC initialization to avoid losing interrupts during asynchronous startup.
Signed-off-by: hujun5 <hujun5@xiaomi.com>
Add the new symbol `NativeSymbol` to the white list,
and update the comments about the symbols that are
from WAMR project.
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
compile error:
Register: ostest
Register: nsh
Register: sh
Register: hello
Register: getprime
In file included from /home/hujun5/downloads1/vela_sim/nuttx/include/arch/irq.h:35,
from /home/hujun5/downloads1/vela_sim/nuttx/include/nuttx/irq.h:37,
from /home/hujun5/downloads1/vela_sim/nuttx/include/nuttx/sched.h:40,
from /home/hujun5/downloads1/vela_sim/nuttx/include/nuttx/arch.h:87,
from common/arm_signal_dispatch.c:26:
common/arm_signal_dispatch.c: In function 'up_signal_dispatch':
common/arm_signal_dispatch.c:72:3: error: 'asm' operand has impossible constraints
72 | sys_call4(SYS_signal_handler, (uintptr_t)sighand, (uintptr_t)signo,
| ^~~~~~~~~
make[1]: *** [Makefile:168:arm_signal_dispatch.o] error 1
Signed-off-by: hujun5 <hujun5@xiaomi.com>
reason:
when a context switch occurs, up_switch_context is executed.
In order to reduce the time taken for context switching,
we inline the up_switch_context function.
Signed-off-by: hujun5 <hujun5@xiaomi.com>
fix previous problemc
added defconfig for weact-stm32h743:nshusb
board.h
Wrong column position or missing blank line before comment: FIX
hopefully last commit
/vela/nuttx/drivers/pci/pci_ecam.c:432:(.text.pci_ecam_get_irq+0x16): undefined reference to `up_get_legacy_irq'
Signed-off-by: Yongrong Wang <wangyongrong@xiaomi.com>
When monitoring multiple capture channels, the `ioctl` function
is called three times, leading to significant overhead mainly due
to VFS and `nxmutex_lock/unlock`. Adding a new interface can save
the overhead of two `ioctl` calls.
Signed-off-by: yangguangcai <yangguangcai@xiaomi.com>
reason:
Only one timer will be effective at a time.In the current
implementation of NuttX's timer handling, only a single global timer is necessary.
Having an excessive number of timers can lead to additional performance
overhead and logical errors, especially when operating in SMP
(Symmetric Multi-Processing) tickless mode.
Signed-off-by: hujun5 <hujun5@xiaomi.com>
When the system cannot obtain buffers for a long time, hpwork will hold
a lot of buffers. However, due to a deadlock between the rptun thread
and hpwork, hpwork cannot send the buffers in time, causing the system
to crash.
so, avoid hold sre lock in rptun thread.
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
if remote not set CONFIG_SENSOR_RPMSG, local can't receive NS_ACK
so sensor_rpmsg_device_ns_bound won't be called, not add sre->node
when local stop remote, rpmsg_deinit_vdev will call sensor_rpmsg_ns_unbind_cb
if (ept && ept->ns_unbind_cb)
ept->ns_unbind_cb(ept);
list_delete node is NULL at sensor_rpmsg_ns_unbind_cb
Signed-off-by: yintao <yintao@xiaomi.com>
When the ipc buffer is obtained for the first time due to insufficient space,
it waits due to insufficient ipc buffer.
At this time, if rptun recursively operates the next ipc request, the ipc buffer
will be reused, but it has been released at this time.
0 file_read (filep=filep@entry=0x20596738, buf=buf@entry=0x205d4358, nbytes=1560) at vfs/fs_read.c:86
1 sensor_rpmsg_push_event_one (dev=0x20558f70, dev@entry=0x2058fc80, stub=stub@entry=0x20596720) at sensors/sensor_rpmsg.c:799
2 sensor_rpmsg_alloc_stub (dev=dev@entry=0x2058fc80, ept=ept@entry=0x20558f08, cookie=<optimized out>) at sensors/sensor_rpmsg.c:552
3 sensor_rpmsg_sub_handler (ept=0x20558f08, data=0x204849c0, len=51, src=<optimized out>, priv=0x20558f00) at sensors/sensor_rpmsg.c:993
4 sensor_rpmsg_ept_cb (ept=<optimized out>, data=<optimized out>, len=<optimized out>, src=<optimized out>, priv=0x20558f00) at sensors/sensor_rpmsg.c:1186
5 rpmsg_virtio_rx_callback (vq=<optimized out>) at open-amp/lib/rpmsg/rpmsg_virtio.c:605
6 virtqueue_notification (vq=<optimized out>) at open-amp/lib/virtio/virtqueue.c:711
7 rproc_virtio_notified (vdev=vdev@entry=0x20558c98, notifyid=notifyid@entry=4294967295) at open-amp/lib/remoteproc/remoteproc_virtio.c:433
8 remoteproc_get_notification (rproc=rproc@entry=0x2054ff34, notifyid=notifyid@entry=4294967295) at open-amp/lib/remoteproc/remoteproc.c:1002
9 rptun_worker (arg=0x2054ff30) at rptun/rptun.c:339
10 rptun_notify_wait (rproc=<optimized out>, id=<optimized out>) at rptun/rptun.c:543
11 remoteproc_virtio_notify_wait (priv=<optimized out>, id=<optimized out>) at open-amp/lib/remoteproc/remoteproc.c:907
12 rproc_virtio_notify_wait (vdev=<optimized out>, vq=<optimized out>) at open-amp/lib/remoteproc/remoteproc_virtio.c:176
13 rpmsg_virtio_notify_wait (vq=<optimized out>, rvdev=0x2054ff78) at nuttx/include/openamp/rpmsg_virtio.h:162
14 rpmsg_virtio_get_tx_payload_buffer (rdev=0x2054ff78, len=0x20558f90, wait=<optimized out>) at open-amp/lib/rpmsg/rpmsg_virtio.c:404
15 rpmsg_get_tx_payload_buffer (ept=ept@entry=0x20558f08, len=len@entry=0x20558f90, wait=wait@entry=1) at open-amp/lib/rpmsg/rpmsg.c:207
16 sensor_rpmsg_push_event_one (dev=0x0, dev@entry=0x20590d60, stub=stub@entry=0x20596720) at sensors/sensor_rpmsg.c:783
17 sensor_rpmsg_alloc_stub (dev=dev@entry=0x20590d60, ept=ept@entry=0x20558f08, cookie=<optimized out>) at sensors/sensor_rpmsg.c:552
18 sensor_rpmsg_sub_handler (ept=0x20558f08, data=0x20483700, len=49, src=<optimized out>, priv=0x20558f00) at sensors/sensor_rpmsg.c:993
19 sensor_rpmsg_ept_cb (ept=<optimized out>, data=<optimized out>, len=<optimized out>, src=<optimized out>, priv=0x20558f00) at sensors/sensor_rpmsg.c:1186
20 rpmsg_virtio_rx_callback (vq=<optimized out>) at open-amp/lib/rpmsg/rpmsg_virtio.c:605
21 virtqueue_notification (vq=<optimized out>) at open-amp/lib/virtio/virtqueue.c:711
22 rproc_virtio_notified (vdev=vdev@entry=0x20558c98, notifyid=notifyid@entry=4294967295) at open-amp/lib/remoteproc/remoteproc_virtio.c:433
23 remoteproc_get_notification (rproc=0x2054ff34, rproc, notifyid=notifyid@entry=4294967295)
24 rptun_worker (arg=0x2054ff30) at rptun/rptun.c:339
25 rptun_thread (argc=<optimized out>, argv=<optimized out>) at rptun/rptun.c:375
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
power/battery/bq27426.c:331:17: error: ‘BATTERY_UNKNOWN’ undeclared (first use in this function)
331 | *status = BATTERY_UNKNOWN;
| ^~~~~~~~~~~~~~~
power/battery/bq27426.c:331:17: note: each undeclared identifier is reported only once for each function it appears in
Makefile:108: recipe for target 'bq27426.o' failed
Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
Signed-off-by: buxiasen <buxiasen@xiaomi.com>