Commit Graph

48011 Commits

Author SHA1 Message Date
Xiang Xiao f9836c94fb epoll.h: Add u64 field like Linux
https://man7.org/linux/man-pages/man2/epoll_wait.2.html

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-26 17:11:37 +02:00
Xiang Xiao 267e80a9e7 boards: Update Administrator tea result to 8Tv+Hbmr3pLVb5HHZgd26D
continue the change: https://github.com/apache/nuttx/pull/6843

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-26 17:11:07 +02:00
Petro Karashchenko af55d894f9 boards/spresense: remove BOARDIOC_SDCARD_SETNOTIFYCB ioctl
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 23:08:28 +08:00
Ville Juven 1c84fc9cd9 Revert "sched/release_tcb: Do not release stack for user processes here"
This reverts commit 1a67dc7c68.
2023-01-26 21:15:25 +08:00
Ville Juven 29eaf95ced Revert "sched/sched_releasetcb: Fix code style issue from prior patch"
This reverts commit 920956b20f.
2023-01-26 21:15:25 +08:00
Ville Juven 686b990a85 arch/ARCH_KERNEL_STACK: Fix signal handling with kernel stack
There were two issues with signal handling:
- With a kernel stack the "info" parameter was passed from kernel memory.
  This is fixed by making a stack frame to the user stack and copying it
  there.
- If the signal handler uses a system call, the kernel stack was completely
  and unconditionally destroyed, resulting in a crash in the user application

There is also no need to check ustkptr, it is always NULL. Why ? Because
signal delivery is deferred when a system call is being executed.
2023-01-26 20:41:42 +08:00
Xiang Xiao 37b8748f17 time.h: Add CLOCK_PROCESS_CPUTIME_ID and CLOCK_THREAD_CPUTIME_ID definition
see the spec here:
https://pubs.opengroup.org/onlinepubs/000095399/functions/clock_getres.html

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-26 13:00:23 +02:00
duduita 2fc1192019 Add initial support to Meadow F7Micro board 2023-01-26 18:05:21 +08:00
Xiang Xiao 819fbd22cc sched: Implement tkill/tgkill
https://linux.die.net/man/2/tgkill

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-26 08:11:56 +02:00
Xiang Xiao 34ac8b2e07 signal.h: Don't include pthread.h to avoid the mutual reference
let's use pthread_attr_s directly

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-26 08:11:56 +02:00
Petro Karashchenko 2c972bd402 fs/shm: update pointer arithmetic logic
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:26:09 +08:00
Petro Karashchenko d35d8b4a12 fs/shm: use ERROR instead of -1
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:26:09 +08:00
Petro Karashchenko e5dbc3328c sched/misc/assert: remove extra indentations
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:26:09 +08:00
Petro Karashchenko a58e73add8 arch/arm/tiva: simplify TIVA_CAN option usage
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:26:09 +08:00
Petro Karashchenko bd7cb522a1 nuttx: use TABs instead of spaces in Kconfig files
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:26:09 +08:00
Petro Karashchenko c4cf1eeb2b arch/xtensa/esp32s2: switch from semaphore to mutex for exclusive access
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:24:05 +08:00
Petro Karashchenko c415ce518f arch/xtensa/esp32: style fixes in SPI driver
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:24:05 +08:00
Petro Karashchenko e3a8e1e3ef drivers/mtd/mtd_config: switch from semaphore to mutex for exclusive access
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:24:05 +08:00
Petro Karashchenko 6e3cb04531 drivers/sensors/msa301: switch from semaphore to mutex for exclusive access
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:24:05 +08:00
Petro Karashchenko a8f4d8447f wireless/ieee802154: rename label pointed to exit with mutex held
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:24:05 +08:00
Petro Karashchenko f952b8456c assert: switch from ASSERT(0/false) to PANIC
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:15:34 +08:00
Xiang Xiao 1280a2a8f9 Launch the initial task through task_spawn instead of nxtask_create
to share the code with the code path of posix_spawn

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-25 23:34:52 +02:00
Xiang Xiao 926e296d48 boards/jupiter-nano: Remove sam_ostest.c
since fpu special handling is done in arch common code now

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-25 23:01:20 +02:00
Michael Jung eaea60a575 armv8-m: Fix pthread_start syscall
The 'arg' parameter is in R3, not in R2.

Signed-off-by: Michael Jung <michael.jung@secore.ly>
2023-01-26 04:02:19 +08:00
Xiang Xiao 99e89809d7 board: Pass the assertion expression to board_crashdump too
continue the follow work:
commit 43e7b13697
Author: Xiang Xiao <xiaoxiang@xiaomi.com>
Date:   Sun Jan 22 19:31:32 2023 +0800

    assert: Log the assertion expression in case of fail

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-25 16:00:48 -03:00
Petro Karashchenko be10056702 arch/arm/samv7: fix issue when AFEC1 driver failed to open second time
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 01:26:41 +08:00
Petro Karashchenko 5f55290e41 sched/pthread: restore C89 compliance in pthread_create
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 01:26:11 +08:00
Xiang Xiao c05cdd6598 libc: Move on_exit and __cxa_atexit in lib_atexit.c
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-25 14:31:37 +02:00
Xiang Xiao 5333c30d45 libc: abort should always call exit not pthread_exit
since pthread_exit just exit the calling thread not the whole process

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-25 14:31:37 +02:00
Xiang Xiao bcd1ebf260 libc: Implement quick_exit and at_quick_exit
Defined by c11:
https://en.cppreference.com/w/c/program/quick_exit
https://en.cppreference.com/w/c/program/at_quick_exit

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-25 14:31:37 +02:00
Xiang Xiao d7ee492fc4 board/arch: Remove FAR decorator
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-25 13:05:07 +02:00
Alin Jerpelea d23bd35dd3 AUTHORS: add Heath Petersen
This message acknowledges receipt of your ICLA, which has been filed in the Apache Software Foundation records.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2023-01-25 11:14:30 +02:00
Stuart Ianna 34fdc3da0d litex: Allow custom peripheral memory mapping and IRQ. 2023-01-25 14:11:06 +08:00
Xiang Xiao 92d23e7d6d esp32-devkitc/coremark: Fix ci break
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-25 03:50:21 +08:00
Xiang Xiao 299de87e68 tiva/lm3s6965-ek: Remove CONFIG_DEBUG_ASSERTIONS from qemu-protected
to save the code size

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 15:00:19 -03:00
Xiang Xiao 43e7b13697 assert: Log the assertion expression in case of fail
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 15:00:19 -03:00
Ville Juven 9b88f8ea5c riscv/riscv_exception.c: Print the EPC value always
The value printed by assert() cannot always be trusted to be correct,
as it relies on the stack / stack pointer not being corrupt.

The CPU register always points to the faulting instruction so print it
out in the exception handler.
2023-01-25 00:55:07 +08:00
Xiang Xiao 8bf693b362 libc/pthread: Implement pthread_condattr_[set|get]pshared
https://pubs.opengroup.org/onlinepubs/009696799/functions/pthread_condattr_getpshared.html

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 13:53:02 -03:00
Xiang Xiao c11cd7f103 libc/pthread: Implement pthread_attr_[set|get]stackaddr
https://pubs.opengroup.org/onlinepubs/009696799/functions/pthread_attr_getstackaddr.html

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 13:53:02 -03:00
Xiang Xiao 36b74bab02 libc/pthread: Implement pthread_rwlockattr API
https://pubs.opengroup.org/onlinepubs/9699919799/functions/pthread_rwlockattr_getpshared.html

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 13:53:02 -03:00
Xiang Xiao 679544cd32 Documentation: Remove the supported function from the unsupported list
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 13:53:02 -03:00
Stuart Ianna f49c20d28f litex: System clock frequency selectable from Kconfig. 2023-01-24 08:20:16 +01:00
Xiang Xiao e166360e8d sched: Map both NZERO and PTHREAD_DEFAULT_PRIORITY to SCHED_PRIORITY_DEFAULT
to unify the default thread priority

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 08:06:42 +01:00
Xiang Xiao 55565a6099 pthread: Implement pthread_gettid_np
which is provided by bionic libc:
https://android.googlesource.com/platform/bionic/+/master/libc/include/pthread.h#172

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 08:05:16 +01:00
Gustavo Henrique Nihei 1b94806b35 boards/esp32: Remove duplicated MCUboot-related defconfigs
These are basically the same from the esp32-devkitc board. As the
defconfigs do not make use of any board-specific peripheral, there
is no need to duplicate them in every ESP32 board.

Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2023-01-24 08:44:22 +09:00
Gustavo Henrique Nihei e77e12e145 espressif: Stabilize MCUboot support on Espressif chips
MCUboot support is no longer behind EXPERIMENTAL for the following
chips:
- ESP32
- ESP32-S2
- ESP32-S3
- ESP32-C3

Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2023-01-24 08:44:22 +09:00
Xiang Xiao d3525ec637 tools/ci: Enable stm32u5, stm32wb and stm32wl5
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 08:40:50 +09:00
Lucas Saavedra Vaz d3a6de2439 boards/esp32-devkitc: Add coremark config 2023-01-24 06:47:34 +08:00
David Sidrane 15462f3e7a s32k1xx:serial Do not use TC use TDRE & TIE 2023-01-24 06:47:21 +08:00
raiden00pl aa7d4b40c1 stm32/foc: move the warning in the right place - should be in stm32f7 2023-01-24 00:44:41 +08:00