by index or address
- dns_del_nameserver()
- dns_del_nameserver_by_index()
Update the "DNS function" section in 11_network.rst, and create
the netlib API documentation in netlib/index.rst
Signed-off-by: nuttxs <zhaoqing.zhang@sony.com>
Fix an issue on ARMv8-R where NEON is not supported.
When NEON is disabled, the assembly-optimized implementations
of memset and memcpy should not be used.
Signed-off-by: Chengdong Wang <wangchengdong@lixiang.com>
remove not related comments from libs/libbuiltin/CMakeLists.txt and
libs/libxx/CMakeLists.txt. These are a copy paste from a Makefile
which doesn't make sense for these files.
Signed-off-by: raiden00pl <raiden00@railab.me>
remove reference to non-existent readme in libc.
Pointing to the documentation page doesn't make sense in this case,
because it doesn't explain the use of `#undef XXX` for this case anyway.
Signed-off-by: raiden00pl <raiden00@railab.me>
When key is deleted, its value should also be reset.
This fixes the pthread_getspecific.c test case from
PSE52 Open Group Threads Test Suite.
Signed-off-by: p-szafonimateusz <p-szafonimateusz@xiaomi.com>
Add crc8rohcincr() function to support byte-by-byte CRC8 calculation
using the ROHC polynomial (0x07) without XOR inversions. This is
useful for protocols that require incremental CRC accumulation,
such as GSM 07.10 (CMUX), where the CRC must be computed as frames
are parsed from circular buffers.
Changes include:
- New crc8rohcincr() function for single-byte incremental CRC
- Function takes current CRC value and returns updated CRC
- Uses same g_crc8_tab table as other ROHC functions
- No XOR inversions applied for proper accumulation
This allows protocols like CMUX to replace local CRC table
implementations with standard libc CRC functions while maintaining
correct incremental calculation behavior.
Signed-off-by: Halysson <halysson1007@gmail.com>
Check that the provided stream pointer is really opened for the group before
closing & freeing it.
Signed-off-by: Jukka Laitinen <jukka.laitinen@tii.ae>
Curernt implementation default semaphore max allowed value to SEM_VALUE_MAX.
In some cases, user may want to change this, so provide a function to do this: sem_setmaxvalue
Signed-off-by: Chengdong Wang <wangchengdong@lixiang.com>
Add support for pthread_{get|set}concurrency support.
NuttX uses 1:1 threading model (every pthread is a kernel-managed thread),
so this function has no real effect on the scheduling behavior.
Signed-off-by: p-szafonimateusz <p-szafonimateusz@xiaomi.com>
This commit adds simple implementation of guardsize for pthreads.
At this moment this option simply increases the size of allocated pthread stack.
At default pthread guard size is set to 0.
Signed-off-by: p-szafonimateusz <p-szafonimateusz@xiaomi.com>
Prior to this commit, it wasn't possible to load ELF modules from
the external PSRAM. There were two main issues about it: 1) copying
data using the instruction bus was being used instead of the data
bus (this, per si, isn't a problem, but requires special attention
regarding data alignment), and 2) the cache was not being properly
cleaned and flushed to properly access the loaded data using the
instruction bus.
Signed-off-by: Tiago Medicci Serrano <tiago.medicci@espressif.com>
1. Adopt an exponential backoff strategy () to dynamically adjust the timeout
duration, which is suitable for retry scenarios.
2. Optimize the default configuration to set the initial timeout to 5 seconds.
3. Support dynamic modification of the maximum timeout limit to adapt
to different scenarios.
Reference: RFC 1536 (section on retransmission implementation recommendations)
Signed-off-by: nuttxs <zhaoqing.zhang@sony.com>
This reverts commit 8f96e59aee.
The implementation of __dso_handle is independent of the HOST OS but dependent on the specific compiler.
Therefore, this patch will cause compilation failures for other cross-compilers on the Windows platform, such as arm-none-eabi-gcc and aarch64-none-elf-gcc.
Constraints should be applied to compiler target rather than compiler host.
idr_destroy() would loop over the removed and alloced
RB tree nodes freeing them but not removing them from
the trees. From the perspective of the RB tree those
nodes would remain valid, while in fact, they were free
memory, potentially reallocated for other purposes, or
otherwise overwritten by the allocator with metadata.
This would cause (seemingly random) memory corruption
crashes triggered by the RB tree code trying to access
link fields from the free'd nodes.
Fix that by removing the nodes before freeing them.
Signed-off-by: George Poulios <gpoulios@census-labs.com>
If atomic_try_cmpxchg_xxxx runs on LL/SC architectures (e.g.ARMv7,
ARMv8, RISC-V), the weak CAS expands to a single LDREX/STREX pair.
If the CPU takes an IRQ/FIQ/SVC between the two instructions,
hardware performs an implicit CLREX and the following STREX returns
1, therefore atomic_try_cmpxchg_xxxx return failure even though
*addr* still holds the expected value.
So let's retry atomic_try_cmpxchg_xxxx in this case.
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
All implementations of gcov are sunk to the kernel implementation
1. Support three dump modes: serial port output, single file output, standard output
Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
Bringing the code coverage option when linking may cause gcc or g++ to automatically link the libgcov.a that comes with the toolchain.
Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
if dns_recv_response() fails, dns_bind() is called again at try_stream to
create a new socket. However, the original socket descriptor sd isn't closed
Signed-off-by: nuttxs <zhaoqing.zhang@sony.com>
follow up this change:
commit 84dc88730c
Author: Xiang Xiao <xiaoxiang@xiaomi.com>
Date: Mon Jun 9 14:39:03 2025 +0800
libc: Move stream printf/scanf from libc/stdio to libc/stream
to keep all related code in one place
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit adds support for the `lib_scanf` function, which
is a stream-oriented version of the `scanf` function.
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>