Commit Graph

43741 Commits

Author SHA1 Message Date
Xiang Xiao
bbf5511e3a arch/sim: Move the dummy ioe driver to drivers/ioexpender
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-09 11:06:06 +08:00
Xiang Xiao
b054bd9d37 arch/sim: Move the dummy foc driver to drivers/motor/foc
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-09 11:06:06 +08:00
Alan C. Assis
d7ec3e30ae esp32-devkitc: Add support to PWM 2022-01-08 14:46:51 +01:00
Alan C. Assis
4ca38c6c50 esp32: Add PWM support using the LEDC peripheral
Co-authored-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2022-01-08 14:46:51 +01:00
Petro Karashchenko
e7f9c7af21 typos: fix typos in Kconfig files
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2022-01-08 06:46:26 -03:00
Gustavo Henrique Nihei
73ea0c1627 xtensa: Improve Kconfig description of ESP32-S2 arch family
Also fix the wrong "dual-core" statement, since all ESP32-S2 chips are
composed of a single Xtensa LX7 core.

Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2022-01-07 22:25:05 +01:00
Xiang Xiao
6e31d0dd87 boards/sim: Switch RAMMTD_FLASHSIM to [Q]SPI_FLASH for smartfs config
to extend the build/test coverage

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-07 23:50:11 +08:00
Xiang Xiao
3156a96a1b arch/sim: Move qspiflash simulation to drivers/spi instead
since it's common implementation can be used in other arch too

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-07 23:50:11 +08:00
Xiang Xiao
d296f9c085 arch/sim: Move spiflash simulation to drivers/spi instead
since it's common implementation can be used in other arch too

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-07 23:50:11 +08:00
ligd
ee916bdb91 CEVA: add ceva platform xc5 xm6 support
Signed-off-by: ligd <liguiding1@xiaomi.com>
2022-01-07 09:31:59 -03:00
chao.an
3fceaf10a9 drivers/ioexpander: fix the kconfig warning
drivers/ioexpander/Kconfig:28:

warning:
config symbol 'IOEXPANDER_RPMSG_INT_NCALLBACKS' uses select, but is not boolean or tristate

Signed-off-by: chao.an <anchao@xiaomi.com>
2022-01-07 09:37:07 +01:00
Xiang Xiao
0cb858edd5 board/sim: Turn on more rpmsg drivers in rpserver config
to improve the build and test coverage

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-07 15:59:58 +08:00
Xiang Xiao
7060408c62 Fix net/rpmsgdrv.c:440:20: error: '#' flag used with '%p' gnu_printf format
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-07 15:59:58 +08:00
Xiang Xiao
49c00e0361 arch/sim: Rename up_vfork[32|64].S to up_vfork_x86[_64].S
to follow other arch/x86 arch/x86_64 convention

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-07 15:59:34 +08:00
Xiang Xiao
1a02556265 Revert "arch/sim: Rename up_vfork[32|64].S to up_vfork_x[32|64].S"
This reverts commit 3982296294.
2022-01-07 15:59:34 +08:00
chao.an
8c35d31808 Kconfig: Remove CONFIG_ prefix from config definition
Signed-off-by: chao.an <anchao@xiaomi.com>
2022-01-07 13:16:18 +08:00
Xiang Xiao
964f4b7ed7 sched/Kconfig: Remove CONFIG_ prefix from SCHED_HPWORK
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-06 18:45:13 -03:00
Xiang Xiao
8dc2ce7995 ioexpander/rpmsg: Select IOEXPANDER_INT_ENABLE instead depend on it
follow other similiar drivers

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-06 22:20:38 +01:00
Alexander Lunev
8042de1145 net/devif/devif_callback.c: devif_callback_free() call is not needed anymore in devif_callback_alloc() 2022-01-06 22:47:18 +08:00
Xiang Xiao
afacc8d590 usbhost: Fix typo error in Kconfig(MOUSE->INPUT_MOUSE)
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-06 17:51:27 +08:00
Xiang Xiao
3c86a3c2b0 input: Remove prompt string from INPUT_MOUSE
to ensure this option can only be enabled by select in Kconfig

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-06 17:51:27 +08:00
Xiang Xiao
3982296294 arch/sim: Rename up_vfork[32|64].S to up_vfork_x[32|64].S
to align with up_vfork_arm.S naming style

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-06 09:42:44 +01:00
Gustavo Henrique Nihei
41c727f251 Revert "ci: Freeze pipenv version for avoiding issue on documentation generation"
This reverts commit 57cba0e088.
2022-01-06 00:27:23 +01:00
Gustavo Henrique Nihei
42ffae2d2d tools/esp: Fix App image alignment when Flash Encryption is enabled
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2022-01-05 17:04:19 -03:00
Gustavo Henrique Nihei
10a8dc9f22 tools/esp: Prevent reset after flash when Flash Encryption is enabled
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2022-01-05 17:04:19 -03:00
Gustavo Henrique Nihei
6053de27ce tools: Fix parallel build issue due to missing dependency
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2022-01-05 23:27:30 +08:00
Xiang Xiao
fb92621962 drivers/mmcsd: Add RPMB ioctl
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-05 11:23:27 -03:00
raiden00pl
a983cd2377 boards/stm32: register CAN character device if configured 2022-01-05 06:16:41 -08:00
raiden00pl
6fe95d8314 stm32: add SocketCAN support, based on stm32_can.c 2022-01-05 06:16:41 -08:00
Xiang Xiao
e27962a997 net/devif: Fix the memory leak in case of netdev isn't alive
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-05 22:01:13 +08:00
Jiuzhu Dong
f93c17be94 fs/procfs: fix readdir loss last character
nsh> ls
/proc:
 0/
 1/
 2/
 3/
 4/
 5/
 meminf
 iobinf
 f/
 ne/
 sel/
 uptim
 versio

Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-01-05 21:58:38 +08:00
Zeng Zhaoxiu
fb43fd73ed signal: signal handler may cause task's state error
For example, task is blocked by nxsem_wait(sem1), use nxsem_wait(sem2)
in signal handler, and take sem2 successfully, after exit from signal
handler to task, nxsem_wait(sem1) returns OK, but the correct result
should be -EINTR.

Signed-off-by: Zeng Zhaoxiu <zhaoxiu.zeng@gmail.com>
2022-01-05 21:36:44 +09:00
anjiahao
9aa69168e4 libc/pthread:pthread_barrierinit sem use pri_none
barrier is used protect resources. don't lock
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2022-01-05 20:21:05 +08:00
Alan Rosenthal
f4d74b52d8 Rename tools/Makefile.* to have the .mk extension
This PR renames `tools/Makefile.*` to have the `.mk` extension. This PR also updates `README.md` and other files that references the other files.
Note: Skipped Makefile.host for this PR since it caused failures in CI for the sim build

By using a standard extension for Makefiles (https://www.file-extension.info/format/mk), editors will auto-format files.
This change will also improve developer ergonomics when searching for specific files

Verified locally that build still works, CI will verify more!
2022-01-05 18:33:16 +08:00
raiden00pl
5b9b3814f8 stm32: add CAN error support 2022-01-05 18:33:06 +08:00
raiden00pl
a8ca1ec026 SocketCAN: add CAN error definitions 2022-01-05 18:32:46 +08:00
raiden00pl
09ae15755e include/nuttx/can/can.h: fix typo 2022-01-05 18:32:46 +08:00
raiden00pl
474205e1be boards/nucleo-f446re: add procfs support 2022-01-05 18:31:44 +08:00
chao.an
4603d108be net/usrsock: add support for CONFIG_NET_ALLOC_CONNS
Signed-off-by: chao.an <anchao@xiaomi.com>
2022-01-05 12:39:00 +08:00
chao.an
cbe9352f41 net/usrsock: remove the connections limit
replace xid type to uint64_t to avoid connections limit

Signed-off-by: chao.an <anchao@xiaomi.com>
2022-01-05 12:38:42 +08:00
Jiuzhu Dong
c6bd160be5 fs/romfs: remove the error single list and using reference
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-01-05 12:22:17 +08:00
Jiuzhu Dong
06f76747fc fs/romfs: fix the typo error
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-01-05 12:22:17 +08:00
Jukka Laitinen
9aea5d5dbb arch/risc-v/src/mpfs/mpfs_serial.c: Correct setting of nbits
Number of bits was set wrongly in TCSETS for mpfs

Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2022-01-05 12:21:38 +08:00
Jiuzhu Dong
6ec006ee02 socket: extend socket_storage for rpmsg_socket addrinfo
rexecd.c: In function 'rexecd_main':
rexecd.c:191:9: warning: array subscript 18 is outside array bounds of 'struct sockaddr_storage[1]' [-Warray-bounds]
  191 |         snprintf(((FAR struct sockaddr_rpmsg *)&addr)->rp_name,
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  192 |                  RPMSG_SOCKET_NAME_SIZE, "%d", REXECD_PORT);
      |                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
rexecd.c:142:27: note: while referencing 'addr'
  142 |   struct sockaddr_storage addr;

Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-01-05 02:05:49 +08:00
Alan Rosenthal
57a19de451 Improve dirlinks dependencies for Makefile.win
This PR improved dirlinks dependencies for Makefile.unix: https://github.com/apache/incubator-nuttx/pull/5069

This PR copies the changes into Makefile.win
2022-01-05 02:03:08 +08:00
Alan Rosenthal
0951f70df6 Improve dependencies for include/nuttx/version.h
`include/nuttx/version.h` is dependent on `.version`, which needs to run for every invocation of make, since git info can update at any time.
Currently the `.version` target is PHONY, thus making `include/nuttx/version.h` and `context` targets (and every target that depends on `context`) have to run every time.

This PR modifies `.version` so it's a real rule. Additionally, `tools/version.sh` is run every invocation of make. This maintains the current behavior while preventing some targets from needlessly running every time
2022-01-04 17:49:39 +01:00
Xiang Xiao
828f04f0e5 sdio: Move sdio utils functions to drivers/mmcsd
so all sdio client driver can reuse them

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-01-04 17:44:24 +01:00
Huang Qi
3a0e86c99b arch/risc-v: Replace __LP64__ with CONFIG_ARCH_RV64
It can provide better auto complete experience for modern code editor,
since they use clang/gcc based parser to analyze code but lacks some
target dependent info such as __LP64__ for riscv64.

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2022-01-04 23:22:43 +08:00
Jiuzhu Dong
dce8c96281 uart_rpmsg: fix data loss
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-01-04 20:57:40 +08:00
Eero Nurkkala
b4d2944df7 tools/mpfs: prepare OpenSBI image
Polarfire Icicle board has only (128K - 256) bytes for the bootloader
in the non-volatile eNVM. This space is barely enough for running NuttX.
If OpenSBI is selected, it will be placed in DDR. This all means the
nuttx.bin file grows into gigabyte size, filling the unused space (ddr -
envm) with zeroes.

The memory layout is as follows:

MEMORY
{
    ddr  (rx)          : ORIGIN = 0x80000000, LENGTH = 4M
    envm (rx)          : ORIGIN = 0x20220100, LENGTH = 128K - 256
    l2lim  (rwx)       : ORIGIN = 0x08000000, LENGTH = 1024k
    l2zerodevice (rwx) : ORIGIN = 0x0A000000, LENGTH = 512k
}

OpenSBI library is used as a separate binary, which is stored into
eMMC or SD-card. It is then loaded into its precise location in DDR.

Thus, we separate OpenSBI from NuttX and end up with two images
by utilizing the objcopy options:

  --only-section=sectionpattern (-j in short)
  --remove-section=sectionpattern (-R in short)

This is only valid when CONFIG_MPFS_OPENSBI is set.

Signed-off-by: Eero Nurkkala <eero.nurkkala@offcode.fi>
2022-01-04 19:45:14 +08:00