Commit Graph

1063 Commits

Author SHA1 Message Date
yangsen5
4d2fb8a6cf nxcamera: Add logic to convert to rgb565
Since the current fb display format of vela qemu is rgb565, it is necessary to convert the frame obtained by v4l2 to rgb565

Signed-off-by: yangsen5 <yangsen5@xiaomi.com>
2023-08-09 18:22:39 +08:00
chao an
3b2b73de88 coredump/priority: Increase the default priority of coredump to 254
Increase coredump priority to avoid unnecessary task switch during dump

Signed-off-by: chao an <anchao@xiaomi.com>
2023-08-09 15:00:45 +08:00
fengxuesong
2909e8d7a0 Add function missing FAR information
Signed-off-by: fengxuesong <fengxuesong@xiaomi.com>
2023-08-09 14:47:00 +08:00
shipei
5aaf4136bf nxplayer:add sbc simple parser in nxplayer
Usage:
device /dev/audio/compress0p
play /data/test.sbc

This function requires the platform to support compress decoding and playback

Signed-off-by: shipei <shipei@xiaomi.com>
2023-08-08 21:41:15 +08:00
zhangyuan21
987cb1ebd9 adb: support adb boardctl when not composite device
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-08-08 00:11:54 -07:00
chenrun1
5645b82b74 memorystress:Fix some warnings and make the index randomized.
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-08-03 10:55:12 -07:00
chenrun1
4a78dedbae memorystress:For pressure detection of memory stability
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-08-03 10:55:12 -07:00
wanggang26
ccd6aec427 ofloader: fix warning and typo
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2023-08-01 23:22:52 -07:00
anjiahao
d0ad047f81 support openflashloader for nuttx
wiki:https://wiki.segger.com/SEGGER_Flash_Loader

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
Signed-off-by: chao an <anchao@xiaomi.com>
2023-08-01 23:22:52 -07:00
simbit18
85988dc77f Fix nuttx coding style
Remove TABs
2023-08-01 23:10:32 -07:00
anjiahao
c08feedcfd ymodem:fix compile warnings
rb_main.c:219:42: warning: 'snprintf' output may be truncated before the last format character [-Wformat-truncation=]
  219 |           snprintf(temp, PATH_MAX, "%s/%s", priv->foldname,

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2023-07-30 01:20:36 -07:00
anjiahao
55b0d4a110 ymodem:support sbrb.py use serial to transport
Get help to use ./sbrb.py -h
./sbrb.py -h
usage: sbrb.py [-h] [-k KBLOCKSIZE] [-t TTY] [-b BAUDRATE] [-r [RECVFROM ...]] [-s SENDTO] [--debug DEBUG] [filelist ...]

positional arguments:
  filelist              if filelist is valid, that is sb, else is rb

options:
  -h, --help            show this help message and exit
  -k KBLOCKSIZE, --kblocksize KBLOCKSIZE
                        This opthin can set a customsize block size to transfer
  -t TTY, --tty TTY     Serial path
  -b BAUDRATE, --baudrate BAUDRATE
  -r [RECVFROM ...], --recvfrom [RECVFROM ...]
                        recvfile from board path like this: ./sbrb.py -r <file1 [file2 [file 3]...]> -t /dev/ttyUBS0
  -s SENDTO, --sendto SENDTO
                        send file to board path like this: ./sbrb.py -s <path on board> -t /dev/ttyUBS0 <file1 [file2 [file3] ...]>
  --debug DEBUG         This opthin is save debug log on host

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2023-07-30 01:20:36 -07:00
anjiahao
8fd4b4d45b ymodem:fix ymodem bug
1.Timeout processing
2.clear error count when received successfully once
3.fix the bug of insufficient header memory application

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2023-07-30 01:20:36 -07:00
dongjiuzhu1
e86f6c12a5 system/popen: support r+, w+ mode
The standard popen uses the pipeline internally, so the stream
returned by it can only support read-only or write-only.
Now this patch is expanded through sockpair, which can support both
read and write. Therefore, we can use the stream to read and write
access this task (posix_spawn start).

Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-07-29 20:29:54 -07:00
dongjiuzhu1
718fcfac1e system/uorb: Solve the problem of wrong use of return value
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-07-28 21:51:10 -07:00
zhangyuan21
7277a48482 uorb: Avoiding GCC VCVT Issue When MVE is Enabled
https: //sourceware.org/git/?p=binutils-gdb.git;a=commit;h=656412a7a4da0aef43ead1ea976ba0235a7ec30a

Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-07-28 21:49:58 -07:00
dongjiuzhu1
78590a55ea system/uorb: Support frequency less than 1hz
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-07-28 21:49:58 -07:00
chao an
c0707b5fc3 system/artable3: add cmake build support
Signed-off-by: chao an <anchao@xiaomi.com>
2023-07-25 10:48:01 +02:00
chenrun1
10baddee07 system/cachespeed:Modifying kconfig depends on
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-07-20 01:42:38 +08:00
chenrun1
d0349a3bd4 system/cachespeed:Optimize the number of tests
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-07-20 01:42:38 +08:00
chenrun1
f3b1ac089b system/cachespeed:Redesign of the overall test tool.
Compared to the previous version, the following factors have been taken into account in the new version of cachespeed:
1. the user needs to care about getting a piece of available memory (even if this piece of memory may memory stomp during use)
2. High repetition of test code, poor readability, and overall high test coupling
3. Not taking into account the alignment cache line situation
4. When comparing values between different test tools, there is a little error because of the different ways to get the values (different fine reading)
Therefore, in the new version according to the above problems have been improved:
1. Provide a "test_skeleton", which contains the overall testing process
2. The user only needs to execute, not to care about how to get the available memory address, and the memory allocated by the program also ensures the memory security and data accuracy
3. The system to obtain the data required for the test reduces the difficulty of use and the possibility of inaccurate results due to data errors.
4. Provide two kinds of precision data results, which can be configured through Kconfig
5. Optimize the output log, now more intuitive and concise, to help the subsequent data organization and observation
6. New test items for aligned/unaligned cache line
7. Better readability and extensibility, making it easier to add/remove test items

Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-07-20 01:42:38 +08:00
Lucas Saavedra Vaz
6f56e69a14 system/nxdiag: Fix race condition during build
This commit fixed a race condition that might happen by only unshallowing the Espressif HAL only after it was completely cloned.
2023-07-18 23:43:29 +08:00
chao an
7cfcb49213 cmake/apps: add more applications into cmake support
Signed-off-by: chao an <anchao@xiaomi.com>
2023-07-13 19:00:18 +02:00
anjiahao
73b888869b gdbstub:Support a general gdbstub, support serial port and network link
Partially implement the gdb rsp protocol,
you can debug the nuttx kernel through the serial port or the network

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2023-07-13 19:31:57 +08:00
yinshengkai
a7c6b20e89 syste/setlogmask: add syslog channel filtering function
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-07-13 00:47:23 +08:00
chao an
4d79a5cbaf add initial cmake build system
Co-authored-by: Daniel Agar <daniel@agar.ca>
Signed-off-by: chao an <anchao@xiaomi.com>
2023-07-08 13:52:02 +08:00
fangxinyong
7faebbd425 libuv: fix compile warning
CC:  pthread/pthread_mutexinconsistent.c libuv/src/unix/getaddrinfo.c:103:9: warning: implicit declaration of function ‘getaddrinfo’; did you mean ‘uv_getaddrinfo’? [-Wimplicit-function-declaration]
  103 |   err = getaddrinfo(req->hostname, req->service, req->hints, &req->addrinfo);
      |         ^~~~~~~~~~~
      |         uv_getaddrinfo
libuv/src/unix/getaddrinfo.c: In function ‘uv_freeaddrinfo’:
libuv/src/unix/getaddrinfo.c:222:5: warning: implicit declaration of function ‘freeaddrinfo’; did you mean ‘uv_freeaddrinfo’? [-Wimplicit-function-declaration]
  222 |     freeaddrinfo(ai);
      |     ^~~~~~~~~~~~
      |     uv_freeaddrinfo
CC:  misc/lib_crc16ccitt.c libuv/src/unix/getnameinfo.c: In function ‘uv__getnameinfo_work’:
libuv/src/unix/getnameinfo.c:45:9: warning: implicit declaration of function ‘getnameinfo’; did you mean ‘uv_getnameinfo’? [-Wimplicit-function-declaration]
   45 |   err = getnameinfo((struct sockaddr*) &req->storage,
      |         ^~~~~~~~~~~
      |         uv_getnameinfo

Signed-off-by: fangxinyong <fangxinyong@xiaomi.com>
2023-07-01 13:27:02 +08:00
Lucas Saavedra Vaz
7bfd623616 system/nxdiag: Add Espressif's HAL version
Adds the currently used ESP HAL version to NXdiag's output.
2023-06-29 00:57:53 +08:00
chenrun1
fd38b95467 system/ramtest.c:New automatic memory acquisition function.
In this change, we have added a malloc from the heap to get the address when the user does not pass an address.
We took into account that the user would be testing the memory after the device was started, but this required them to focus on how to get a piece of address available. To improve the experience of tool users, we can simply ask them to get a size for testing purposes, while also keeping the ability to test for a given address
This change is mainly in the 'parse_commandline' function, so there are a few changes in the way it is used, see usage for details.

Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-06-26 13:57:11 +08:00
Stuart Ianna
a549668439 system/ramspeed: Allow read and write buffers to be allocated from the heap.
This change makes it much easier to use the ramspeed test in BUILD_KERNEL,
as one does not need to know which virtual address is safe to use.
2023-06-23 17:06:09 +08:00
Petro Karashchenko
c9c4cc13e6 apps: correct print specifiers to fix compilation warnings
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-06-23 12:05:54 +08:00
Petro Karashchenko
aed0e2873e apps: fix style issues in code
Add missing FAR and CODE to pointers
Remove FAR for non-pointer variables
Remove extra spaces and align the parameters
Add do {} while(0) wrapper in macro
Use nitems to calculate number of elements in arrays

Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-06-11 18:47:50 +08:00
chao an
65ee6bea44 system/cu: disable error print if SYSTEM_CUTERM_DISABLE_ERROR_PRINT enabled
Test on sim/nsh (CONFIG_SYSTEM_CUTERM_DISABLE_ERROR_PRINT=y):

   text	   data	    bss	    dec	    hex	filename
 397049	  26704	   4128	 427881	  68769	nuttx      /* before */
 396481	  26704	   4128	 427313	  68531	nuttx      /* after */
   -568

Signed-off-by: chao an <anchao@xiaomi.com>
2023-06-10 02:29:47 +08:00
Lucas Saavedra Vaz
890524c86f system/nxdiag: Fix issues introduced by #1776
Fix compilation issue by properly providing the defconfig name
2023-06-03 02:26:33 +08:00
Lucas Saavedra Vaz
9cc710e954 testing/nxdiag: Move to "system" and improve info generated
Move the application to the "System" category. Improve host OS info by using platform.uname() and get current config file using CONFIG_BASE_DEFCONFIG
2023-05-27 13:48:32 +08:00
jinxiuxu
df418bea81 system/audio: check if channels are valid
check ac_channels upper four bits which means min channels.

Signed-off-by: jinxiuxu <jinxiuxu@xiaomi.com>
2023-05-26 02:24:28 +08:00
chao an
6f4546f597 system/coredump: add coredump tool to capture system status
Signed-off-by: chao an <anchao@xiaomi.com>
2023-05-25 11:46:22 +08:00
Xiang Xiao
e81227f99d Indent the define statement by two spaces
follow the code style convention

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-05-22 11:57:40 +02:00
Xiang Xiao
7032c72f2f Indent the define statement by two spaces
follow the code style convention

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-05-21 07:39:53 +03:00
jinxiuxu
ceba53402e nxlooper: set default format for nxlooper
set default format as AUDIO_FMT_PCM for nxlooper.

Signed-off-by: jinxiuxu <jinxiuxu@xiaomi.com>
2023-05-15 17:30:57 +08:00
raiden00pl
d521d2ea57 telnetd/Kconfig: cosmetic change
With this change `# CONFIG_SYSTEM_TELNETD_PORT is not set` will not be present
in the generated `.config` file if telnetd is disabled.
2023-05-13 10:15:02 -03:00
simbit18
b810ac0b7e system: Fix nxstyle errors
error: Long line found
2023-05-10 15:40:06 +02:00
Xiang Xiao
f95d60366a Fix the nxstyle warning
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-05-08 21:35:16 +03:00
Xiang Xiao
575582ca85 system/vi: Replace strncat with strlcat
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-05-08 21:35:16 +03:00
Xiang Xiao
73701cd7cd Replace all strncpy with strlcpy
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-05-08 21:35:16 +03:00
Xiang Xiao
7c37421266 Replace all sprintf with snprintf
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-05-08 21:35:16 +03:00
Xiang Xiao
134b8b538f Replace all strcat with strlcat
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-05-08 21:35:16 +03:00
Radek Pesina
be55ea7869 spitool: add support for 32-bit SPI BUS width
Link: https://git.motec.com.au/id/I62920d28ab9804d52d25af3bcdd0f1ceb87be93f
2023-05-06 03:23:02 +08:00
simbit18
6a5912c76c system/termcurses: Fix nxstyle errors
error: Long line found
2023-05-04 20:19:56 +08:00
anjiahao
fd42d811c2 support ymodem transfer on a custom blocksize
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2023-04-29 21:23:55 +08:00
anjiahao
32e597a136 support ymodem send/recve can asynchronous
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2023-04-29 21:23:55 +08:00
yinshengkai
08bfc4e9c7 system/critmon: fix warning
critmon.c:269:3: warning: 'runtime' may be used uninitialized in this function [-Wmaybe-uninitialized]
  269 |   printf("%11s %11s %11s %-16s %-5s %s\n",
      |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  270 |          maxpreemp, maxcrit, maxrun, runtime, entryp->d_name, name);

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-04-25 20:00:54 +08:00
Zhe Weng
e935f153bc apps/system: Call arg_freetable before iptables/tcpdump exit
Forget to free argtable before exit.

Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-04-24 23:47:45 +08:00
yinshengkai
3877c31b2f critmon: add total time running time of task
PRE-EMPTION   CSECTION      RUN         TIME         PID   DESCRIPTION
0.000000000   0.000000000   0.001237000 28.421047000 0     Idle Task

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-04-24 04:44:52 -04:00
Xiang Xiao
fe1d701b71 system/adb: Replace adb special reset cause with boardctl.h's value
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-04-23 10:44:43 -07:00
Fotis Panagiotopoulos
c50ff7ff61 Fixes in asprintf usage. 2023-04-23 17:16:34 +08:00
chenrun1
69d5f960fc system/ramspeed:Fix the problem that irq_disable is often opened.
Fix the problem that "when repeat_num!=0, there is no break, so irq_disable will be configured to true by default".
2023-04-19 03:10:05 +08:00
raiden00pl
9f3f6a4b3b system/usbmsc: set stack size to DEFAULT_TASK_STACKSIZE 2023-04-07 13:45:07 +03:00
Ville Juven
c694d8d90f system/composite_main.c: Convert fprintf -> dprintf
CONFIG_FILE_STREAMS now defaults to 'n' when DEFAULT_SMALL is enabled. This
is a good change, but this source file fails to compile when file streams
are disabled.

Fix this by using dprintf.
2023-04-03 21:33:19 +03:00
Xiang Xiao
fd9c92e2e9 system/cu: Move fd_std_tty, g_tio_std and g_tio_dev to cu_globals_s
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-03-29 14:50:11 +03:00
Gustavo Henrique Nihei
efb4e0bc91 Add another batch of missing headers throughout the repository
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2023-03-28 14:54:16 -03:00
Xiang Xiao
35edbf02f5 system/cu: Remove the duplicated SIGINT definition
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-03-26 09:12:45 -06:00
simbit18
386e077525 apps/system/ymodem/Makefile: fix nxstyle
Remove LF first line
2023-03-24 15:04:43 -03:00
simbit18
1adc70fe43 apps/system/ymodem/Make.defs: fix nxstyle
Remove LF first line
2023-03-24 15:04:43 -03:00
Huang Qi
4079f6d613 system/cu: Let remote machine handle special character except Ctrl-C
Let remote machine handle special character except Ctrl-C, make cu's behavior more close to linux/bsd system.

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-03-22 11:51:04 -03:00
Huang Qi
8ae5a1b148 Fix some hard coded buffer len of snprintf
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-03-21 20:57:56 -03:00
simbit18
48928e1c68 apps/system/dumpstack/Makefile: fix style
fix error: Relative file path does not match actual file
2023-03-21 20:37:38 -03:00
simbit18
0e04cd75f8 apps/system/dumpstack/Make.defs: fix style
fix error: Relative file path does not match actual file
2023-03-21 20:37:38 -03:00
Tiago Medicci Serrano
3a1893ba7e nxplayer: read file completely until 0 bytes are returned
Previously, if the read bytes were less than the requested, the
file was closed immediately. This behavior, however, does not
consider the fact that the read operation may be blocking when
no bytes are available at the moment. That is true for a named pipe
(FIFO), for instance. Thus, reading it again lets to the underlying
file system the decision of 1) blocking until bytes become
available or 2) return 0 immediately (the case for actual files) or
3) read available bytes.
2023-03-21 07:51:18 +09:00
Xiang Xiao
f3c104b99a Fix nxstyle warning
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-03-19 14:53:44 -06:00
Xiang Xiao
86080a110e apps: Remove the check of CONFIG_SERIAL_TERMIOS
If the code only change c_oflag, c_iflag and c_lflag, not c_cflag in termios.
Follow up the change from kernel: https://github.com/apache/nuttx/pull/8843

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-03-19 14:53:44 -06:00
anjiahao
369c354dc7 support ymodem protocal and sb rb application
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2023-03-17 12:17:14 -03:00
Huang Qi
0af64dc045 system/cle: Remove cle_getcursor()
Fix https://github.com/apache/nuttx/issues/8731, don't rely on the vt100 to report
the cursor position.

This avoid the implicit input (response of get cursor command) during the user inputs.

Notice: This assume that the nsh prompt is always shown at line start.

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-03-17 12:08:04 -03:00
Huang Qi
ea4437fc76 termios: Fix wrong ECHO flag
Follow https://github.com/apache/nuttx/pull/8800

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-03-17 03:22:08 +01:00
zhangyuan21
922f9932a6 apps: add <assert.h> header file
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-03-16 12:00:28 +01:00
Zhe Weng
098f5836f9 apps/system: Add tcpdump command
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-03-08 19:47:53 +08:00
simbit18
d325cf048a apps/system/uorb/Makefile: Fix mistakes in comments
Fix mistakes in comments
2023-03-07 21:45:12 +02:00
simbit18
a62f09136e apps/system/setlogmask/Make.defs: Fix mistakes in comments
Fix mistakes in comments
2023-03-07 21:45:12 +02:00
simbit18
7b8cc4e74b apps/system/nxrecorder/Make.defs: Fix mistakes in comments
Fix mistakes in comments
2023-03-07 21:45:12 +02:00
simbit18
ef908dd83b apps/system/cachespeed/Make.defs: Fix mistakes in comments
Fix mistakes in comments
2023-03-07 21:45:12 +02:00
Huang Qi
96cd66cf51 system/cu: Disable echo if it's enabled to avoid double input character
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-03-07 09:50:54 +01:00
Gustavo Henrique Nihei
f500c64962 Include missing headers throughout the repository
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2023-03-07 09:58:13 +08:00
Gustavo Henrique Nihei
da7d9e3737 system/nsh: Include missing "unistd.h" header
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2023-03-06 18:52:31 +02:00
Huang Qi
509e90aadc termcurses: Disable echo for serial driver
Since termcurse will control whole echo and vt100 command itself.

This fix the dupped character in VI's command mode and some display issue in editor mode, like:
```
~
~
~
~
:qq!!
```

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-03-05 14:37:45 +08:00
Huang Qi
fd8ce46060 system/cle: Don't echo extra '\n'
Before:
```
NuttShell (NSH) NuttX-12.0.0
nsh> free
/* Extra line here */
                   total       used       free    largest  nused  nfree
        Umem:   33154512      33584   33120928   33120928     96      1
```

After:
```
NuttShell (NSH) NuttX-12.0.0
nsh> free
                   total       used       free    largest  nused  nfree
        Umem:   33154512      33584   33120928   33120928     96      1
```

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-03-04 13:50:08 +08:00
Huang Qi
8160dd0d56 readline: Don't echo input except VT100 command
Let's echo character by serial driver,
this will imporve the experience of telnetd,
which will display input command and newline twice.
And also enhance the compatiblity with some third party
linux readline based application (like WAMR repl).

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-03-02 13:46:18 +08:00
yinshengkai
19ba886ec2 trace: remove SCHED_INSTRUMENTATION_HIRES
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-02-23 22:33:14 +08:00
Huang Qi
db22e07d07 stdio: Remove CONFIG_EOL_IS_XXX
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-02-23 17:21:19 +08:00
lilei19
41f60bd669 change strcpy to strlcpy
Change-Id: I8b9429a3c225a82842fce136bdb14b8b135066d3
Signed-off-by: lilei19 <lilei19@xiaomi.com>
2023-02-22 23:09:55 +08:00
Huang Qi
95f32fd018 nsh: Decouple with CONFIG_FILE_STREAM
Replace all fwrite/fread/fgets/... to write/read/...

Before:
```
       text    data     bss     dec     hex filename
 109827     601    6608  117036   1c92c nuttx/nuttx
```
    After:
```
       text    data     bss     dec     hex filename
108053     601    6608  115262   1c23e nuttx/nuttx
```
    After with CONFIG_FILE_STREAM disabled:
```
       text    data     bss     dec     hex filename
 105667     601    6608  112876   1b8ec nuttx/nuttx
```

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-02-22 13:47:41 +08:00
chao an
8ac809e680 system/libuv: check GCC version before set special flags
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-21 13:57:43 +08:00
chao an
f0ddb92be0 libuv: disable warning message of dangling-pointer
| In file included from libuv/src/uv-common.h:42,
|                  from libuv/src/uv-common.c:23:
| libuv/src/uv-common.c: In function 'uv_walk':
| libuv/src/queue.h:68:19: warning: storing the address of local variable 'queue' in '((void * (**)[2])MEM[(void *[2] * *)loop_13(D) + 8B])[1]' [-Wdangling-pointer=]
|    68 |     QUEUE_PREV(q) = (n);                                                      \
|       |                   ^
| libuv/src/queue.h:78:7: note: in expansion of macro 'QUEUE_SPLIT'
|    78 |       QUEUE_SPLIT(h, q, n);                                                   \
|       |       ^~~~~~~~~~~

Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-20 19:25:58 +08:00
chao an
cf4db3f62d drivers/note: fix build break by note rename change
Regression by:

| commit 4e6041a46c (HEAD, origin/master, origin/HEAD)
| Author: Xiang Xiao <xiaoxiang@xiaomi.com>
| Date:   Tue Feb 14 01:17:13 2023 +0800
|
|     system: Change DRIVER_NOTExxx to DRIVERS_NOTExxx
|
|     follow the kernel side change: https://github.com/apache/nuttx/pull/8531
|
|     Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>

Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-20 16:13:54 +08:00
Xiang Xiao
4e6041a46c system: Change DRIVER_NOTExxx to DRIVERS_NOTExxx
follow the kernel side change: https://github.com/apache/nuttx/pull/8531

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-02-20 14:30:57 +08:00
Peter Bee
ce84d5d7cd system/nxcamera: fix sscanf overflow
Signed-off-by: Peter Bee <bijunda1@xiaomi.com>
2023-02-16 19:00:29 +08:00
Huang Qi
1207977447 readline: Check the fd before echo
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-02-16 15:47:26 +08:00
Ville Juven
a38c23f557 system/cle.c: Fix configuration for CONFIG_EOL_IS_EITHER_CRLF=y
The old flagging was insufficient, only '\r' was accepted as a line terminator
if CONFIG_EOL_IS_EITHER_CRLF was set.

I noticed this regression after:
https://github.com/apache/nuttx/pull/8454
2023-02-14 00:19:24 +08:00
Xiang Xiao
df55bf5cea system/adb: Update to 305007e0e574e7cc2b8d706b0f5d8cc76675fc51
which contain the fix: https://github.com/spiriou/microADB/pull/34

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-02-11 22:00:05 +02:00
Nathan Hartman
8e77b79f78 Kconfig: Make indent consistent with TABS 2023-02-10 14:11:48 +08:00
chao an
42d34fcef3 build/Kconfig: fix warnings detected by kconfiglib
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-09 19:45:36 +08:00