7960 Commits

Author SHA1 Message Date
pengyaozong
63f43e70a9 add LIBUV_HANDLE_BACKTRACE
Signed-off-by: pengyaozong <pengyaozong@xiaomi.com>
2024-10-16 14:30:34 +08:00
anjiahao
c693b3064e system/coredump:support coredump can save board memory
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 14:22:43 +08:00
anjiahao
9752b57714 system/coredump:upload kernal coredump change
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 14:22:43 +08:00
anjiahao
b99f92bac5 system/coredump:fix coverity bug
check read return, avoid dead loop if read return zero

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 14:22:43 +08:00
anjiahao
03f3ce7fd4 system/coredump:Increase coredump swap buffer size to improve speed
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 14:22:43 +08:00
Xiang Xiao
e96f1ca83a system/ymodem: Change #include <nuttx/mm/circbuf.h> to #include <nuttx/circbuf.h>
follow the change in kernel side change

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2024-10-16 14:20:34 +08:00
yangguangcai
49941f1d57 cmd_date:Set optind to zero in the error case.
Signed-off-by: yangguangcai <yangguangcai@xiaomi.com>
2024-10-16 12:40:04 +08:00
anjiahao
8130d7e211 zlib:Support using Kconfig to control memory usage in zlib
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 12:39:47 +08:00
Yongrong Wang
3514c6c704 drivertest/Makefile: add CONFIG_BUILD_FLAT limit for drivertest_block.c
If BUILD_FLAT is not enabled, the app and CPU run in user mode and
kernel mode respectively. The kernel and app are in different
memory address spaces. Different apps are in the same memory address
space. drivertest_block.c cannot directly call the kernel API.

Signed-off-by: Yongrong Wang <wangyongrong@xiaomi.com>
2024-10-16 12:34:25 +08:00
Bowen Wang
4af9653b1e nshlib/nsh_parse: support use \\ to pass '\' to argument
Now the nsh can use \\ to pass '\' to the command

Signed-off-by: Bowen Wang <wangbowen6@xiaomi.com>
2024-10-16 10:21:30 +08:00
anjiahao
bb492e789d sotest & chardev:change elf loading method
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 07:38:06 +08:00
anjiahao
bebb7e9a46 module/sotest:use Compile dynamic modules using a unified compilation method
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 07:38:06 +08:00
anjiahao
293c05b5e6 apps/Makefile:Add a postinstall keyword to do something before compilation is completed and linking begin
It is better to package the dynamic module into romfs after it is compiled.

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 07:38:06 +08:00
anjiahao
5debbb8d46 Application.mk:unify module compilation
we can build a module like app,
use 'DYNLIB' mark current path is a loadable module

and CFLAGSELF and CMODFLAGS can act on
these compiled as loadable module

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2024-10-16 07:38:06 +08:00
jihandong
eca0928319 cxxtest: optional stream test.
Signed-off-by: jihandong <jihandong@xiaomi.com>
Signed-off-by: cuiziwei <cuiziwei@xiaomi.com>
2024-10-16 07:20:47 +08:00
Yongrong Wang
a486129907 testing/drivertest_block.c: Fix cmoka driver block test error
1. Fix the problem that pre->source may have memory stampede
2. Fix total block size larger than cache size condition

Signed-off-by: Yongrong Wang <wangyongrong@xiaomi.com>
2024-10-16 07:18:20 +08:00
yintao
0e519328c8 fstest: Add header to fix build issues
Signed-off-by: yintao <yintao@xiaomi.com>
2024-10-16 07:17:20 +08:00
yintao
2d248c1eaa examples/rpsock: fix redefined warning
CC: rpsock_client.c:41:9: warning: 'ALIGN_UP' macro redefined

Signed-off-by: yintao <yintao@xiaomi.com>
2024-10-16 07:16:07 +08:00
yintao
bfde92a3fd examples/rpmsgsocket: fix build warning
Signed-off-by: yintao <yintao@xiaomi.com>
2024-10-16 07:16:07 +08:00
wanggang26
2de1fdcebd thttpd:fix Coding Style Check Failed issue
error: Mixed case identifier found

Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2024-10-16 07:13:50 +08:00
ouyangxiangzhen
44d2250b6e apps: Fix compilation error after nuttx/arch.h excluded.
This patch fix compilation error after excluding nuttx/arch.h.

Signed-off-by: ouyangxiangzhen <ouyangxiangzhen@xiaomi.com>
2024-10-16 07:12:40 +08:00
Gao Jiawei
30215c260b add test for longjump with 0 as return value
Signed-off-by: Gao Jiawei <gaojiawei@xiaomi.com>
2024-10-16 07:12:10 +08:00
yangguangcai
3f08d4f11c rtc: change localtime to gmtime.
Signed-off-by: yangguangcai <yangguangcai@xiaomi.com>
2024-10-16 07:11:40 +08:00
anjiahao
345e303133 nshlib:Add macro restrictions to code that uses floating point numbers
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-10-16 07:11:02 +08:00
zhangwenjian
8e7d6cadf4 support filter for each note channel
Signed-off-by: zhangwenjian <zhangwenjian@xiaomi.com>
2024-10-15 12:34:09 +08:00
yinshengkai
2ea062642f nshlib: Add startup process buried points
Used for system startup time profiling

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-15 12:34:09 +08:00
yinshengkai
bcbd092d3e trace: fix trace dump crash
After thread switching is triggered in an interrupt, two notes will be printed.
If the buffer of 256 is not enough, it will cause overflow.

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-15 12:34:09 +08:00
yinshengkai
9c51919a1a libuv:add threadpool DEF_THREADPOOL_PRIORITY
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-15 10:32:08 +08:00
guohao15
be85fab47c libuv:Make libuv use epoll runable without fsnotify
Signed-off-by: guohao15 <guohao15@xiaomi.com>
2024-10-15 10:32:08 +08:00
guohao15
ed91a3c03c libuv:change LIBUV_BACKEND_EPOLL depends on FS_NOTIFY
Signed-off-by: guohao15 <guohao15@xiaomi.com>
2024-10-15 10:32:08 +08:00
guohao15
4e386a955e system/libuv: optimize stack usage
Signed-off-by: guohao15 <guohao15@xiaomi.com>
2024-10-15 10:32:08 +08:00
guohao15
5891f7037b libuv:add inotify test for nuttx
Signed-off-by: guohao15 <guohao15@xiaomi.com>
2024-10-15 10:32:08 +08:00
dongjiuzhu1
8b6e63c22d libuv: default select epoll backend in libuv
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2024-10-15 10:32:08 +08:00
wangming9
8ed046e2d6 apps/benchmarks/dhrystone: Fix compilation errors
Error details:
dhrystone/v2.2/dry.c:714:3: error: 'Int_2_Loc' may be used uninitialized [-Werror=maybe-uninitialized]
  714 |   fprintf (stderr, "Int_2_Loc:           %d\n", Int_2_Loc);
      |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
dhrystone/v2.2/dry.c:543:25: note: 'Int_2_Loc' was declared here
  543 |   REG   One_Fifty       Int_2_Loc;
      |                         ^~~~~~~~~

Signed-off-by: wangming9 <wangming9@xiaomi.com>
Signed-off-by: lipengfei28 <lipengfei28@xiaomi.com>
2024-10-15 10:31:14 +08:00
chenrun1
bb957498cc cjson_test:add define CONFIG_CJSON_NESTING_LIMIT
Summary:
 Added a limit to CJSON_NESTING_LIMIT. The default value is 1000, which can cause stack overflow in some test cases.

Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2024-10-15 00:57:11 +08:00
ligd
0e8a6ee2d2 Revert "add test for longjump with 0 as return value"
This reverts commit 63542f83c2985723071ae7e428311213008aa108.

Signed-off-by: ligd <liguiding1@xiaomi.com>
2024-10-14 13:31:47 +08:00
Xiang Xiao
2eeb750055 Fix telnetd.c:57:5: error: 'CONFIG_SYSTEM_TELNETD_SESSION_STACKSIZE' undeclared
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2024-10-14 10:44:40 +08:00
raiden00pl
d9cc2c29f2 github/issue: update bug report template
update bug report template issue so that it better reflects the nuttx-apps repo
2024-10-13 23:30:08 +08:00
raiden00pl
f7f4f77e2e github: add auto labeler for PR
this commit adds initial support for auto labeler for PR
based on https://github.com/actions/labeler
2024-10-13 23:30:08 +08:00
wangjianyu3
2bfe2c2ed0 nshlib: Fix a typo error of redirect
Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2024-10-13 15:48:57 +08:00
wangjianyu3
0f5a786347 nshlib: Fix stack-buffer-overflow of nsh_redirect()
Board/Config/Command
  sim:nsh
  cat < /etc/init.d/rc.sysinit

Problem
  The NSH hangs after exec the test command.
  `nsh_redirect()` needs to save three fd but array length is only two, stack buffer overflowed!

Related: https://github.com/apache/nuttx-apps/pull/2469

Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2024-10-13 15:48:57 +08:00
buxiasen
2429b2ef6a ramspeed: fix -r -w parameter ignored, report align issue
We may want to test ramspeed by specific address, it was previous ignored,
and for the not aligned address from user, just report a error.

Signed-off-by: buxiasen <buxiasen@xiaomi.com>
2024-10-13 11:44:58 +08:00
Gao Jiawei
63542f83c2 add test for longjump with 0 as return value
Signed-off-by: Gao Jiawei <gaojiawei@xiaomi.com>
2024-10-13 10:50:58 +08:00
yinshengkai
e9b457fca1 telnet: Configure the telnet session stack to be the same as nsh
Using the default 3K stack size will result in insufficient stack when executing certain commands.

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-13 10:49:46 +08:00
yinshengkai
524eb0880f osperf: changes irq_t to irqstat_t
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-13 10:49:05 +08:00
yinshengkai
dbef7b5f85 examples: fix usrsocktest compiler warning
error: variable 'ret' set but not used [-Werror=unused-but-set-variable]
   112 |   int ret;

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-13 10:35:20 +08:00
yinshengkai
427b107dac quickjs: fix mp_mul multiple definition
in function `mp_mul':
apps/interpreters/quickjs/quickjs/libbf.c:1179: multiple definition of `mp_mul';
nuttx/staging/libapps.a:apps/math/libtommath/libtommath/bn_mp_mul.c:8: first defined here

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-13 10:34:43 +08:00
zhanghu5
5f3e3fe655 fix ECHO problem
only when devfd and stdfd both are tty, we call tcsetattr

Signed-off-by: zhanghu5 <zhanghu5@xiaomi.com>
2024-10-13 10:33:22 +08:00
Marco Casaroli
bc19db2c78 ci: use venv for check
To avoid the following CI error:

This environment is externally managed
--> To install Python packages system-wide, try apt install
    python3-xyz, where xyz is the package you are trying to
    install.

    If you wish to install a non-Debian-packaged Python package,
    create a virtual environment using python3 -m venv path/to/venv.
    Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
    sure you have python3-full installed.

    If you wish to install a non-Debian packaged Python application,
    it may be easiest to use pipx install xyz, which will manage a
    virtual environment for you. Make sure you have pipx installed.

    See /usr/share/doc/python3.12/README.venv for more information.
2024-10-13 10:17:17 +08:00
xuxin19
131ff36842 build.yml:disable CMake Ninja for Msys2
CI in the msys2 environment, the CMake ninja generator
will have a problem with parameters being too long

Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2024-10-13 00:39:30 +08:00