Commit Graph

51888 Commits

Author SHA1 Message Date
Dong Heng
8c9e9b628c xtensa/esp32s3: GPIO clear pending interrupt status before enable IRQ 2023-12-06 02:30:58 -08:00
Dong Heng
d9b543e465 xtensa/esp32s3: QSPI disable DMA when sending command to slave 2023-12-06 02:30:03 -08:00
liqinhui
a69c8a6183 net/icmpv6:Optimize the process of obtaining the IPv6 address through RA.
- When receiving Router Advertisement Message, if Managed Address
  Configuration flag is set, we should ignore the Autonomous
  Address-configuration flag, and obtain the IPv6 address via the
  stateful process.

Signed-off-by: liqinhui <liqinhui@xiaomi.com>
2023-12-05 23:40:37 -08:00
zhanghongyu
4087e21dea ci_sim01: install g++-multilib into docker to support libcxx
fix build break:
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/11/libstdc++.so when searching for -lstdc++
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/11/libstdc++.a when searching for -lstdc++
/usr/bin/ld: cannot find -lstdc++: No such file or directory
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/11/libstdc++.so when searching for -lstdc++
collect2: error: ld returned 1 exit status
ninja: build stopped: subcommand failed.

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-12-06 06:20:05 +01:00
David Sidrane
f92a9068dc stm32h7:Serial refactor out tx dma semaphore
Fixes is stuttering output.

   The use of the semaphore was causing blocking
   on non blocking callers. This ensured that
   the TX DAM would be restated, but when it
   was switched to trywait in 660ac6, it left
   data in the xmit queue unsent.

   This solution removes the semaphore and restart
   the DMA on completion if there is more data in
   the xmit queue to be sent.
2023-12-05 08:20:10 -08:00
Michal Lenc
7f4cf11064 samv7/sam_emac.c: fix compile error with unknown structure member
chip/sam_emac.c:3754:11: error: 'struct sam_emac_s' has no member
named 'phytype'
 3754 |   if (priv->phytype == SAMV7_PHY_KSZ8061)
      |           ^~
make[3]: *** [Makefile:167: sam_emac.o] Error 1

Member phytype is available only if CONFIG_NETDEV_PHY_IOCTL and
CONFIG_ARCH_PHY_INTERRUPT is set.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-12-05 08:19:30 -08:00
David Sidrane
9175f3a9b6 s32k3xx:Serial refactor out tx dma semaphore
Fixes stuttering output.

  The use of the semaphore was causing blocking
  on non blocking callers. This ensured that
  the TX DAM would be restated, but when it
  was switched to trywait in 8362e314, it left
  data in the xmit queue unsent.

  This solution removes the semaphore and restart
  the DMA on completion if there is more data in
  the xmit queue to be sent.
2023-12-05 08:17:42 -08:00
David Sidrane
7f0643de6d s32k3xx:edma clear state before callback add idle check
This prevents dma stop operations called of a completion
   call back from rentering, the callback and ensures that
   the call back will see the idle state.
2023-12-05 08:17:42 -08:00
Zhe Weng
bffe858e47 fs/proc: Fix groupfd to get fd by group instead of current tcb
/proc/<pid>/group/fd should read the fds of <pid>, not current tcb.

Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-12-04 21:37:28 -08:00
zhanghongyu
c17fcb5ddd ci_sim: the version of nodejs obtained by apt install is too low
so using npm to upgrade the nodejs tool to the latest

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-12-04 11:25:40 -08:00
chenrun1
eee3af93ff tools/Unix.mk:Security Checks and Windows Native Compilation Enhancements
Avoid splicing paths to /include when BOARD_COMMON_DIR does not exist
and enhanced Windows native compilation

Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-12-04 07:07:08 -08:00
chenrun1
e4b561d51b sh:Enhanced compilation system
In this change, if board/include and board/script are not found, they will be looked for again in the upper level of common.

Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-12-04 07:07:08 -08:00
simbit18
ccc0c54401 Fix Kconfig style
Remove extra TABs
Remove spaces from Kconfig
Add comments
2023-12-04 22:20:50 +08:00
zhanghongyu
a18a0d20eb ci_sim: the version of gn obtained by apt install is too low
so dynamically download and install the latest gn tools

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-12-04 03:58:27 -08:00
Petro Karashchenko
a3cd8f921a arch/arm/samv7/sam_emac: Implement errata workaround for KSZ8061 PHY
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-12-04 00:37:43 -08:00
Rodrigo Sim
ce4c70690f stm32f401rc-rs485: Add eeprom support 2023-12-04 00:34:14 -08:00
zhanghongyu
e0df6dd22e ci_sim: add the tools needed at matter compile
add the tools needed for the compilation environment and docker first, then add matter compilation to cilist

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-12-04 00:33:54 -08:00
Xiang Xiao
6783051aed Fix the wrong comment banner
"Private Type"->"Private Types"

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-12-03 17:50:35 +01:00
raiden00pl
ac5c47fcb6 nrf52832-dk: add timer example 2023-12-03 05:47:07 -08:00
shizhenghui
49398d32aa move userspace interface from video.h to sys/videoio.h
Signed-off-by: shizhenghui <shizhenghui@xiaomi.com>
2023-12-02 19:44:39 -08:00
wangzhaofeng
1967b8432a copy part of linux videodev2.h which is used in v4l2m2m
Signed-off-by: wangzhaofeng <wangzhaofeng@xiaomi.com>
2023-12-02 19:44:39 -08:00
chenrun1
a6dc4412ba misc/rwlock:Implementing read/write locks.
A new locking mechanism: read/write locks
When there is a writer it is not possible to put on a read lock or a write lock; when there is a reader it is possible to reenter the read lock but not the write lock.
Writers are exclusive locks, readers are shared locks.
At the same time through the waiter count to determine whether there is currently a blocked task, if there is then in the unlock time to wake up all the waiter, through the priority of the competition to complete the blocked lock execution.
For example:
When we have a reader blocking two waiter writers, when the reader is unlocked it wakes up both writers. The writer with higher priority wakes up and checks for a successful condition and locks the lock, the second writer wakes up and fails to check for a condition and continues to block the lock.

Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-12-02 19:43:19 -08:00
raiden00pl
95ac627d59 arch/nrf{52|53|91}: add missing support for 1 Mbps UART baud 2023-12-02 19:40:09 -08:00
Zhang Yang
4f9d014994 Fix -nan issue with f32 2023-12-01 18:49:46 -08:00
Eren Terzioglu
9c793067cc xtensa/esp32s3: Fix esp32s3 mcuboot ota crash 2023-12-01 18:48:10 -08:00
Eren Terzioglu
5b19d8b2cb xtensa/esp32s2: Add RTC support 2023-11-30 21:02:12 -03:00
Eren Terzioglu
31abcb0e9a xtensa/esp32s3: Add rtc defconfig 2023-11-30 08:58:17 -08:00
chao an
7b1f22ca18 xmc4/spi: fix typo
Signed-off-by: chao an <anchao@xiaomi.com>
2023-11-30 06:16:09 -08:00
chao an
09c17fcfa8 segger/rtt: correct macro name to avoid unable to change default mode
SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL should be CONFIG_SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL

Signed-off-by: chao an <anchao@xiaomi.com>
2023-11-30 06:16:09 -08:00
chao an
3d57055057 libc/arm: add support of PACBTI
Reference:
https://developer.arm.com/documentation/100748/0617/Security-features-supported-in-Arm-Compiler-for-Embedded/PACBTI-M-extension-mitigations-against-ROP-and-JOP-style-attacks
https://developer.arm.com/documentation/101754/0619/armclang-Reference/armclang-Command-line-Options/-mbranch-protection

Signed-off-by: chao an <anchao@xiaomi.com>
2023-11-30 01:12:24 -08:00
Rodrigo Sim
14000d077d seeed-xiao-rp2040: Add initial board support 2023-11-29 19:32:22 -08:00
chao an
22654f62c0 libc/arm: add acle-compat license
add acle-compat implementation, and the implementation are ported from newlib

Signed-off-by: chao an <anchao@xiaomi.com>
2023-11-29 19:04:30 -08:00
chao an
29bda7cf27 libc/machine/arm: align related implementations of armv7 architecture
1. sync arch elf changes
2. fix cmake compilation break
3. remove the definition of related math files

Signed-off-by: chao an <anchao@xiaomi.com>
2023-11-29 19:04:30 -08:00
raiden00pl
74874e0874 boards/sim/nxscope: use default /dev/ttySIM0 path 2023-11-29 18:35:44 -08:00
raiden00pl
47b27321d5 boards/sim/nxscope: remove CONFIG_ALLSYMS=y
this option adds some python dependencies for mkallsyms.py and we don't need it for this example
2023-11-29 18:35:44 -08:00
Zhe Weng
bd19065933 net/loopback: Fix flags of lo device
netdev_register will set IFF_LOOPBACK in d_flags, we should not just
change it into IFF_UP only.

Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-11-29 07:57:01 -08:00
chenwen@espressif.com
53beaf1a67 xtensa/esp32s3: Add SPIRAM high memory support
1. Configurable mapping of virtual address to psram physical address
  2. Access SPIRAM memory at high physical address through bank switching

Signed-off-by: chenwen@espressif.com <chenwen@espressif.com>
2023-11-29 06:33:51 -08:00
chao an
88dd492e4d arm/clang: clang must depends on the implementation of the math library
Since picolibc used by clang-17 does not provide an implementation of libm,
if you want to use clang, please must specify a libm as an option.

Signed-off-by: chao an <anchao@xiaomi.com>
2023-11-29 03:58:05 -08:00
chao an
0bf9e5eb8d armv6-m/dumpnvic: fix build warning
armv6-m/arm_dumpnvic.c: In function 'arm_dumpnvic':
armv6-m/arm_dumpnvic.c:67:13: warning: format '%x' expects argument of type 'unsigned int', but argument 4 has type 'uint32_t' {aka 'long unsigned int'} [-Wformat=]
   67 |       _info("   IPR%d: %08x  IPR%d: %08x  IPR%d: %08x  IPR%d: %08x\n",
      |             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
armv6-m/arm_dumpnvic.c:67:27: note: format string is defined here
   67 |       _info("   IPR%d: %08x  IPR%d: %08x  IPR%d: %08x  IPR%d: %08x\n",
      |                        ~~~^
      |                           |
      |                           unsigned int
      |                        %08lx

Signed-off-by: chao an <anchao@xiaomi.com>
2023-11-29 03:58:05 -08:00
chao an
4540dd4718 stm32/clang: enable LIBM avoid build break on clang-17
Signed-off-by: chao an <anchao@xiaomi.com>
2023-11-29 03:58:05 -08:00
chao an
27bfdf68ae stm32/ethernet: fix build warning
chip/stm32_ethernet.c:2014:7: warning: variable 'i' set but not used [-Wunused-but-set-variable]
 2014 |   int i;
      |       ^
1 warning generated.

Signed-off-by: chao an <anchao@xiaomi.com>
2023-11-29 03:58:05 -08:00
chao an
1ce1a19afd arm/clang: replace deprecated parameter
In LLVM Clang 17.0.1, the `--config` parameter has been deprecated and replaced by the `-target` parameter

Signed-off-by: chao an <anchao@xiaomi.com>
2023-11-29 03:58:05 -08:00
chenwen@espressif.com
e2a82f008a xtensa/esp32s3: Invalidate cache if the flash address used has a cache mapping.
Signed-off-by: chenwen@espressif.com <chenwen@espressif.com>
2023-11-29 03:57:50 -08:00
Michal Lenc
e852f28710 ci: add open_memestream CI test
CI test for open_memestream() stdio function was added.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-11-29 02:13:19 -08:00
Michal Lenc
eea7db24f3 libc: add support for open_memstream
Adds support for POSIX interface open_memstream() that allows writing
to dynamic memory buffer stream. The stream is dynamically reallocated
as the buffer grows with initial size set to zero.

The caller has to free the buffer after the stream is closed.

The implementation uses fopencookie() for custom stream operations and
callbacks.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-11-29 02:13:19 -08:00
yaojingwei
a57e3f365a video.c: modify set_buf call seqence in start_capture function.
To avoid losing the first frame, the set_buf needs to excute first. At the same time, imgdata->start_capture should excuted before the imgsensor->start_capture.

Signed-off-by: yaojingwei <yaojingwei@xiaomi.com>
2023-11-29 02:01:34 -08:00
chenwen@espressif.com
54b71de23a xtensa/esp32s3: Fix some ESP32S3 module reboot and QVL issues
1. Increase the data length in timing tuning.
2. Add MSPI Error-Correcting Code function when accessing SPIRAM.
3. Add delay before timing tuning.
2023-11-29 01:51:58 -08:00
Ville Juven
8494fd2097 mpfs/mpfs_corespi.c: Round up divider to prevent overlock of SPI
The divider should be rounded to the next full integer to ensure that
the resulting SPI frequency is <= target frequency, i.e. the SPI is
not overclocked.
2023-11-29 01:47:55 -08:00
raiden00pl
9858dfde32 Documentation: disable parallel build 2023-11-29 01:37:10 -08:00
raiden00pl
de199faed6 Documentation: turn warnings into errors 2023-11-29 01:37:10 -08:00