Commit Graph

44118 Commits

Author SHA1 Message Date
Xiang Xiao
d29f3bd21c arm/rtl8720c: Remove the unused Toolchain.defs
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-02-20 04:15:34 +01:00
Piet
bb3d8c35e4 ci: add Rust compiler suite 2022-02-20 10:30:30 +08:00
Oki Minabe
e9bd959425 add new line to /proc/*/loadavg snprintf format. 2022-02-19 22:35:27 +01:00
Oki Minabe
484eb1795b fix #if condition of g_mmheap for BUILD_KERNEL. 2022-02-19 19:33:15 +08:00
Oki Minabe
682984e9ba add the kernel stack allocation in pthread create. 2022-02-19 19:32:21 +08:00
Alan C. Assis
9739be15de Doc/sim: Add documentation about LVGL and VNC 2022-02-19 17:30:27 +08:00
Piet
baa4bf17b7 sim: Enable Rust suppport for hello_rust application. 2022-02-18 23:01:04 +08:00
ligd
756c9fb60d semaphore: fix corner case sem_waitirq assert crash
[   11.041077] [25] [ EMERG] [ap] up_assert: Assertion failed at file:semaphore/sem_waitirq.c line: 84 task: thermal service
[   11.041407] [25] [ EMERG] [ap] backtrace:
[   11.041517] [25] [ EMERG] [ap] [25] [<0x2c687c9e>] up_backtrace+0xa/0x164
[   11.041627] [25] [ EMERG] [ap] [25] [<0x2c676e6c>] sched_dumpstack+0x1c/0x5c
[   11.041682] [25] [ EMERG] [ap] [25] [<0x2c68763a>] up_assert+0x42/0x24c
[   11.041792] [25] [ EMERG] [ap] [25] [<0x2c67355e>] _assert+0x2/0xc
[   11.041847] [25] [ EMERG] [ap] [25] [<0x2c65d536>] nxsem_wait_irq+0x3e/0x134
[   11.042288] [25] [ EMERG] [ap] [25] [<0x2c65d378>] nxsem_timeout+0x24/0x34
[   11.043169] [25] [ EMERG] [ap] [25] [<0x2c65f74c>] wd_timer+0xc0/0x104
[   11.043995] [25] [ EMERG] [ap] [25] [<0x2c65c930>] nxsched_alarm_expiration+0x4c/0xdc
[   11.044986] [25] [ EMERG] [ap] [25] [<0x2c670872>] oneshot_callback+0x16/0x24
[   11.045867] [25] [ EMERG] [ap] [25] [<0x2c6822b8>] bes_oneshot_irq_handler+0x18/0x28
[   11.046858] [25] [ EMERG] [ap] [25] [<0x57e5c>] up_irq_handler+0x4/0xc
[   11.047684] [25] [ EMERG] [ap] [25] [<0x2c65a20e>] irq_dispatch+0x5a/0xb8
[   11.048510] [25] [ EMERG] [ap] [25] [<0x2c6864d8>] arm_doirq+0x28/0x3c
[   11.049336] [25] [ EMERG] [ap] [25] [<0x2c681732>] exception_common+0x4a/0xac
[   11.050272] [25] [ EMERG] [ap] [25] [<0x2c65a324>] leave_critical_section+0x2c/0x54
[   11.051208] [25] [ EMERG] [ap] [25] [<0x2c65f472>] timer_settime+0x9e/0x10c

There are 2 ways can caused this:
1. sem_timedwait
   HW IRQ sem_post
   TIMER IRQ do wd_timer -> nxsem_timeout -> crash

   Note: The 2 IRQS happens amost at same time

2. sem_timedwait
   TIMER IRQ do wd_timer -> wd_func1 sem_post
                         -> wd_func2 nxsem_timeout -> crash

Resolve:
Stop the watchdog when sem_post

Signed-off-by: ligd <liguiding1@xiaomi.com>
2022-02-18 23:00:28 +08:00
Alin Jerpelea
b2048f985c LICENSE: document code found in arch: arm: lc823450:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
32038f6116 LICENSE: document code found in arch: arm: stm32l4:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
1e20bdd6a0 LICENSE: document code found in arch: arm: stm32f7/stm32h7:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
9899d36139 LICENSE: document code found in arch: arm: stm32f0l0g0:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
f55f366ba4 LICENSE: document code found in arch: arm: stm32:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
2c3ec7687e LICENSE: document code found in arch: arm: s32k1xx:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
0099001fcf LICENSE: document code found in arch: arm: rp2040:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
da8ba00b3b LICENSE: document code found in arch: arm: phy62xx:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
addda5155b LICENSE: document code found in arch: arm: nrf52:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
1c38b9e194 LICENSE: document code found in arch: arm: kl:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
4af324c57d LICENSE: document code found in arch: arm: kinetis:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
e86b3a7e97 LICENSE: document code found in arch: arm: inxrt:
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
36205be66b LICENSE: document code found in arch: arm: inxrt: hardware
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Alin Jerpelea
5773d0a7fc LICENSE: document code found in arch: arm: am335x
Document the licenses for non Apache code found in the mentioned folder

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-02-18 22:59:42 +08:00
Huang Qi
da25883c64 arch/sim: Fix usrsock build break on macOS
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2022-02-18 09:06:46 -03:00
Huang Qi
928b90b48d boards: Add missing options to sim:vncserver
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2022-02-18 09:06:46 -03:00
Petro Karashchenko
27d75e7552 drivers/ioexpander: minor initialize and styling fixes
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2022-02-18 16:44:40 +08:00
chao.an
61fa5d70f5 devif/ipv6_input.c: fix compile warning
devif/ipv6_input.c: In function ‘ipv6_input’:
devif/ipv6_input.c:344:32: warning: suggest parentheses around comparison in operand of ‘&’ [-Wparentheses]
  344 |       if ((ipv6->destipaddr[0] & HTONS(0xff0f) != HTONS(0xff00)) &&
      |                                ^
devif/ipv6_input.c:345:32: warning: suggest parentheses around comparison in operand of ‘&’ [-Wparentheses]
  345 |           (ipv6->destipaddr[0] & HTONS(0xff0f) != HTONS(0xff01)) &&
      |                                ^
devif/ipv6_input.c:346:32: warning: suggest parentheses around comparison in operand of ‘&’ [-Wparentheses]
  346 |           (ipv6->destipaddr[0] & HTONS(0xff0f) != HTONS(0xff02)))
      |                                ^

Signed-off-by: chao.an <anchao@xiaomi.com>
2022-02-18 16:05:20 +08:00
chao.an
f073ed3a44 net/tcp: add support for send timeout on buffer mode
Signed-off-by: chao.an <anchao@xiaomi.com>
2022-02-18 16:04:55 +08:00
Xiang Xiao
848d1ef0b7 tools/mkallsyms.sh: Disable the mismatch warning of builtin declaration
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-02-18 09:04:47 +01:00
chao.an
5da5ffb7d4 sim/usrsock: correct the xid type to uint64_t
Signed-off-by: chao.an <anchao@xiaomi.com>
2022-02-18 08:16:17 +01:00
Abdelatif Guettouche
ab18b7b3d3 esp32xx_irq.c: Fix CPU interrupt documentation to remove the MAC
interrupt from the internal interrupt table.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2022-02-18 13:40:21 +08:00
Abdelatif Guettouche
ee88235d81 esp32_irq.c: Don't reserve BT and Wifi CPU interrupts for APP CPU as
they are attached to the PRO CPU.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2022-02-18 13:40:21 +08:00
Abdelatif Guettouche
17e43b0b4a esp32_irq.c: For internal interrupts use the current CPU to enable them.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2022-02-18 13:40:21 +08:00
Abdelatif Guettouche
3d2771c49a esp32_irq.c: Move interrupt initialisation for special drivers to
`up_irqinitialize`.  `esp32_cpuint_initialize` is not a good place as
it's also called from CPU1.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2022-02-18 13:40:21 +08:00
Huang Qi
0c5aff9be6 risc-v/qemu-rv: Supports SMP up to 8 cores
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2022-02-18 13:25:01 +08:00
Huang Qi
36ff081b1a risc-v: Support more than 2 cores in riscv_cpu_boot
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2022-02-18 13:25:01 +08:00
Huang Qi
7c18290331 risc-v: Rename up_fault to riscv_fault
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2022-02-18 13:25:01 +08:00
Oki Minabe
979124928c fix array index range checking of gat[] in gran_alloc(). 2022-02-18 11:44:32 +08:00
Xiang Xiao
e0ae2963d2 drivers/pipe: Don't use sched_[lock|unlock] to do protection
since the sched lock can't work in SMP context

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-02-17 22:08:43 +01:00
Xiang Xiao
fe04eb535f drivers/pipe: Fix the format style issue
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-02-17 22:08:43 +01:00
chao.an
1911ae2192 net/tcp: add interface tcp_wrbuffer_timedalloc()
add new interface to support alloc wrbuffer with timeout

Signed-off-by: chao.an <anchao@xiaomi.com>
2022-02-17 21:27:39 +01:00
chao.an
a92d5f622e net/ioballoc: add support of alloc with timeout net_iobtimedalloc()
Signed-off-by: chao.an <anchao@xiaomi.com>
2022-02-17 21:27:39 +01:00
Piet
8828a43219 Default macro to compile one Rust file 2022-02-17 15:35:27 -03:00
chao.an
c73df52c46 net/socket: fix shadow variable
socket/setsockopt.c: In function ‘psock_socketlevel_option’:
socket/setsockopt.c:168:38: warning: declaration of ‘conn’ shadows a previous local [-Wshadow]
  168 |               FAR struct tcp_conn_s *conn;
      |                                      ^~~~

Signed-off-by: chao.an <anchao@xiaomi.com>
2022-02-17 17:55:16 +01:00
chao.an
0b18cfbd9a mm/iob: add support of alloc with timeout iob_timedalloc()
Signed-off-by: chao.an <anchao@xiaomi.com>
2022-02-17 11:55:29 -03:00
chao.an
4824ea68a9 libs/libnx: handle the bad message correctly
Signed-off-by: chao.an <anchao@xiaomi.com>
2022-02-17 13:40:11 +01:00
Petro Karashchenko
7933442b98 sched/semaphore/sem_clockwait: fix typo in comment
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2022-02-17 12:54:49 +01:00
Masayuki Ishikawa
41d62033a0 mm: umm_heap: Fix umm_heap for BUILD_KERNEL & ADDRENV
Summary:
- I noticed that the user heap is corrupted
- This commit fixes this issue by reverting the change to
  the NuttX-9.0.0

Impact:
- None

Testing:
- sabre6-quad:netknsh (not merged yet)

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
Co-authored-by: Oki Minabe <minabe.oki@gmail.com>
2022-02-17 11:31:01 +01:00
Masayuki Ishikawa
a44a0a08cd binfmt: Call umm_initialize() for BUILD_KERNEL & ADDRENV
Summary:
- I noticed that the user heap is not initialized correctly
  if BUILD_KERNEL=y and ADDRENV=y
- This commit fixes this issue

Impact:
- None

Testing:
- Tested with sabre-6quad:netknsh (not merged yet)

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2022-02-17 11:31:01 +01:00
lp.xiao
bc12260540 dp83848c ethernet phy interrupt support 2022-02-17 08:00:53 +01:00
Xiang Xiao
69a6072946 arch/ceva: Replace adj_stack_ptr with stack_base_ptr
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-02-17 11:06:09 +09:00