Commit Graph

7317 Commits

Author SHA1 Message Date
Lingao Meng
518e455dce add macro for ecc
application may use micro-ecc for some ecc operation, which may be
faster than tinycrypt, due to assamble code, but both of them have
same function defination, cause build error on there case.

Signed-off-by: Lingao Meng <menglingao@xiaomi.com>
2023-08-29 12:19:26 +03:00
chenrun1
844a31b24c memtester:update format
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-08-29 17:07:58 +08:00
chenrun1
56045e8e3d memtester:Two new bit-width test items
Because it may cause unaligned access problems with some hardware, these
two tests are not turned on by default, and are enabled or disabled
through Kconfig.

Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-08-29 17:07:58 +08:00
chenrun1
de3746e2ba memtester:Adaptation of memtester
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-08-29 17:07:58 +08:00
chao an
6923c9cf57 testing: fix visual studio Compiler Error C2057
expected constant expression
The context requires a constant expression, an expression whose value is known at compile time.
The compiler must know the size of a type at compile time in order to allocate space for an instance of that type.

Reference:
https://learn.microsoft.com/en-us/cpp/error-messages/compiler-errors-1/compiler-error-c2057?view=msvc-170

Signed-off-by: chao an anchao@xiaomi.com
Signed-off-by: chao an <anchao@xiaomi.com>
2023-08-29 15:44:09 +08:00
dulibo1
afcc8d8f62 regulator:add testcase for regualtor register
Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-08-29 13:41:08 +08:00
Niklas Hauser
78a6d07a90 nshlib/nsh_consolemain: detect null pointer
Returning with an error from nsh_consolemain prevents dereferencing a
NULL pointer later in the code.
2023-08-29 03:11:28 +08:00
wangmingrong
7981278021 apps/nshlib: Add the pidof command and API nsh_getpid
Add the API "nsh_getpid" in "nsh_fsutils. c" and the nsh command pidof. Temporarily support two parameters, - s, and process name

Signed-off-by: wangmingrong <wangmingrong@xiaomi.com>
2023-08-29 02:58:45 +08:00
yanghuatao
658b847384 apps/rpsock_client: Fix rpsock_client.c [-Wformat=] warning
Fix warning:
CC:  rpsock_client.c rpsock_client.c: In function 'rpsock_unsync_test':
rpsock_client.c:203:30: warning: format '%x' expects argument of type 'unsigned int', but argument 4 has type 'uint32_t' {aka 'long unsigned int'} [-Wformat=]
  203 |                       printf("client check fail total %d, \
      |                              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  204 |                               i %d, %08x, %08x\n",
      |                               ~~~~~~~~~~~~~~~~~~~
  205 |                               ALIGN_UP(total), i, intp[i],
      |                                                   ~~~~~~~
      |                                                       |
      |                                                       uint32_t {aka long unsigned int}

Signed-off-by: yanghuatao <yanghuatao@xiaomi.com>
2023-08-28 17:34:02 +03:00
wanggang26
75c8580238 nshlib: fix a typo
painc to panic

Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2023-08-28 17:33:15 +03:00
yinshengkai
5a0bc863dd setlogmask: fix uncloseed handle
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-28 17:09:18 +03:00
makejian
11de514217 mbedtls: update Kconfig
update Kconfig for adapting version v3.4.0
Signed-off-by: makejian <makejian@xiaomi.com>
2023-08-27 21:44:10 +08:00
haopengxiang
26e2736863 benchmarks/coremark: apply SEED_METHOD/MEM_METHOD update
Signed-off-by: haopengxiang <haopengxiang@xiaomi.com>
2023-08-26 20:03:06 +08:00
liaoao
1243c0ba4d libfdt: modify makefile
update LIBFDT to LIBC_FDT
move version_gen.h and place it under nuttx/libs/libc/fdt/
change include path to nuttx/libs/libc/fdt/dtc/

Signed-off-by: liaoao <liaoao@xiaomi.com>
2023-08-26 17:06:55 +08:00
liuhongchao
a3dfef117b apps/examples:Add keyboard example
Signed-off-by: liuhongchao <liuhongchao@xiaomi.com>
2023-08-26 17:02:48 +08:00
fangxinyong
512af7fbd7 ltp/makefile: filter testcases based on defconfig
Signed-off-by: fangxinyong <fangxinyong@xiaomi.com>
2023-08-25 21:17:56 +03:00
SPRESENSE
5058a0dba7 Application.mk: Remove warning that program names mismatch
Avoid warning when PROGNAME contains space blank.
2023-08-26 01:18:10 +08:00
raiden00pl
0cd1901da9 boot/miniboot: hide miniboot options if not enabled 2023-08-26 01:17:42 +08:00
Ville Juven
94d477b3df nshlib/nsh_console.h: Add nsh_none, where any empty output can be forwarded
Add nsh_none to consume all empty traces from nsh.

For the variadic argument case need to add a (inline) function to eat
away the __VA_ARGS__ list, there is no good / portable way to do this by
pre-processor macros, but a function will eat the variadic list whatever
its size is.
2023-08-25 17:18:35 +08:00
Ville Juven
1668c3e97d Revert "nshlib/nsh_timcmds.c: Suppress warning about unused variable (errfmt)"
This reverts commit 4ca9b518fa9923c1af9c120eafbac59359874e13.
2023-08-25 17:18:35 +08:00
makejian
1274aa5c8a mbedtls: mbedtls_selftest depends on MBEDTLS_SSL_DTLS_CONNECTION_ID
Signed-off-by: makejian <makejian@xiaomi.com>
2023-08-25 17:02:44 +08:00
haopengxiang
a4f0349813 benchmarks/coremark: fix no coremark in bin
Signed-off-by: haopengxiang <haopengxiang@xiaomi.com>
2023-08-25 08:23:53 +02:00
xuxin19
a091b91d83 cmake:replace custom_patch_target with PATCH_COMMAND
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-08-24 17:49:12 +02:00
xuxin19
4765cc3411 Application.mk:define main entry MAINNAME relatively
when a program has multiple MAINSRC for incremental compilation,
the PROGNAME of the compiled file may generate errors
-------------------- compile definition error ---------------------
cc -c -g CFLAGS INCLUDEDIR -Dmain=funA_main funB.c -o funB.c.path.o
                             ^^^^  ^^^^^^    ^^^^
-------------------------------------------------------------------
use the MAINOBJ:PROGNAME mapping variable to define the main entry name

Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-08-24 23:36:30 +08:00
chao an
8aa3c1e4b9 system/libuv: export GCCVER to environment
Signed-off-by: chao an <anchao@xiaomi.com>
2023-08-24 20:49:22 +08:00
chao an
77e6c39cbd system/libuv: strict GCC version check from GCC-12.2 to GCC-12
Toolchain related detection errors are still not resolved on GCC-12.3

Signed-off-by: chao an <anchao@xiaomi.com>
2023-08-23 23:51:14 +08:00
YAMAMOTO Takashi
73f27b7cae toywasm: regen for v33
```
REF=e03d1f61d3f3163da76b33c4c770dbf0d2024324 ./regen.sh
```
2023-08-23 03:02:12 +08:00
YAMAMOTO Takashi
816b499ef8 toywasm: bump to v33 2023-08-23 03:02:12 +08:00
Ville Juven
b65b577ad3 nshlib/nsh_timcmds.c: Suppress warning about unused variable (errfmt)
Fixes following warning:

CC:  grp/lib_getgrbufr.c nsh_timcmds.c: In function 'cmd_date':
nsh_timcmds.c:370:19: warning: variable 'errfmt' set but not used [-Wunused-but-set-variable]
  370 |   FAR const char *errfmt;
      |
2023-08-23 00:17:25 +08:00
dongjiuzhu1
d73e6412b7 apps/gpsutils: move gpsutils to nuttx/libs/libc/gpsutils
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-08-22 23:05:53 +08:00
Zhe Weng
87838bb62c ostest/wqueue: Check return value for pthread ops.
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-08-22 13:55:03 +08:00
Andre Heinemans
8757c6934c Added tools for NXP SE05x (secure element) 2023-08-22 10:12:31 +08:00
Petro Karashchenko
189d0c803f net/ip: print ip addresses using ip4_addrN macro
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-08-22 01:36:42 +08:00
raiden00pl
2b58cc6578 rptun/ping: fix invalid use of nsh_error after 31421db6f 2023-08-21 18:47:01 +03:00
Xiang Xiao
6716f15d7b testing: Check CONFIG_TLS_NELEM is defined before using it
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-21 15:08:17 +03:00
makejian
18280fdc25 mbedtls-alt: add aes alternative implementation
aes module of mbedtls use alternative implementation via /dev/crypto
Signed-off-by: makejian <makejian@xiaomi.com>
2023-08-21 16:10:48 +08:00
raiden00pl
31421db6fa rptun/ping: print invalid arguments error 2023-08-20 22:58:07 +08:00
simonatoaca
4739b18cb1 examples/bme680: Added test program for the BME680 sensor
The program is an example on how to poll the sensor for data when
all its sub-sensors are enabled.

Signed-off-by: simonatoaca <simona.alexandra2000@gmail.com>
2023-08-18 23:00:32 +08:00
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