Commit Graph

7029 Commits

Author SHA1 Message Date
simbit18
00a093e108 Fix Kconfig style
Replace help => ---help---
Add comments
2023-08-18 20:19:22 +08:00
xucheng5
15edd28a69 example/capture : fixed build warning
Signed-off-by: xucheng5 <xucheng5@xiaomi.com>
2023-08-18 14:08:33 +08:00
Xiang Xiao
7251645685 Fix some coding style issue
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-17 22:51:51 +03:00
Xiang Xiao
856416540c Remove the definition of MIN/MAX
use the macro in sys/params.h

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-17 22:51:51 +03:00
Xiang Xiao
054cf3b1cb Change all sizeof(arr)/sizeof(arr[0]) to nitems
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-17 22:51:51 +03:00
xuxin19
8e8d58a915 cmake:migrate apps CMakeLists for libsodium
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-08-17 14:35:02 +08:00
makejian
c25f5e1955 crypto: fix formatting issues in commit #1932
(1) add 'FAR' in mbedtls_hardware_poll
(2) fix indentation issues in hash testcase
Signed-off-by: makejian <makejian@xiaomi.com>
2023-08-17 14:31:41 +08:00
makejian
024a7eeec3 crypto/libsodium: fix libsodium compilation problem
(1)fix unable to pull source code
(2)fix compile warning
Signed-off-by: makejian <makejian@xiaomi.com>
2023-08-17 14:31:23 +08:00
huangkai8
323c16a5fb Wrong start and end values would make dead cycle. Exchange the values when start value is bigger than end value. 2023-08-16 20:20:03 +03:00
xuxin19
32b417a8f7 cmake:refine cmake build for apps/examples
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-08-17 01:15:17 +08:00
Shoukui Zhang
9cf473c88c mtd_config_fs: Default select MTD_CONFIG_NAMED config
Signed-off-by: Shoukui Zhang <zhangshoukui@xiaomi.com>
2023-08-16 22:06:28 +08:00
yangjiao
37ac7f923a Update cmocka_main.c to support following functions:
1. list all the testcases with "--list";
2. run some testcases with "--test";
3. show cmocka help message;
4. skip some testcases with "--skip";

Signed-off-by: yangjiao <yangjiao@xiaomi.com>
2023-08-16 01:00:36 +08:00
yangjiao
4b521051d3 cmocka/Kconfig: add the depends on item "LIBC_REGEX".
The "regex" library will be used in cmocka test, so add the dependency relationship for this config.

Signed-off-by: yangjiao <yangjiao@xiaomi.com>
2023-08-16 01:00:36 +08:00
yangjiao
f0f94a1235 testing/cmocka:add a patch.
cmocka modification upload Nuttx community preparation: upload a patch with recent changes for cmocka source code.

Signed-off-by: yangjiao <yangjiao@xiaomi.com>
2023-08-16 01:00:36 +08:00
xuxin19
817ea66e9f cmake:migrate apps CMakeLists for tinycrypt
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-08-16 00:59:04 +08:00
fengxuesong
3f556c8df4 Fix the bug of i2c_dev
Signed-off-by: fengxuesong <fengxuesong@xiaomi.com>
2023-08-14 13:40:15 +08:00
fengxuesong
c6ee7baca7 Fix the bug of i2c_bus
Signed-off-by: fengxuesong <fengxuesong@xiaomi.com>
2023-08-14 13:40:15 +08:00
liuhongchao
e5bf64d792 apps/examples:Edit arm64 compilation error
Signed-off-by: liuhongchao <liuhongchao@xiaomi.com>
2023-08-14 13:39:59 +08:00
wanggang26
eb815c48d7 ofloader: startup ofloader directly
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2023-08-14 13:39:42 +08:00
fangxinyong
b0933fe431 builtin: uid and gid configuration for builtin app
File uid and gid configuration for builtin fs, if set-user-ID bit is set
in the file permissions, then the euid of process set as file uid. Use
the confiuration to emulate builtin app set.

MODE must octal number and use similar with linux chmod OCTAL-MODE FILE
UID  = 2000
GID  = 3000
MODE = 06555

Signed-off-by: fangxinyong <fangxinyong@xiaomi.com>
2023-08-14 11:47:55 +08:00
liuhongchao
75f04dd775 drivertest:Add touch panel test case.
Signed-off-by: liuhongchao <liuhongchao@xiaomi.com>
2023-08-14 09:05:52 +08:00
Xiang Xiao
2db68e26c4 Fix Error: luv/src/constants.c:674:11: error: implicit declaration of function 'getprotobyname'
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-12 15:58:11 +03:00
Xiang Xiao
b586ab839d nshlib: Don't select LIBC_NETDB automatically
since nshlib always call netdb API inside #ifdef CONFIG_LIBC_NETDB

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-12 15:58:11 +03:00
xuxin19
dbfe1a33f1 cmake:migrate libopencyphal for cmake build
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-08-12 15:16:15 +08:00
xuxin19
28a5ecfed1 cmake:migrate libdronecan for cmake build
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-08-12 15:16:15 +08:00
xuxin19
6e8d83e783 cmake:migrate lely-canopen for cmake build
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-08-12 15:16:15 +08:00
huxiandong
5a4e9e4389 nxrecorder: mode is required when oflags include O_CREAT or O_WRONLY
Refer -- fs_open.c:
/* If the file is opened for creation, then get the mode bits */

  if ((oflags & (O_WRONLY | O_CREAT)) != 0)
    {
      mode = va_arg(ap, mode_t);
    }

Signed-off-by: huxiandong <huxiandong@xiaomi.com>
2023-08-12 01:11:35 +08:00
simbit18
e501f784c3 Fix Kconfig style
Add TABs
Add comments
2023-08-11 22:13:17 +08:00
yangjiao
910409b4fb resolve the compile error.
Update the test cases' source code to solve the conflict of test function name,like below:"/home/yangjiao/Vela_Project/vela_TinyCrypt/apps/crypto/tinycrypt/tinycrypt/tests/test_sha256.c:149: multiple definition of `test_5'; /home/yangjiao/Vela_Project/vela_TinyCrypt/nuttx/staging/libapps.a(test_hmac_prng.c.home.yangjiao.Vela_Project.vela_TinyCrypt.apps.crypto.tinycrypt.o):/home/yangjiao/Vela_Project/vela_TinyCrypt/apps/crypto/tinycrypt/tinycrypt/tests/test_hmac_prng.c:316: first defined here".

Signed-off-by: yangjiao <yangjiao@xiaomi.com>
2023-08-11 21:47:47 +08:00
yangjiao
30e56fd6a0 porting tinycrypt tests.
Signed-off-by: yangjiao <yangjiao@xiaomi.com>
2023-08-11 21:47:47 +08:00
anjiahao
34f71ec25b fstest:fix build break
fstest_main.c:340:47: note: expected ‘struct fstest_ctx_s *’ but argument is of type ‘fsblkcnt_t’ {aka ‘long long unsigned int’}
  340 | static int fstest_gc(FAR struct fstest_ctx_s *ctx, size_t nbytes)
      |                          ~~~~~~~~~~~~~~~~~~~~~^~~
fstest_main.c:1168:13: error: too few arguments to function ‘fstest_gc’
 1168 |       ret = fstest_gc(buf.f_bfree);
      |             ^~~~~~~~~
fstest_main.c:340:12: note: declared here
  340 | static int fstest_gc(FAR struct fstest_ctx_s *ctx, size_t nbytes)
      |            ^~~

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2023-08-11 21:04:44 +08:00
xucheng5
6196e03337 testing/drivertest : fix build error
Signed-off-by: xucheng5 <xucheng5@xiaomi.com>
2023-08-11 20:15:28 +08:00
zhangchao53
ba19e5b92b porting superPi to vela,add makefile
Signed-off-by: zhangchao53 <zhangchao53@xiaomi.com>
2023-08-11 18:25:07 +08:00
makejian
af3ea2af03 mbedtls: add mbedtls sha256/sha512 alternative implementation
Signed-off-by: makejian <makejian@xiaomi.com>
2023-08-11 18:13:11 +08:00
makejian
558450f0ab mbedtls: add hardware entropy source via /dev/random
add hardware entropy from /dev/random
Signed-off-by: makejian <makejian@xiaomi.com>
2023-08-11 18:13:11 +08:00
makejian
4e016e2260 mbedtls: add nuttx crypto alternative implementation in mbedtls
(1)add dev_alt to manage /dev/crypto
(2)add sha_alt to alternate sha1 algorithm
(3)use new mbedtls_config.h to admin configs of mbedtls
Signed-off-by: makejian <makejian@xiaomi.com>
2023-08-11 18:13:11 +08:00
makejian
fcbf7cc1aa testing/crypto: add md5/sha1/sha256/sha512 testcases
add hash test cases to test the support for the hash algorithm in crypto device
Signed-off-by: makejian <makejian@xiaomi.com>
2023-08-11 18:13:11 +08:00
zhangchao53
f1154b5be2 Memory leaks can be checked using cmocka
Signed-off-by: zhangchao53 <zhangchao53@xiaomi.com>
2023-08-11 18:09:40 +08:00
zhangchao53
d3d704fddb porting libtomcrypt tests cases,update make config.
Signed-off-by: zhangchao53 <zhangchao53@xiaomi.com>
2023-08-11 15:57:59 +08:00
ligd
12a2e14a83 example/poll: add delay for poll testcase
for should setup the fifo firstly

Signed-off-by: ligd <liguiding1@xiaomi.com>
2023-08-11 15:35:06 +08:00
yinshengkai
bdc522bad7 trace: move trace_dump to noteram
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-11 13:52:12 +08:00
yinshengkai
95b0515c30 trace: unify ftrace and atrace output formats
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-11 13:52:12 +08:00
xucheng5
c7955e5faf drivertest/adc : support cmocka_driver_adc
Signed-off-by: xucheng5 <xucheng5@xiaomi.com>
2023-08-11 13:51:30 +08:00
Xiang Xiao
d420036cbc testing/drivertest: Fix typo error in drivertest_uart.c
Made by:
commit 5659906fdfdac0a363aecb329c39c936324dcc55
Author: Gregory Nutt <gnutt@nuttx.org>
Date:   Fri Mar 24 12:02:04 2023 -0600

    Changes to apps needed by nutts PR 8885

    needby:965551

    ostest contains some logic that depends on internal implementation of signal sets and ostest must be updated to match those changes.

    There is no particular impact from this PR.  This PR is the result of impact from nuttx 8885.

    Tested with nuttx 8885

    Change-Id: I2550888ee29aadcfcf8a98bfe5690920ee2b17d1

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-11 13:50:55 +08:00
fengxuesong
fad26cb3ae Add function is missing FAR
Signed-off-by: fengxuesong <fengxuesong@xiaomi.com>
2023-08-11 13:50:38 +08:00
yangsen5
78792120cd nxcamera: Solve compilation errors caused by type mismatch
CC:  nxcamera.c nxcamera.c: In function 'show_image':
nxcamera.c:85:20: error: initialization of 'uint32_t *' {aka 'unsigned int *'} from incompatible pointer type 'uint8_t *' {aka 'unsigned char *'} [-Werror=incompatible-pointer-types]
   85 |   uint32_t *pbuf = pcam->bufs[buf->index];
      |                    ^~~~
cc1: all warnings being treated as errors

Signed-off-by: yangsen5 <yangsen5@xiaomi.com>
2023-08-11 13:50:28 +08:00
dulibo1
3c674fb4d8 add test case for regulator
Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-08-11 00:45:16 +08:00
yinshengkai
d090da6b91 examples/watcher: get the thread name using pthread_getname_np
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-10 22:50:58 +08:00
dulibo1
6534f3d87c add batterydump tool for dump the battery info
Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-08-10 20:44:03 +08:00
yangguangcai
5c6ffe1a4d drivertest:fix timer testcase
Signed-off-by: yangguangcai <yangguangcai@xiaomi.com>
2023-08-10 20:41:05 +08:00