Commit Graph

51101 Commits

Author SHA1 Message Date
wanggang26
fa744e24a3 mmcsd: update cid reg layout
refer spec: https://www.jedec.org/sites/default/files/docs/JESD84-B51.pdf

Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2023-09-20 00:42:30 +08:00
yintao
f3c9a8643b nuttx: change RPTUNIOC_START and RPTUNIOC_STOP to synchronous
Support quit remote when server poweroff

Signed-off-by: yintao <yintao@xiaomi.com>
2023-09-20 00:42:02 +08:00
ligd
1f9fb5fce2 rptun: add rptun_update_rx() when device_created()
Signed-off-by: ligd <liguiding1@xiaomi.com>
2023-09-20 00:42:02 +08:00
ligd
378470f611 add remote poweroff support
Signed-off-by: yintao <yintao@xiaomi.com>
2023-09-20 00:42:02 +08:00
Shanmin Zhang
e8550a02b9 arm64: support reboot / poweroff for qemu virt arm64
Signed-off-by: Shanmin Zhang <zhangshanmin@xiaomi.com>
2023-09-20 00:40:44 +08:00
xinbingnan
75e591ae4f tools/minidumpserver: don't stop while gdb client is stopping
VELAPLATFO-16411

Signed-off-by: xinbingnan <xinbingnan@xiaomi.com>
2023-09-20 00:40:14 +08:00
Roy Feng
d98367693d esp32s3: fix build error 2023-09-20 00:35:28 +08:00
yangsen5
e0873c5a48 drivers/video: Fix crash caused by priv->capture_cb = null
When the upper layer calls goldfish_camera_data_uninit, priv->capture_cb=NULL, but when there is data transmission in goldfish_camera_thread, priv->capture_cb will be called, which will cause a crash.

Signed-off-by: yangsen5 <yangsen5@xiaomi.com>
2023-09-20 00:34:54 +08:00
Xiang Xiao
f6681218f4 ci: Update aarch64 gcc toolchain to 12.3.rel1
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-19 22:37:54 +08:00
Huang Qi
7d3f11af1f cibuild.sh: Using GCC from xPack for riscv
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-09-19 12:59:48 +03:00
Xu Xingliang
3cd5e20f74 sched: return 0 from clock_systime_ticks if failed
Signed-off-by: Xu Xingliang <xuxingliang@xiaomi.com>
2023-09-19 16:17:08 +08:00
ligd
415fe60695 signal: use work_cancel_sync() to fix used after free
bug:

user thread:                             hpwork:
timer_create() with SIGEV_THREAD
timer_settime()
    irq -> work_queue()                  add nxsig_notification_worker to Q
timer_delete()
    nxsig_cancel_notification()
                                         call nxsig_notification_worker()
    work_cancel()
    timer_free()
                                         nxsig_notification_worker() used after free

root cause:
work_cancel() can't cancel work completely, the worker may alreay be running.

resolve:
use work_cancel_sync() API to cancel the work completely

Signed-off-by: ligd <liguiding1@xiaomi.com>
2023-09-19 15:52:48 +08:00
ligd
61ef7eb3dc wqueue: add work_cancel_sync() support
Signed-off-by: ligd <liguiding1@xiaomi.com>
2023-09-19 15:52:48 +08:00
zhangyuan21
978c8bd249 sim: enable usb board ctrl in adb
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-09-19 07:51:49 +02:00
sunkun3
219677cdae rndis: Fixed rndis assert issue when calling composite_uninitlize
Signed-off-by: sunkun3 <sunkun3@xiaomi.com>
2023-09-19 07:51:49 +02:00
Huang Qi
89e409a194 tools: Switch riscv GCC to 12.3
GCC13 have compatibility issue with libcxx (need libcxx 17+).

Please refer to: https://github.com/llvm/llvm-project/issues/62396

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-09-19 11:42:51 +08:00
yangguangcai
fe30f0fa82 sched/wdog:change g_wdtickbase update situation.
In the 'wd_timer',the callback function executed by 'wd_expiration' could call wd_start,and g_wdtickbase might be updated.Subsequently, g_wdtickbase is incremented by the value of ticks, causing g_wdtickbase to be greater than the actual passage of time.

Signed-off-by: yangguangcai <yangguangcai@xiaomi.com>
2023-09-19 11:41:50 +08:00
Dong Heng
6ac28d5526 xtensa/esp32s3: LCD controller driver 2023-09-19 11:38:05 +08:00
liaoao
3a08c0a1e6 qemu:fdt:add device tree support for goldfish arm/arm64
Signed-off-by: liaoao <liaoao@xiaomi.com>
2023-09-19 11:34:26 +08:00
qinwei1
cb3e6667e3 arm64: add PSCI support for qemu platform
Summary
   Add ARM PCSI (Power State Coordination Interface) Support
for qemu. With the interface, Poweroff/PowerReset can be support

Signed-off-by: qinwei1 <qinwei1@xiaomi.com>
2023-09-19 11:34:26 +08:00
zhangyuan21
1e55ca43ef arm64: set cpuid according to mpidr
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-09-19 11:34:26 +08:00
qinwei1
8eea6d2e2a arm64: GoldFish add miss arm64_netinitialize
Summary
    add miss arm64_netinitialize function for goldfish
platform

Signed-off-by: qinwei1 <qinwei1@xiaomi.com>
2023-09-19 11:34:26 +08:00
qinwei1
c7e70b6967 arm64: 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 chip

Signed-off-by: qinwei1 <qinwei1@xiaomi.com>
2023-09-19 11:34:26 +08:00
Xiang Xiao
635d578a73 drivers/sensor: Remove the selection of UORB from Kconfig
since the driver doesn't depend on userspace library(uORB) at all

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-19 11:27:47 +08:00
zhengshaobo1
6e6ba062fd clock flags add CLK_OPS_PARENT_ENABLE, parents need enable during gate/ungate, set rate and re-parent
Signed-off-by: zhengshaobo1 <zhengshaobo1@xiaomi.com>
2023-09-19 10:34:48 +08:00
zhengshaobo1
be767dde01 vela fs procfs add clock procfs entry
procfs enrty add clock feature procfs operations

Signed-off-by: zhengshaobo1 <zhengshaobo1@xiaomi.com>
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-19 10:34:48 +08:00
Xiang Xiao
15e78470f8 arch/sim: Guard frame buffer related setting in SIM_X11FB
and remove SIM_VNCSERVER

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-19 10:33:52 +08:00
Xiang Xiao
4d2cc2ab4d supply/regulator: Refine rpmsg regulator
1.Change priv to client or server
2.Allocate memory for name in regulator_rpmsg_get
3.Lock/unlock regulator_list in regulator_rpmsg_server_s

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-19 10:33:09 +08:00
yinshengkai
1d8e69700f drivers/serial: add ram uart driver
It uses the memory block as the serial communication medium, which can communicate between different processes or different CPUs

Using the following configuration, the cross-core communication rate of 200MHz cortex-M55 is about 461KB/s
RAM_UART_BUFSIZE=1024
RAM_UART_POLLING_INTERVAL=100

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-09-19 09:41:07 +08:00
yinshengkai
1d9097f1df drivers/serial: unmodify head and tail pointers
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-09-19 09:41:07 +08:00
qiaohaijiao1
31da767cfc sim/alsa: add AUDIO_FMT_PCM query handler
Signed-off-by: qiaohaijiao1 <qiaohaijiao1@xiaomi.com>
2023-09-19 09:39:44 +08:00
chao an
ce6330bf29 arch/arm64: sync with mainline change
Signed-off-by: chao an <anchao@xiaomi.com>
2023-09-19 09:38:52 +08:00
qinwei1
a42448feb4 arch/arm64: fix link RWX warning for NuttX arm64
Summary
  when using new gcc verion like:
  GNU ld (Arm GNU Toolchain 12.2.Rel1 (Build arm-12.24)) 2.39.0.20221210)

  we will get link warning like:

  aarch64-none-elf-ld: warning: XXX/nuttx has a LOAD segment with RWX permissions

  The patch fix the warning through add link option --no-warn-rwx-segments

Signed-off-by: qinwei1 <qinwei1@xiaomi.com>
2023-09-19 09:38:52 +08:00
guoshichao
6683699c70 unistd: add _POSIX_SEMAPHORES definition
add _POSIX_SEMAPHORES definition can make the ltp testcase:
ltp_functional_semaphores_sem_conpro,
ltp_functional_semaphores_sem_philosopher,
ltp_functional_semaphores_sem_lock,
ltp_stress_semaphores_multi_con_pro,
ltp_functional_semaphores_sem_readerwriter,
ltp_functional_semaphores_sem_sleepingbarber
passed

Signed-off-by: guoshichao <guoshichao@xiaomi.com>
2023-09-19 09:37:49 +08:00
zhanghongyu
1389a686ba tcp: fix coverity warning for tcp_timer
use after free when the number of retransmissions reached the maximum.

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-09-19 09:37:20 +08:00
wanggang26
c3ccc30f83 wireless: enable O_CLOEXEC explicit
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2023-09-19 09:36:59 +08:00
qinwei1
cbf76e96c7 arm64: add mcpu option for all Cortex CPU
Summary
   add mcpu option for all Cortex CPU, from Spec of gcc

https://gcc.gnu.org/onlinedocs/gcc-12.3.0/gcc/AArch64-Options.html

testing with ostest for every option

Signed-off-by: qinwei1 <qinwei1@xiaomi.com>
2023-09-19 09:36:29 +08:00
chenxiaoyi
917764857a gdb/thread.py: fix typo
Signed-off-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
2023-09-19 09:35:55 +08:00
guoshichao
e0ec88e738 timer/timer_getoverrun: adjust the default errno from ENOSYS to EINVAL
modify the default errno from ENOSYS to EINVAL can pass the ltp
case: ltp_timer_getoverrun_speculative_6_1,
ltp_timer_getoverrun_speculative_6_2, ltp_timer_getoverrun_speculative_6_3

Signed-off-by: guoshichao <guoshichao@xiaomi.com>
2023-09-19 09:35:27 +08:00
chenrun1
4ce205cf08 lib_iconv.c:Fix possible out-of-bounds reads
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2023-09-19 09:34:48 +08:00
ligd
c9bc6b1ad5 rpmsg socket: add return value check.
Signed-off-by: ligd <liguiding1@xiaomi.com>
2023-09-19 09:33:30 +08:00
qinwei1
335c83e3c0 arm64: sync make file rules from arch/arm
Summary:
  sync makefile build rules from arch/arm to fix some compile
issue

Signed-off-by: qinwei1 <qinwei1@xiaomi.com>
2023-09-19 09:32:53 +08:00
ligd
f41383d998 notifier: add BLOCKING_INIT_NOTIFIER_HEAD support
Signed-off-by: ligd <liguiding1@xiaomi.com>
2023-09-19 09:32:17 +08:00
Simon Filgis
8853e72502 add phy bordinit functionality
on boardlevel one can do reset, cable-check, diagnostics, check link
quality and more on every link up
2023-09-19 02:41:55 +08:00
Petro Karashchenko
587f01a5e2 libs/libxx/libcxx: fix CI compilation issue reported on MACOS
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-09-19 01:17:17 +08:00
chao an
5026a96cfa nxstyle: cleanup UTF-8 Unicode to ASCII
Signed-off-by: chao an <anchao@xiaomi.com>
2023-09-18 11:54:17 -04:00
hujun5
02a3bbc73b sim/posix: Add the host_system interface
Encapsulate the host system interface to host_system.

Signed-off-by: hujun5 <hujun5@xiaomi.com>
2023-09-18 11:41:24 -04:00
yanghuatao
7ea52505c2 libm/libmcs: Fix clang build download libmcs warning
VELAPLATFO-16865

Fix warnings:
CC:  libmcs/libmcs/libm/common/fenv.c libmcs/libmcs/libm/common/fenv.c:26:15: warning: a function declaration without a prototype is deprecated in all versions of C [-Wstrict-prototypes]
int fegetround()
              ^
               void
Signed-off-by: yanghuatao <yanghuatao@xiaomi.com>
2023-09-18 23:00:38 +08:00
Huang Qi
43610f75f1 tools: Use GCC 13.2 from xPack for risc-v 2023-09-18 21:25:13 +08:00
qiaohaijiao1
9334ae47c7 sim/sim_alsa: reset alsa pcm device when snd_pcm_avail < 0
Signed-off-by: qiaohaijiao1 <qiaohaijiao1@xiaomi.com>
2023-09-18 21:24:02 +08:00