Commit Graph

51101 Commits

Author SHA1 Message Date
pengyiqiang
76c214bd00 tools/showstack: add configurable rank parameters
Signed-off-by: pengyiqiang <pengyiqiang@xiaomi.com>
2023-09-12 16:23:20 +08:00
Tiago Medicci Serrano
1f1c793fd5 boards/esp32s3-devkit: Add board GPIO support
The board-level GPIO support is different from the already existing
button and LEDC support because it enable us to register the GPIO
pins as devices in `/dev/gpioX`. Some applications are able to use
this interface to read and write the GPIO pins.

Documentation was added regarding its usage. Please check
`Documentation/platforms/xtensa/esp32s3/boards/esp32s3-devkit/index.rst`
2023-09-12 16:22:15 +08:00
Xiang Xiao
c27b470d39 Fix error: implicit declaration of function 'arc4random'; did you mean 'random'? [-Werror=implicit-function-declaration]
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-12 10:02:50 +08:00
Xiang Xiao
78728fc5eb Fix error: spi/qspi_flash.c:576:45: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-12 10:02:50 +08:00
Xiang Xiao
d4fd9f53cd Fix error: arch/sim/src/sim/posix/sim_alsa.c:290:18: error: 'flags' undeclared
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-12 10:02:50 +08:00
makejian
4fef475825 sim/crypto: support MBEDTLS_MD5_ALT config
Signed-off-by: makejian <makejian@xiaomi.com>
2023-09-12 10:01:28 +08:00
dongjiuzhu1
36e3d32740 mm/heap: add coloration after free to detect use after free issue
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-09-11 15:28:34 -04:00
Philippe Leduc
a7d0b6c120 Do not let CMake check the compiler with en executable as the entry point is not always main() 2023-09-12 01:17:30 +08:00
daniellizewski
a75b3bad15 Fixed typo in CRC define 2023-09-12 00:41:59 +08:00
Petro Karashchenko
a003a7ea36 arch/xtensa/esp32s3: add UART RS485 support
This commit adds support of RS485 support in ESP32-S3 serial driver

Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-09-11 23:20:49 +08:00
Pavel Pisa
b9472129c8 arch/arm/samv7: fix typos in quadrature encoder and timer drivers
The typo s/.timid/.tcid prevents to compile NuttX with
quadrature encoder configured for timer1 (CONFIG_SAMV7_TC1_QE)
and s/SAM_TC789_BASE/SAM_TC678_BASE prevented use of the
of the timer 2.

Signed-off-by: Pavel Pisa <ppisa@pikron.com>
2023-09-11 23:11:43 +08:00
xuxin19
e5ee8f7470 Fix error: procfs/fs_procfscritmon.c:184:10: error: variable 'remaining' set but not used [-Werror,-Wunused-but-set-variable]
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-09-11 20:34:46 +08:00
yintao
9e43a4d31c sim: To avoid system calls being interrupted when use host api
Signed-off-by: yintao <yintao@xiaomi.com>
2023-09-11 20:33:49 +08:00
dongjiuzhu1
6367f2469c fs/vfs: fix dup issue for eventfd/signalfd/timerfd
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-09-11 19:57:34 +08:00
xucheng5
30bb3086be socketcan/recv : fixed recv filter not work in special case
can recv filter doesn't work when there is any CAN data already
buffered in a read-ahead buffer

Signed-off-by: xucheng5 <xucheng5@xiaomi.com>
2023-09-11 19:29:47 +08:00
Xiang Xiao
08b151a681 Fix error: mtd/smart.c:2800:12: error: variable 'mincount' set but not used [-Werror,-Wunused-but-set-variable]
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-11 17:38:45 +08:00
Stuart Ianna
531e5c2011 mm/shm/shmget: Zero allocated shared memory pages when created.
Modification based on opengroup's description for shmget: "When the shared memory segment is created, it shall be initialized with all zero values."

Link to documentation page for shmget: https://pubs.opengroup.org/onlinepubs/9699919799/
2023-09-11 16:38:37 +08:00
dependabot[bot]
890dd87a4a build(deps): bump actions/checkout from 3 to 4
Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-09-11 14:28:40 +08:00
Xiang Xiao
4f5a177eef board/sim/crypto: Enable CONFIG_CRYPTO_SW_AES
to fix the following linker error:
/usr/bin/ld: nuttx.rel: in function `aes_encrypt_xform':
/github/workspace/sources/nuttx/crypto/xform.c:509: undefined reference to `aes_encrypt'
/usr/bin/ld: nuttx.rel: in function `aes_decrypt_xform':
/github/workspace/sources/nuttx/crypto/xform.c:514: undefined reference to `aes_decrypt'
/usr/bin/ld: nuttx.rel: in function `aes_setkey_xform':
/github/workspace/sources/nuttx/crypto/xform.c:519: undefined reference to `aes_setkey'
/usr/bin/ld: nuttx.rel: in function `aes_ctr_crypt':
/github/workspace/sources/nuttx/crypto/xform.c:566: undefined reference to `aes_encrypt'
/usr/bin/ld: nuttx.rel: in function `aes_ctr_setkey':
/github/workspace/sources/nuttx/crypto/xform.c:585: undefined reference to `aes_setkey'
/usr/bin/ld: nuttx.rel: in function `aes_ofb_encrypt':
/github/workspace/sources/nuttx/crypto/xform.c:694: undefined reference to `aes_encrypt'
/usr/bin/ld: nuttx.rel: in function `aes_ofb_setkey':
/github/workspace/sources/nuttx/crypto/xform.c:706: undefined reference to `aes_setkey'
/usr/bin/ld: nuttx.rel: in function `aes_cfb8_encrypt':
/github/workspace/sources/nuttx/crypto/xform.c:733: undefined reference to `aes_encrypt'
/usr/bin/ld: nuttx.rel: in function `aes_cfb8_decrypt':
/github/workspace/sources/nuttx/crypto/xform.c:751: undefined reference to `aes_encrypt'
/usr/bin/ld: nuttx.rel: in function `aes_cfb128_encrypt':
/github/workspace/sources/nuttx/crypto/xform.c:765: undefined reference to `aes_encrypt'
/usr/bin/ld: nuttx.rel: in function `aes_cfb128_decrypt':
/github/workspace/sources/nuttx/crypto/xform.c:781: undefined reference to `aes_encrypt'
/usr/bin/ld: nuttx.rel: in function `aes_gmac_setkey':
/github/workspace/sources/nuttx/crypto/gmac.c:135: undefined reference to `aes_setkey'
/usr/bin/ld: /github/workspace/sources/nuttx/crypto/gmac.c:143: undefined reference to `aes_encrypt'
/usr/bin/ld: nuttx.rel: in function `aes_gmac_final':
/github/workspace/sources/nuttx/crypto/gmac.c:195: undefined reference to `aes_encrypt'

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-11 14:17:07 +08:00
Xiang Xiao
745dc4299f mmcsd: Rename mmc_rpmb_frame_s to rpmb_frame
align with mmc-utils definition:
https://git.kernel.org/pub/scm/utils/mmc/mmc-utils.git/tree/mmc_cmds.c#n2085

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-10 23:10:42 +08:00
hujun5
70a67099b3 timer/trustzone: set CPU frequency in tee environment
In an implementation that supports the ARM Security Extensions, only
software executing in a Secure PL1 mode can write to CNTFRQ

Signed-off-by: hujun5 <hujun5@xiaomi.com>
2023-09-10 23:10:06 +08:00
liaoao
d63e3962bf qemu:fdt:add device tree support for goldfish arm/arm64
Signed-off-by: liaoao <liaoao@xiaomi.com>
2023-09-10 23:10:06 +08:00
wangming9
c8a4bdf21a arch/arm: GoldFish Platform support
Summary:
    Adding virtual evaluate platform GoldFish. Which is based on
    Android Goldfish Emulator, it's a ARM virt board but Android
    enhance it with more featue.
    The patch set goldfish as a arm chip.

Signed-off-by: wangming9 <wangming9@xiaomi.com>
2023-09-10 23:10:06 +08:00
liaoao
78c942a05a devicetree: add devicetree support for arm/arm64
Signed-off-by: liaoao <liaoao@xiaomi.com>
2023-09-10 14:28:41 +03:00
hujun5
90fba56d2e timer/trustzone: set CPU frequency in tee environment
In an implementation that supports the ARM Security Extensions, only
software executing in a Secure PL1 mode can write to CNTFRQ

Signed-off-by: hujun5 <hujun5@xiaomi.com>
2023-09-10 14:28:41 +03:00
zhengshaobo1
09a81017b8 To solve the problem of unordered setting of div & mux, after solving the problem, the frequency will be set to mux first, and then div
Signed-off-by: zhengshaobo1 <zhengshaobo1@xiaomi.com>
2023-09-10 13:36:16 +03:00
zhengshaobo1
f6ba2970e0 Solve the risk of dividing by 0 when setting frequency points
Signed-off-by: zhengshaobo1 <zhengshaobo1@xiaomi.com>
2023-09-10 13:36:16 +03:00
Xiang Xiao
dec99c0c97 crypto: Remove CRYPTO_BLAKE2S Kconfig
since it's more simple to let linker remove the unused functions from the final image

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-10 18:27:03 +08:00
Stanley
56286a72c6 PAGESIZE and PAGEMASK seems as common macro 2023-09-10 18:18:15 +08:00
wanggang26
83ac6c7c43 mmc: change rpmb operation type define style
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2023-09-09 18:16:23 +03:00
wangming9
61a38ca680 libs/libxx/libcxx: Fix compilation warnings
Summary
Workaround the following warning with "GCC 12"
CXX:  libcxxabi/src/cxa_demangle.cpp In file included from libcxx/src/locale.cpp:15:
In member function 'std::__1::_EnableIf<std::__1::__is_cpp17_forward_iterator<_ForwardIterator>::value> std::__1::basic_string<_CharT, _Traits, _Allocator>::__init(_ForwardIterator, _ForwardIterator) [with _ForwardIterator = const wchar_t*; _CharT = wchar_t; _Traits = std::__1::char_traits<wchar_t>; _Allocator = std::__1::allocator<wchar_t>]',    inlined from 'std::__1::basic_string<_CharT, _Traits, _Allocator>::basic_string(_InputIterator, _InputIterator) [with _InputIterator = const wchar_t*; <template-parameter-2-2> = void; _CharT = wchar_t; _Traits = std::__1::char_traits<wchar_t>; _Allocator = std::__1::allocator<wchar_t>]' at include/libcxx/string:2182:11,
    inlined from 'virtual int std::__1::collate_byname<wchar_t>::do_compare(const char_type*, const char_type*, const char_type*, const char_type*) const' at libcxx/src/locale.cpp:764:33:
include/libcxx/string:2156:35: warning: 'lhs' may be used uninitialized [-Wmaybe-uninitialized]
 2156 |         this->__throw_length_error();
      |         ~~~~~~~~~~~~~~~~~~~~~~~~~~^~

include/libcxx/new:237:24: warning: argument 1 value '18446744073709551599' exceeds maximum object size 9223372036854775807 [-Walloc-size-larger-than=]
  237 |   return ::operator new(__args...);
      |          ~~~~~~~~~~~~~~^~~~~~~~~~~

Signed-off-by: wangming9 <wangming9@xiaomi.com>
2023-09-09 17:08:23 +03:00
wangming9
f05e72324c drivers/video: fix build error on CONFIG_DEBUG_OPTLEVEL="-O3"
Summary
The following compilation error occurs after configuring CONFIG_DEBUG_OPTLEVEL="-O3"
CC:  ping.c video/video.c: In function 'video_ioctl':
video/video.c:2347:22: error: 'control.size' may be used uninitialized [-Werror=maybe-uninitialized]
 2347 |               control->size,
      |                      ^~
video/video.c:2273:28: note: 'control' declared here
 2273 |   struct v4l2_ext_control  control;
      |                            ^~~~~~~

Signed-off-by: wangming9 <wangming9@xiaomi.com>
2023-09-09 17:08:23 +03:00
wangming9
21c30f80af net/local: fix build error on CONFIG_DEBUG_OPTLEVEL="-O3"
Summary
The following compilation error occurs after configuring CONFIG_DEBUG_OPTLEVEL="-O3"
CC:  local/local_fifo.c In file included from local/local_fifo.c:25:
In function 'local_format_name',
    inlined from 'local_cs_name' at local/local_fifo.c:101:3,
    inlined from 'local_create_fifos' at local/local_fifo.c:431:3:
local/local_fifo.c:84:16: error: '%x' directive output may be truncated writing between 1 and 8 bytes into a region of size between 5 and 112 [-Werror=format-truncation=]
   84 |                CONFIG_NET_LOCAL_VFS_PATH "/%s%s%" PRIx32,
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: wangming9 <wangming9@xiaomi.com>
2023-09-09 17:08:23 +03:00
wangming9
6265596cd0 libs/libc: Modify the Kconfig error description
Signed-off-by: wangming9 <wangming9@xiaomi.com>
2023-09-09 17:08:23 +03:00
hujun5
d9cbf84d86 arm/oneshot: rm sched_[un]lock
Signed-off-by: hujun5 <hujun5@xiaomi.com>
2023-09-09 20:26:32 +08:00
Andre Heinemans
329e050c30 Added NXP SE05x support (secure element) 2023-09-09 15:54:08 +08:00
zhangyuan21
59f7fe11a3 usbdev: adb use fs device for ep process
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-09-09 15:52:08 +08:00
zhangyuan21
1f6d9bbd17 usbdev: add usbdev fs device for usb char device
Add usb_fs driver so that userspace can directly transfer USB packets
through the EP node. ADB, Fastboot, MTP will use usb_fs, these class
driver only need to provide the descriptors and register the usb_fs device.

Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>

Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-09-09 15:52:08 +08:00
hujun5
3f8f3340d1 pic32mx: sched_lock should replace with enter_critical_secion
Signed-off-by: hujun5 <hujun5@xiaomi.com>
2023-09-09 10:26:03 +08:00
xuxin19
d93d377257 cmake:complete missing changes during cmake reforming for sched
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-09-08 21:20:16 +03:00
xuxin19
5b6488f09f cmake:complete missing changes during cmake reforming for mm
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-09-08 21:20:16 +03:00
xuxin19
b1cc5b50b1 cmake:complete missing changes during cmake reforming for fs
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-09-08 21:20:16 +03:00
xucheng5
b756a7c3a9 socketcan : support error frame filter
add error mask for CAN_RAW_ERR_FILTER

Signed-off-by: xucheng5 <xucheng5@xiaomi.com>
2023-09-08 21:14:09 +03:00
haopengxiang
ef3f807f89 tools/mkdeps: increase MAX_BUFFER/MAX_EXPAND/MAX_SHQUOTE to 16384
solve CFLAG is too long when building in deep path

Signed-off-by: haopengxiang <haopengxiang@xiaomi.com>
2023-09-09 00:47:59 +08:00
SPRESENSE
60364d7c72 drivers/sensors/bmi270: Enable to select config memory
Allow to transfer the BMI270 configuration data directly, and
provide an option to use the heap memory if it cannot transfer
directly.
2023-09-09 00:46:24 +08:00
SPRESENSE
a015aa4fca boards: cxd56xx: Add board-specific driver for bmi270 2023-09-09 00:46:24 +08:00
raiden00pl
e26dfec157 cmake: add support for sensors/bmi270 2023-09-09 00:43:09 +08:00
raiden00pl
e83fd87f9c driver/sensors/: BMI270 fix compilation if sensor works in SPI mode 2023-09-09 00:43:09 +08:00
guoshichao
4645004d49 nuttx/board/sim/posix_test: add defconfig for ltp openposix testsuite
1. the defconfig is based on nuttx/boards/sim/sim/configs/nsh/defconfig
2. make the option enabled by default that needed by open posix
testsuite, such as PTHREAD_SPINLOCK, FS_AIO, TESTING_LTP etc.

Signed-off-by: guoshichao <guoshichao@xiaomi.com>
2023-09-09 00:39:59 +08:00
zhangjun21
a5f133a15f MLD: add byte order conversion for ipv6 address printing
Signed-off-by: zhangjun21 <zhangjun21@xiaomi.com>
2023-09-09 00:23:35 +08:00