chenrun1
d65f8bd4c1
filelock:Move filelock call to ioctl
...
Forward the implementation originally placed in fcntl to ioctl. in order
to achieve cross-core.
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2024-08-18 19:56:49 +08:00
chenrun1
a1e3444df0
rpmsgfs:Support cross-core access using file locks on the same file
...
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2024-08-18 19:56:49 +08:00
Yanfeng Liu
b9fde453ce
riscv/qemu-rv: add RPTUN support
...
This adds initial RPTUN support for qemu-rv and rv-virt device.
Signed-off-by: Yanfeng Liu <yfliu2008@qq.com>
2024-08-18 19:55:27 +08:00
Yanfeng Liu
2af5ad174f
riscv/qemu-rv: add RPTUN Kconfig
...
This add RPTUN related Kconfigs for qemu-rv chip.
Signed-off-by: Yanfeng Liu <yfliu2008@qq.com>
2024-08-18 19:55:27 +08:00
guoshichao
61cd8c379e
mm/mempool: rename the mempool_alloc and mempool_free function
...
the mempool_alloc and mempool_free function are duplicate with the
mempool method that provided in optee_os, in order to port optee_os, so
we rename the mempool related functions in nuttx
Signed-off-by: guoshichao <guoshichao@xiaomi.com>
2024-08-18 19:46:54 +08:00
fangxinyong
a6fa9db91e
libs: fix the default value of process-shared attribute
...
pass ltp case: open_posix_testsuite/conformance/interfaces/pthread_condattr_getpshared/2-1.c
Reference:
https://pubs.opengroup.org/onlinepubs/009696899/functions/pthread_mutexattr_getpshared.html
Signed-off-by: fangxinyong <fangxinyong@xiaomi.com>
2024-08-18 19:44:56 +08:00
wanggang26
67f5fc19eb
build: untracked these two types of files
...
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2024-08-18 19:38:44 +08:00
wanggang26
c58bd521a3
coredump: refine coredump info analyse
...
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2024-08-18 19:34:36 +08:00
chenrun1
f7adb52c8b
hostfs_ioctl:Fixed the error:expected expression caused by not adding parentheses in switch
...
hostfs/hostfs.c:612:17: error: expected expression
FAR char *path = (FAR char *)(uintptr_t)arg;
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2024-08-18 10:17:48 +08:00
chenrun1
def05ebabb
hostfs:ioctl should return -ENOTTY when the instruction is incompatible
...
When sending FIOC_XXXLK to hostfs, hostfs will return -1 by default. For ioctl statements, incompatible instructions should be processed as -ENOTTY by default
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2024-08-18 10:17:48 +08:00
chenrun1
6e9a43c504
hostfs:add get_path
...
To perform kvdb related type testing in the simulator, ioctl support is required to obtain relpath
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2024-08-18 10:17:48 +08:00
chenrun1
e9ac1a2317
rpmsgfs_client:Fix error return exception
...
When handling errors through ioctl, the error returned by the server is always 0 on the client, because cookie.result is not assigned, the error returned should be in msg->result
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
2024-08-18 10:15:18 +08:00
rongyichang
8c3872b919
drivers/video: add goldfish gpu fb
...
In order to better use the Android goldfish emulator,
a GPU FB driver has been added. This allows the goldfish
emulator side to achieve more flexible display effects,
such as UI skins.
Signed-off-by: rongyichang <rongyichang@xiaomi.com>
2024-08-18 10:15:00 +08:00
Saurav Pal
daa3168cfb
fs/mnemofs: Fix journal log rw issue, read size issue
...
Fixes the journal log read and write size and overlap issues, along with read return value issue.
Signed-off-by: Saurav Pal <resyfer.dev@gmail.com>
2024-08-17 09:10:04 -03:00
buxiasen
9d396bf89e
pm: add debug_assert for cb register/unregister api
...
avoid the register/unregister API access wrong memory
Signed-off-by: buxiasen <buxiasen@xiaomi.com>
2024-08-17 14:30:49 +08:00
Eren Terzioglu
e11a53bec9
esp32[c3|c6|h2]: Add adjustable SPI clock speed
2024-08-17 13:43:58 +08:00
Tiago Medicci
69a8e2697f
espressif: Fix default pins for SPI bus 2 on ESP32-[C3|C6|H2]
...
Fix the correct pin number for the SPI 2 bus on ESP32-C3, ESP32-C6
and ESP32-H2.
2024-08-17 13:43:58 +08:00
Eren Terzioglu
61dff51a33
esp32[c3|c6|h2]: Fix SPI clock issue
2024-08-17 13:43:58 +08:00
Xiang Xiao
cd1f8f1fea
fs/epoll: Map EPOLLRDHUP from 0x2000 to POLLRDHUP
...
maintain consistency within nuttx definitions
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2024-08-17 00:19:15 +02:00
Xiang Xiao
7c1768c167
fs/epoll: Double array size when it is full
...
correct the sequnce of array size from:
size, size, 2*size, 4*size, 8*size...
to:
size, 2*size, 4*size, 8*size, 16*size...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2024-08-17 00:19:15 +02:00
Xiang Xiao
56b2e7254a
fs/poll: Compute tick from millisecond by MSEC2TICK
...
reduce duplicate code
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2024-08-17 00:19:15 +02:00
buxiasen
94e34d0020
clk: fix reg operation not compatible with 64bit
...
Signed-off-by: buxiasen <buxiasen@xiaomi.com>
2024-08-17 00:05:18 +08:00
Zhe Weng
504af7a1fa
drivers/virtio-net: Support VIRTIO_F_ANY_LAYOUT
...
According to Virtual I/O Spec:
When using legacy interfaces, transitional drivers which have not negotiated VIRTIO_F_ANY_LAYOUT MUST use a single descriptor for the struct virtio_net_hdr on both transmit and receive, with the network data in the following descriptors.
https://docs.oasis-open.org/virtio/virtio/v1.2/cs01/virtio-v1.2-cs01.html#x1-2280006 (Section 5.1.6.6)
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2024-08-16 21:15:31 +08:00
Ville Juven
073bb31c3b
mm/map/vm_region.c: Fix formatting error
...
mm/map/vm_region.c:131:7: error: If statement followed by garbage
2024-08-16 09:50:23 -03:00
Ville Juven
971ca501b9
mm/map/vm_region.c: Fix usage of void* arithmetics
...
Fixes build error:
map/vm_region.c: In function 'vm_map_region':
map/vm_region.c:128:16: error: pointer of type 'void *' used in arithmetic [-Werror=pointer-arith]
128 | return vaddr + (MM_PGMASK & paddr);
| ^
cc1: all warnings being treated as errors
2024-08-16 09:50:23 -03:00
Jouni Ukkonen
9c2af7284b
arch/arm64/imx93: Add more base addresses
...
mem slice and src base address added
Signed-off-by: Jouni Ukkonen <jouni.ukkonen@unikie.com>
2024-08-16 19:39:02 +08:00
Gao Feng
87ff0ddf6d
xtensa/esp32s3: reserve memory for a mutex struct depending on the OS
...
Enabling CONFIG_PRIORITY_INHERITANCE config causes a build error
Based on Nuttx OS reserve memory for mutex struct.
Pass build based on
- CONFIG_PRIORITY_INHERITANCE y
- CONFIG_SEM_PREALLOCHOLDERS 0/8
2024-08-16 15:25:20 +08:00
fanjiangang
5e9358b782
make/disassembly: generate disassembly file
...
Create the nuttx.asm in the disassembly format using the objdump program.
NOTE:
'>', objdump doesn't take arguments for output file,
but result is printed to standard out, and is redirected.
Signed-off-by: fanjiangang <fanjiangang@lixiang.com>
Signed-off-by: chao an <anchao@lixiang.com>
2024-08-16 15:22:25 +08:00
Gao Feng
ddbbdd7fd3
xtensa/esp32s3: partition name duplicate and free
2024-08-16 15:11:14 +08:00
Jinliang Li
a5bfbca869
arm/armv8-r: invalidate d-cache on boot
...
Pass CP15_CACHE_INVALIDATE argument with r1 register to cp15_dcache_op_level.
cache level is 0(L1 D-Cache) with r0 register.
prototype:
void cp15_dcache_op_level(uint32_t level, int op)
Signed-off-by: Jinliang Li <lijinliang1@lixiang.com>
2024-08-16 13:41:19 +08:00
Jinliang Li
0e825b230d
arm/armv8-r: add cp15 ops for mpu
...
Add some cp15 definitions for mpu configuration
Signed-off-by: Jinliang Li <lijinliang1@lixiang.com>
2024-08-16 13:27:31 +08:00
Jinliang Li
0fddb71478
serial/uart_16550: include stdint.h in uart_16550.h
...
stdint.h is needed in uart_16550.h for some types, e.g. uint32_t,
uintptr_t. Otherwise there will be building issue unless that stdint.h
is added before uart_16550.h by all files which needs uart_16550.h.
Signed-off-by: Jinliang Li <lijinliang1@lixiang.com>
2024-08-16 13:26:40 +08:00
xuxin19
b64fb09e6c
cmake:bugfix fix CMake LTO build block
...
it was wrong in https://github.com/apache/nuttx/pull/12423/files#r1618852245
EXTRA_FLAGS is useful in LTO for pass option tu lto linker
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-15 18:01:50 +08:00
Alan C. Assis
a409c42d13
Doc: Fix broken SPI Tool documentation
2024-08-15 13:36:50 +08:00
Alexis Guijarro
f05c85e622
arm/stm32h7x3x_rcc.c: Add External Power Supply option to stm32h7x3x targets
2024-08-15 02:52:45 +08:00
pengyiqiang
08cdff2046
arch/sim/Kconfig: set SIM_FBBPP to 32 by default
...
32bpp is the most commonly used option and should be used as the default
Signed-off-by: pengyiqiang <pengyiqiang@xiaomi.com>
2024-08-15 02:38:31 +08:00
Tiago Medicci
3ae30d00ea
docs: Improve information about debugging for Espressif SoCs
...
Provide more information on how to properly use OpenOCD and gdb to
debug Espressif SoCs on NuttX.
2024-08-15 02:38:09 +08:00
xuxin19
b3f1871bc3
sched:fix windows sim build error
...
nuttx\sched\signal\sig_timedwait.c(253,13): error C2059: syntax error:'<parameter-list>'
nuttx\sched\signal\sig_timedwait.c(321,44): error C2182: '$S1': illegal use of type 'void'
nuttx\sched\signal\sig_timedwait.c(321,50): error C2059: syntax error:':'
nuttx\sched\tls\tls_initinfo.c(68,39): error C2036: 'void *': unknown size
nuttx\sched\sched\sched_get_tls.c(76,44): error C2036: 'void *': unkown size
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 22:36:57 +08:00
chenxiaoyi
363cd1c17a
windows sim:convert pointer type to char* fix windows net build error
...
nuttx\include\nuttx\net\netfilter\ip6_tables.h(299,24): error C2036: 'void *': unknown size
Co-authored-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
Co-authored-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 22:36:57 +08:00
chenxiaoyi
cedb7f97de
compiler.h: fix windows netfilter build error
...
nuttx\net\netfilter\ipt_sockopt.c(389,7): error C2059: syntax error: ')'
nuttx\net\netfilter\ip6t_sockopt.c(387,7): error C2059: syntax error: ')'
Co-authored-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
Co-authored-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 22:36:57 +08:00
chenxiaoyi
538582ede1
convert pointer string to number in base 16
...
Co-authored-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
Co-authored-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 22:36:57 +08:00
chenxiaoyi
7ce5241f0e
types.h: fix windows build error
...
Windows Kits\10\Include\10.0.22621.0\ucrt\corecrt.h(605,39): error C2371: 'wint_t': redefinition; different basic types
Windows Kits\10\Include\10.0.22621.0\ucrt\corecrt.h(606,39): error C2371: 'wctype_t': redefinition; different basic types
Co-authored-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
Co-authored-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 22:36:57 +08:00
chenxiaoyi
7c56e917e7
libc:add missing source to fix windows build error
...
nuttx_all.lib(netlib_setipv4dnsaddr.obj) : error LNK2019: unresolved external symbol _bzero referenced in function _netlib_set_ipv4dnsaddr
Co-authored-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
Co-authored-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 22:36:57 +08:00
chenxiaoyi
46f3477d2f
compiler.h: fix windows build error
...
warning C5101: use of preprocessor directive in function-like macro argument list is undefined behavior
Co-authored-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
Co-authored-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 22:36:57 +08:00
chenxiaoyi
f512f5e8a9
windows sim:add MSCV atomic support for fix windows build error
...
VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(36,24): error C2061: syntax error: identifier 'atomic_bool'
VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(36,24): error C2059: syntax error: ';'
VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(37,23): error C2061: syntax error: identifier 'atomic_char'
VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(37,23): error C2059: syntax error: ';'
VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(38,30): error C2061: syntax error: identifier 'atomic_schar'
VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(38,30): error C2059: syntax error: ';'
Co-authored-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
Co-authored-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 22:36:57 +08:00
chenxiaoyi
b65efdba12
sim_hostmemory.c: fix windows build error
...
nuttx\arch\sim\src\sim\win\sim_hostmemory.c(39,40): error C2146: syntax error: missing ')' before identifier 'exec'
nuttx\arch\sim\src\sim\win\sim_hostmemory.c(39,35): error C2081: 'bool': name in formal parameter list illegal
nuttx\arch\sim\src\sim\win\sim_hostmemory.c(39,40): error C2061: syntax error: identifier 'exec'
nuttx\arch\sim\src\sim\win\sim_hostmemory.c(39,40): error C2059: syntax error: ';'
nuttx\arch\sim\src\sim\win\sim_hostmemory.c(39,44): error C2059: syntax error: ')'
nuttx\arch\sim\src\sim\win\sim_hostmemory.c(40,1): error C2449: found '{' at file scope (missing function header?)
nuttx\arch\sim\src\sim\win\sim_hostmemory.c(42,1): error C2059: syntax error: '}'
Co-authored-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
Co-authored-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 22:36:57 +08:00
chenxiaoyi
4cd66fa7cc
windows sim:add CONFIG_SYSTEM_TIME64 fix windows build error
...
nuttx\arch\sim\src\sim\sim_checkhostfstypes.c(80,1): error C2338: static_assert failed: 'sizeof(((struct nuttx_stat_s *)0)->st_atim) == sizeof(((struct stat *)0)->st_atim)'
nuttx\arch\sim\src\sim\sim_checkhostfstypes.c(81,1): error C2338: static_assert failed: 'offsetof(struct nuttx_stat_s, st_mtim) == offsetof(struct stat, st_mtim)'
nuttx\arch\sim\src\sim\sim_checkhostfstypes.c(81,1): error C2338: static_assert failed: 'sizeof(((struct nuttx_stat_s *)0)->st_mtim) == sizeof(((struct stat *)0)->st_mtim)'
nuttx\arch\sim\src\sim\sim_checkhostfstypes.c(82,1): error C2338: static_assert failed: 'offsetof(struct nuttx_stat_s, st_ctim) == offsetof(struct stat, st_ctim)'
Co-authored-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
Co-authored-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 22:36:57 +08:00
xuxin19
b325ae6391
cmake: add_application supports only registration but not compilation
...
for sources that have implemented multiple prog_main,
there is a situation where you don't need to add source files but need to register.
the add_application method is enhanced so that it can be registered without entering SRCS.
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 16:05:27 +02:00
Yanfeng Liu
41dba46c1d
arch/riscv: fix IRQ_SOFT for non-SMP
...
This fixes software interrupt number for non-SMP cases
Signed-off-by: Yanfeng Liu <yfliu2008@qq.com>
2024-08-14 20:59:52 +08:00
xuxin19
819685fbec
cmake:bugfix enable ARCH_STRING_FUNCTION CMake build fail
...
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2024-08-14 20:58:59 +08:00