Refer to issue #8867 for details and rational.
Convert sigset_t to an array type so that more than 32 signals can be supported.
Why not use a uin64_t?
- Using a uin32_t is more flexible if we decide to increase the number of signals beyound 64.
- 64-bit accesses are not atomic, at least not on 32-bit ARMv7-M and similar
- Keeping the base type as uint32_t does not introduce additional overhead due to padding to achieve 64-bit alignment of uin64_t
- Some architectures still supported by NuttX do not support uin64_t
types,
Increased the number of signals to 64. This matches Linux. This will support all xsignals defined by Linux and also 32 real time signals (also like Linux).
This is is a work in progress; a draft PR that you are encouraged to comment on.
There are number problems with the implementation of realtime signals in NuttX as discussed in Issue #8869. A first step to correcting any of these is to correct the definitions of SIGRTMIN, SIGRTMAX, and RTSIG_SIX.
SIGRTMIN is the first real-time signals. Real-time signal numbers must not overlap the standard signal numbers. Before this fix, it was set equal to the first standard signal. Real-time signals differ from standard signals in that (1) they have no default actions, and (2) real time signal actions are prioritized whereas standard signal actions are processed FIFO.
SIGRTMAX is the last real-time signal.
RTSIG_MAX must be set equal to maximum number of realtime signals reserved for application use
The change corrects the definitons but has not impact at all becasuse none of there definitions are currently used in the OS. But they will be when prioritized real time signal handling is implemented.
ptrdiff_t is defined as intptr_t that is defined as _ssize_t in Nuttx.
The real size depends on architecture and the PTR_MAX and PTR_MIN is
specified by it.
Note: this patch can get file path from root pseudo file handle,
but a general infrastructure is setup for other file system too.
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I86cd79ebb741f2f43fdd398bb7498c40687d949b
from https://pubs.opengroup.org/onlinepubs/007904875/functions/setpriority.html:
1.The nice value shall in the range [-{NZERO},{NZERO} -1]
2.Lower nice value shall cause more favorable scheduling
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I5ad60d92abc3b69fbaa406da68cec2e40ca3fa6d
1.Reduce the default size of task_group_s(~512B each task)
2.Scale better between simple and complex application
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ia872137504fddcf64d89c48d6f0593d76d582710
- Numbered arguments now work by using two pass parsing and an argument list.
The maximum number of numbered args is determined by CONFIG_LIBC_NL_ARGMAX
which is then copied into NL_ARGMAX.
- Size of pointer argument ('p') is determined before output.
include/limits.h: Define NL_ARGMAX (as well as some of the other 'invariant
values' per http://pubs.opengroup.org/onlinepubs/7908799/xsh/limits.h.html)