summaryrefslogtreecommitdiff
path: root/components
AgeCommit message (Collapse)Author
2024-05-31[DM/feature] Implement PIC irq state { get; set } (#9006)GUI
* [DM/feature] Implement PIC irq state { get; set } There are some common state for irq: 1. Pending: IRQ was triggered, but software not ACK. 2. Active: IRQ was ACK, but not EOI. 3. Masked: IRQ was masked or umasked. Signed-off-by: GuEe-GUI <[email protected]> * [DM/pic] Support IRQ state { get; set } for ARM GICv2/v3 Signed-off-by: GuEe-GUI <[email protected]> --------- Signed-off-by: GuEe-GUI <[email protected]>
2024-05-31[fix]fix compile err in pic-gic (#9015)zms123456
fix compile err in pic-gic
2024-05-31[smart] fixup of script execution (#9009)Shell
This patch fixup the script execution capabilities on argv passing and adds support for arguments larger than 4k. According to POSIX, the script parameter is quiet different from the current implementation. Especially on the way it inserts the path of executables. At the end, when you execute a script from `$PATH`, it always fails. For the script, interpreter will be invoked with the following arguments: `{interpreter [optional-arg] pathname arg...}` where pathname is the pathname of the file specified as the first argument of execve(), and arg... is the series of words pointed to by the argv argument of execve(), starting at argv[1]. Note that there is no way to get the argv[0] that was passed to the execve() call. The changes include: - Separating argument, environment variable, and auxiliary vector processing into a new lwp_args.c file. - Fixing bugs in script argument processing and supporting arguments larger than 4k. - Updating lwp_execve to use the new argscopy function and removing the old lwp_argscopy function. - Making various modifications to lwp_load and elf_aux_fill to work with the new argument processing. - Removing unnecessary code related to dynamic loading and interpreter scripts. Signed-off-by: Shell <[email protected]>
2024-05-31[lwp]list_process can print tid (#8991)rcitachi
* list_process can print tid * fix-ci * update list_process * Update lwp_pid.c
2024-05-30dev: random should copy size bytes of data to buffer (#9012)Shell
2024-05-30[Feature] Support simple power domain API (#9005)GUI
* [Feature] Power domain for device 1.Support device power on/off. 2.Support attach/detach device. 3.Support power domain driver api. Signed-off-by: GuEe-GUI <[email protected]> * [DM/platform] Enhanced platform bus 1.Add power domain for device. 2.Support `remove` and `shutdown` bus interface. Signed-off-by: GuEe-GUI <[email protected]> --------- Signed-off-by: GuEe-GUI <[email protected]>
2024-05-30解决ktime部分函数计算时unsigned long溢出 (#9008)LaterComer
* 解决ktime部分函数计算时unsigned long溢出 * 恢复部分不需要ktime中部分rt_uint64_t类型的为unsigned long
2024-05-29[components][drivers][include][phy] add one more parameter for mulitiple physJiading Xu
- add parameter phy to specify multiple-phy instance Signed-off-by: Jiading Xu <[email protected]>
2024-05-29[smart] fixup errno passing on sys_mkdir() (#9007)Shell
Use _SYS_WRAP to fetch errno on return of mkdir to avoiding overriding of it on other system APIs. Signed-off-by: Shell <[email protected]>
2024-05-29[smart] update sched_setaffinity() to use thread(task) ID (#9004)Shell
Correct `sched_setaffinity()` to use the thread IDs (TIDs) instead of process IDs (PIDs). The previous implementation used PIDs, which caused issues since affinity settings need to be applied at the thread level. As the manual documented, the signature is: > int sched_setaffinity(pid_t pid, size_t cpusetsize, > const cpu_set_t *mask); Yes, it's tricky, the identification passing in is called **'PID'**. But when we talk about 'pid' from GNU libc, it's the **'task-id'**, aka, `thread->tid` known in kernel. Changes were made by updating the function signatures and logic in `lwp.h`, `lwp_pid.c`, and `lwp_syscall.c` to accept TIDs. Specifically, the `lwp_setaffinity` function and related internal functions now operate using thread IDs and adjust thread affinity settings accordingly Signed-off-by: Shell <[email protected]>
2024-05-29[lwp/riscv]进入libc前初始化用户态sp (#8997)heyuanjie87
2024-05-28[OFW] io ranges use list to storage without ofw data (#8993)GUI
[OFW] io ranges use ptr array to storage without ofw data ofw data is private data for every ofw node that the drivers of ofw node will use item. replace the ranges supported to a ptr array. the ptr array size is config by `RT_USING_OFW_BUS_RANGES_NUMBER` Signed-off-by: GuEe-GUI <[email protected]>
2024-05-28[DM/feature] Simple NUMA (Non-Uniform Memory Access) (#9000)GUI
For some CPU memory access devices, that the drivers will find memory and CPU affinity to config device. Signed-off-by: GuEe-GUI <[email protected]>
2024-05-28[smart] add FIONREAD ioctl support for tty (#8996)Shell
Signed-off-by: Shell <[email protected]>
2024-05-28 [PIC] Make affinity helper interface (#8995)GUI
* [PIC] Make affinity helper interface Signed-off-by: GuEe-GUI <[email protected]> * [PIC/GIC] Fixup GIC affinity init GICv2 is not support if current CPU is not startup, but RT-Thread SMP is startup after the devices init in the `main` thread. This patch fixup the cpumask to init once and check the init status in affinity interface. Signed-off-by: GuEe-GUI <[email protected]> --------- Signed-off-by: GuEe-GUI <[email protected]>
2024-05-28[OFW] Support ID map interface (#8994)GUI
The OFW map id is always use in DMA, PCI, IOMMU bus system to find the device identity. this is a access interface. Signed-off-by: GuEe-GUI <[email protected]>
2024-05-28[OFW] Fixup irq parse map and map mask (#8992)GUI
`map_len` and `map_mask_len` is the count of elements, not the bytes size of elements. Signed-off-by: GuEe-GUI <[email protected]>
2024-05-28[Feature] DFS mount auto by kernel parameters (#8989)GUI
DFS mount auto by kernel parameters 1.Mount the rootfs options by parameters: - root=: root device, like vda1, sda1, sd0p1, nvme0n0p1... - rootfstype=: root file system type, like elm, ext, crom... - rw/ro: root is readonly or all enable, if not have 'rw' flag, the 'ro' flag is default. - rootwait: always wait for root device status is OK. - rootdelay=: mount rootfs delay amount of time (millisecond). 2.Mount the other fs options by `fstab.sh`, it will read the script after root mount is OK, it's format is a list of mount cmds in MSH: mount vda2 /mnt elm mount 192.168.1.1:/ /mnt/remote nfs Signed-off-by: GuEe-GUI <[email protected]>
2024-05-27如果申请空间不足,申请不到合适的空间,需要回收new_rbbwinfenggao
2024-05-27[components][drivers][sd] add uhs-i mode support to sd driverFan YANG
- added SDR50, SDR104 and DDR50 support to SD driver Signed-off-by: Fan YANG <[email protected]>
2024-05-26[libcpu] arm: fixup signal handling (#8988)Shell
Signed-off-by: Shell <[email protected]>
2024-05-26[libcpu] discard rt_current_thread (#8976)Shell
* [libcpu] rv64: discard rt_current_thread * arm: using rt_thread_self to fetch current TCB
2024-05-26[components][drivers][mmc] add HS400 support to mmc driverFan YANG
- added HS400 supprt (both eMMC5.0 and eMMC5.1 flavor are supported) Signed-off-by: Fan YANG <[email protected]>
2024-05-21[component][driver]init dm serial naming framework in a separate phase (#8971)zms123456
init dm serial naming framework in a phase
2024-05-21[quality] fixup compiler warning (#8961)Shell
Signed-off-by: Shell <[email protected]>
2024-05-21[dfsv2] fixup out-of-memory access (#8973)Shell
This change addresses a potential out-of-memory access issue in the devfs filesystem component. The issue arises when the `rt_malloc` function allocates memory for a path string without accounting for the null terminator, leading to undefined behavior. As the manual documented: > DESCRIPTION > The strlen() function calculates the length of the string pointed to > by s, excluding the terminating null byte ('\0'). To fix this, the memory allocation size was increased by one byte to ensure space for the null terminator. This prevents potential out-of-memory access and ensures proper string termination. Signed-off-by: Shell <[email protected]>
2024-05-21[components][driver]add isr statistics (#8955)zms123456
add isr statistics
2024-05-17[smart] select console device dynamically (#8949)Shell
* [smart] select console device dynamically - Fixed compiler warning on terminal subsystem for `components/lwp/terminal/terminal.h` - Updated default console setup to dynamically select an appropriate tty device based on the configured console device name. Signed-off-by: Shell <[email protected]> * fixup: remove useless codes --------- Signed-off-by: Shell <[email protected]>
2024-05-16fix specified network card not taking effect with msh's ping error (#8937)xiao-mang
* fix specified network card not taking effect with msh's ping error * fix specified network card not taking effect with msh's ping error
2024-05-16[drivers][serial]fix error in getting serial_tty settings (#8953)zms123456
fix error in getting serial_tty settings
2024-05-13[drivers][ofw] fix ofw_alias_scan() bug (#8908)liYangYang
* fix ofw_alias_scan() bug * fix tag_len
2024-05-11修复C++11 ↵atwww
thread_local对象析构函数与实际内存释放动作顺序相反问题
2024-05-11[components][drivers]fix compiler error in serial dm (#8927)zms123456
fix compiler error in serial dm
2024-05-11[hrtimer] fixup use-after-free (#8928)Shell
Signed-off-by: Shell <[email protected]>
2024-05-10remove intr disablezhao maosheng
2024-05-10add percpu interrupt infozhao maosheng
2024-05-10[smart] fixup arm64 aspace switch (#8925)Shell
* [smart] fixup arm64 aspace switch Signed-off-by: Shell <[email protected]> * fixup: arm add arch_kernel_mmu_table_get --------- Signed-off-by: Shell <[email protected]>
2024-05-09fix_serial_baudrate_setgeniusgogo
2024-05-08[ipc] support of lockless rt_completion (#8887)Shell
* [ipc] lockless rt_completion implementation The new rt_completion implemented by lockless algorithm can improve timer resolution for up to ~12%, compare to sem IPC. Signed-off-by: Shell <[email protected]> * fixup: error * remove useless changes --------- Signed-off-by: Shell <[email protected]>
2024-05-08[libcpu/arm64] dealing with mem region out of kernel space (#8847)Shell
* [ofw] dealing with mem region out of kernel space - Fix parameter checking in _out_of_range() that NULL is excluded for fixed mapping - Split page install with a deferred stage to avoid mapping over ARCH_EARLY_MAP_SIZE Signed-off-by: Shell <[email protected]> * fixup: restrict vstart for using of RT_NULL --------- Signed-off-by: Shell <[email protected]>
2024-05-07fix_serial_baudrate_setgeniusgogo
Signed-off-by: geniusgogo <[email protected]>
2024-05-01[kernel] add rt_thread_close()Shell
* [thread] Add rt_thread_close() This patch introduces a new function `rt_thread_close()` to enhances the usability and maintainability by providing a dedicated mechanism for closing threads. - A new function `rt_thread_close()` is added to the API, providing a standardized approach for closing threads. - The `rt_thread_close()` function removes a thread from the thread queue, updates its status to indicate closure, and performs the thread timer detaching which is a embedded timer in thread object. - Additionally, the `rt_thread_detach()` function is modified to utilize `rt_thread_close()` internally, streamlining the thread detachment process. Signed-off-by: Shell <[email protected]>
2024-04-30Add comments for all functions in components/libc/posix/ipc/mqueue.cTroy
2024-04-29[i2c] adjust the timing for I2C initializationLZerro
2024-04-29[components][drivers] added sensor device lookup functionyiyi
2024-04-29fix baudrate error (#8873)xiao-mang
* fix baudrate error * fix baudrate error * fix baudrate error * fix baudrate error * fix baudrate error * fix baudrate error * fix baudrate error * fix baudrate error * fix baudrate error
2024-04-28fix file mmap (#8865)xiao-mang
2024-04-27[drivers][ofw] Fixed fdt_scan_memory() memory adjustment bug (#8853)liYangYang
* Fixed fdt memory adjustment bug * Modify the memory adjustment logic
2024-04-26Add comments for all functions in components/libc/posix/io/termios/termios.cTroy
2024-04-25fix sys_getcwd (#8852)xiao-mang