shizhenghui
ed1ad1be65
Add v4l2m2m & sim decoder
...
Signed-off-by: shizhenghui <shizhenghui@xiaomi.com>
2024-05-15 22:03:18 +08:00
Alan Carvalho de Assis
056eb46d69
nxstyle: Ignore long line for file path at line 2
...
This patch fixes the issue reported by PR #12345 where the file
path existent in the second line of each source file on NuttX.
Sometimes the path could be too long and could raise a nxstyle
issue during the CI test.
Signed-off-by: Alan C. Assis <acassis@gmail.com>
2024-05-15 21:53:30 +08:00
Xiang Xiao
d680ba47c4
Move video_controls.h from include/nuttx/video to include/sys
...
The video_controls.h is a public header file, and it is used by
videoio.h. So it should be moved to the include/sys directory.
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2024-03-21 19:23:53 +08:00
chao an
09aede87ee
tools/nxstyle: add infineon prefix into ignore list
...
add infineon prefix into ignore list to avoid nxstyle warning
Signed-off-by: chao an <anchao@lixiang.com>
2024-02-21 21:39:19 -08:00
yangjian11
b3b8ec35a6
tools/nxstyle: can use ',' in the string when declaring it
...
Signed-off-by: yangjian11 <yangjian11@xiaomi.com>
2024-01-26 06:12:48 -08:00
simbit18
c494ce4a96
Update kconfig2html.c
...
Fix nuttx coding style
2023-12-14 20:02:52 -08:00
anjiahao
a2c5cb729a
fs:support zipfs,can mount zipfile
...
we can mount a zipfile in nuttx use mount command like this:
mount -t zipfs -o /data/test.zip /zip
The zipfs is a read only file system,The advantage is that it
does not occupy additional space when reading the decompressed file.
When used, reading and decompression operations are simultaneous.
The known disadvantage is that when using seek to read forward,
it will reopen and cause slow speed problems.
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2023-09-27 01:06:04 +08:00
chao an
5026a96cfa
nxstyle: cleanup UTF-8 Unicode to ASCII
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-09-18 11:54:17 -04:00
chao an
664927c86e
mm/alloc: remove all unnecessary cast for alloc
...
Fix the minor style issue and remove unnecessary cast
Signed-off-by: chao an <anchao@xiaomi.com>
2023-08-30 14:34:20 +08:00
chao an
50cf3d8577
tools/nxstyle: add "_NSGetExecutablePath" into ignore list
...
sim/posix/sim_hostmisc.c:128:6: error: Mixed case identifier found
Signed-off-by: chao an <anchao@xiaomi.com>
2023-05-16 17:05:42 +08:00
chao an
c87da0d115
tools/nxstyle: add white files list to allow assembly headers to pass ci checks
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-04-28 09:51:52 +08:00
yanghuatao
826dd87f30
libm/newlib: add newlib/libm support
...
Signed-off-by: yanghuatao <yanghuatao@xiaomi.com>
2023-04-24 10:32:53 +08:00
chao an
743d13c2b0
tools/nxstyle: skip mixed case check for particular headers
...
Add header keywords into whitelist, skip the warning if the
particular headers will contain the functions with mixed case
Signed-off-by: chao an <anchao@xiaomi.com>
2023-04-11 11:12:32 +03:00
raiden00pl
c4c2b14623
tools/nxstyle: add 'IRQn_Type' to whitelists
2023-03-05 17:56:37 +02:00
zhangyuan21
0af63cfc48
sim/usb: add sim usb host
...
signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-03-03 14:31:30 -03:00
zhangyuan21
c61c694a77
sim/usb: add sim usb device
...
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-03-03 14:31:30 -03:00
Takeyoshi Kikuchi
b901837f52
tools: nxstyle: add "NimMain" to whitelists.
...
Signed-off-by: Takeyoshi Kikuchi <kikuchi@centurysys.co.jp>
2023-02-26 19:11:53 +08:00
wangbowen6
0f5b66c335
nxstyle: add "CMUnitTest" to nxstyle white list
...
https://github.com/apache/nuttx-apps/pull/1575 need this
Signed-off-by: wangbowen6 <wangbowen6@xiaomi.com>
2023-02-17 22:57:58 +08:00
Xiang Xiao
79d02c0e29
arch/sim: Unify the host soruce file naming
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-11-22 19:37:48 +01:00
zhangyuan21
f1837e7e96
tools/nxstyle: add more white list for sim arch
2022-11-22 16:27:56 +08:00
Xiang Xiao
f905563cc9
tools/nxstyle: Add kbps to the while suffix list
...
and correct offset by 1 error
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-05-15 13:55:58 +03:00
Xiang Xiao
317cc6c174
tools/nxstyle: Add the suffix white list
...
and initialize it to "kHz", "Mbps", and "us"
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-05-13 16:39:16 +03:00
Xiang Xiao
59db30fd59
tools/nxstyle: Add __sFILE_fake(defined by newlib) to the white list
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-05-06 14:43:57 -03:00
Xiang Xiao
fa42ebace4
tools/nxstyle: Order g_white_prefix by alphanum
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-03-20 20:35:08 +02:00
Michael Mogenson
2c450be9e8
nxstyle: ignore mixed-case identifiers for Lua types
2022-03-20 23:32:20 +08:00
Michael Jung
0a37744826
Fix jlink-nuttx build with GCC 10.2
...
The packed-attribute on the tcb_info_s type was misplaced, which caused
incompatible memory layout between host and target. According to
current GCC documentation:
> You may specify type attributes in an enum, struct or union type
> declaration or definition by placing them immediately after the struct,
> union or enum keyword. You can also place them just past the closing
> curly brace of the definition, but this is less preferred because
> logically the type should be fully defined at the closing brace.
I also added jlink-nuttx.so to the .gitignore list and updated nxstyle
to ignore the camel case function names required by JLinkGDBServer.
Signed-off-by: Michael Jung <mijung@gmx.net>
2022-02-15 13:48:52 +01:00
Xiang Xiao
7dfa768552
tools/nxstyle: add Segger RTT prototype name into white list
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-02-01 11:26:46 +01:00
chao.an
3fc18d50b8
tools/nxstyle: add Segger System View prototype name into white list
...
Reference:
https: //github.com/SEGGERMicro/SystemView/blob/master/SYSVIEW/SEGGER_SYSVIEW.h
Signed-off-by: chao.an <anchao@xiaomi.com>
2022-01-29 17:26:04 +08:00
Alexander Lunev
c45534f41b
tools/nxstyle: fixed "Mixed case identifier found" errors related to sim/wpcap
2022-01-27 10:37:32 +08:00
zhouliang3
1f53a058fa
nuttx:Change fs strncpy to strlcpy to avoid losing'\0'
...
Signed-off-by: zhouliang3 <zhouliang3@xiaomi.com>
2021-12-30 18:06:00 +08:00
Petro Karashchenko
3ccb657dc2
nuttx: remove space befone newline in logs
...
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2021-12-27 21:01:19 -06:00
Petro Karashchenko
298c372afa
tools/nxstyle: fix nxstyle check for pointer to function types
...
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2021-11-26 14:55:34 -03:00
chenwei23
39cdd99d77
mm: Support the kernel address sanitizer
...
Signed-off-by: chenwei23 <chenwei23@xiaomi.com>
2021-11-02 13:32:47 -03:00
liucheng5
d1ebdf6e65
fix: nxstyle: fix a bug after "'\'"
...
When nxstyle.c detects a "\'", it seeks the other "\'", records the index as "endndx", then skip the "'x'". But it makes the index "n" as "endndx+1".Then it comes to the "n++" in "for()". So the character after "'x'" will be skipped, causing some errors.
For example, "{"devid", no_argument, NULL, 'i'},", the "}" will be skipped, causing a lot of error reports.
Now it's fixed.
Signed-off-by: liucheng5 <liucheng5@xiaomi.com>
2021-10-28 09:59:36 -05:00
liucheng5
b42d2a7284
fix: nxstyle: detect --,->,++ not next to operand
...
The nxstyle check tool can't recongnize the style error that --, -> or ++ is not next to the operand. For example, "idx ++;", "p ->member" or "(-- idx)", which is in incorrect style, is not recongnized. This patch add detection for these cases.
Signed-off-by: liucheng5 <liucheng5@xiaomi.com>
2021-09-19 11:06:05 -04:00
yangjiukui
014d6d026c
tools/nxstyle: Fix the check tool incorrectly reported no alignment.
...
The nxstyle check tool recognizes the division operator as
a comment. Check the following content to determine whether
it is a comment.
Change-Id: Id07c6668489895b45a1042794bc3acca66cd3c47
Signed-off-by: yangjiukui <yangjiukui@xiaomi.com>
2021-09-08 09:45:06 +08:00
Gustavo Henrique Nihei
f547883747
tools/nxstyle: Extend check to any URI scheme
2021-05-07 19:38:10 -07:00
Gustavo Henrique Nihei
886009f15f
tools/nxstyle: Add _Atomic keyword to whitelisted words
2021-05-06 06:48:59 -07:00
chao.an
692856a626
tools/nxstyle: rename exception _Unwind_Ptr to _Unwind to support fuzzy match
...
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-04-19 04:45:04 -07:00
Alin Jerpelea
f878390c6d
tools: nxstyle: add exception for X11 keysymdef
...
Add exception for XK_* Mixed Case defined by X11 keysymdef.h
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-04-03 11:56:35 -05:00
Alin Jerpelea
c7c3683845
tools: nxstyle: add Mixed case exceptions for nfs
...
add exceptions for nfs to avoid future false warnings
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-04-03 09:37:06 -05:00
Abdelatif Guettouche
aaedc99612
nxstyle: Fix typos in reported errors.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-04-01 07:06:49 -05:00
Alin Jerpelea
2a03582541
nxstyle: add Mixed Case exceptions
...
Add _Far and _Erom to the mixed case exceptions
Ref:
nuttx/compiler.h
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-03-31 09:17:54 -07:00
Alin Jerpelea
122f59b761
tools; nxstyle: add exception for ascii.h definitions
...
The following definitions are added as exceptions
ASCII_a -> ASCII_z
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-03-20 19:22:58 -07:00
Gustavo Henrique Nihei
95c8c99a3f
tools/nxstyle: Verify relative path in the file header
2021-03-06 20:17:23 -08:00
Alin Jerpelea
796ef13b20
tools: nxstyle: add L_tmpnam/P_tmpdir exceptions
...
Those exceptions are defined in
https://pubs.opengroup.org/onlinepubs/9699919799/functions/tempnam.html
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-03-03 18:52:53 -08:00
YAMAMOTO Takashi
954115e097
nxstyle: Add more inttypes.h stuff to the whitelist
2020-11-05 15:19:31 +01:00
Xiang Xiao
cfc58d1913
nxstyle: Add some unwind name to the white list
...
we can't change the case because it is defined by ARM
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-07-11 10:34:22 -07:00
Xiang Xiao
b2f3a4b5f9
tools/nxstyle: Support the white list
...
and add _Exit to the white list
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-06-28 21:07:57 +01:00
Xiang Xiao
dde25b0f80
tools/nxstyle: Fix AddressSanitizer error
...
=================================================================
==2474==ERROR: AddressSanitizer: stack-buffer-underflow on address 0x7fffb7e59b5f at pc 0x561fffec79f6 bp 0x7fffb7e59ac0 sp 0x7fffb7e59ab0
READ of size 1 at 0x7fffb7e59b5f thread T0
#0 0x561fffec79f5 in block_comment_width /home/xiaoxiang/mirtos/nuttx/tools/nxstyle.c:355
Address 0x7fffb7e59b5f is located in stack of thread T0 at offset 31 in frame
#0 0x561fffec7b90 in get_line_width /home/xiaoxiang/mirtos/nuttx/tools/nxstyle.c:419
This frame has 1 object(s):
[32, 544) 'line' (line 420) <== Memory access at offset 31 underflows this variable
HINT: this may be a false positive if your program uses some custom stack unwind mechanism, swapcontext or vfork
(longjmp and C++ exceptions *are* supported)
SUMMARY: AddressSanitizer: stack-buffer-underflow /home/xiaoxiang/mirtos/nuttx/tools/nxstyle.c:355 in block_comment_width
Shadow bytes around the buggy address:
0x100076fc3310: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0x100076fc3320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0x100076fc3330: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0x100076fc3340: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0x100076fc3350: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x100076fc3360: 00 00 00 00 00 00 00 00 f1 f1 f1[f1]00 00 00 00
0x100076fc3370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0x100076fc3380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0x100076fc3390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0x100076fc33a0: 00 00 00 00 00 00 00 00 00 00 00 00 f3 f3 f3 f3
0x100076fc33b0: f3 f3 f3 f3 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
Addressable: 00
Partially addressable: 01 02 03 04 05 06 07
Heap left redzone: fa
Freed heap region: fd
Stack left redzone: f1
Stack mid redzone: f2
Stack right redzone: f3
Stack after return: f5
Stack use after scope: f8
Global redzone: f9
Global init order: f6
Poisoned by user: f7
Container overflow: fc
Array cookie: ac
Intra object redzone: bb
ASan internal: fe
Left alloca redzone: ca
Right alloca redzone: cb
Shadow gap: cc
==2474==ABORTING
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ie7dee3cdfdbbd04ea9cdb58e227afef07073cecd
2020-06-16 09:56:22 -06:00