Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\signal.c Create Date:2022-07-28 09:17:45
Last Modify:2020-03-17 13:28:47 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:do_sigaction

Proto:int do_sigaction(int sig, struct k_sigaction *act, struct k_sigaction *oact)

Type:int

Parameter:

TypeParameterName
intsig
struct k_sigaction *act
struct k_sigaction *oact
3951  p = current process
3955  If Not Test if 'sig' is valid signal. Use this instead of testing _NSIG directly || sig < 1 || act && sig_kernel_only(sig) Then Return -EINVAL
3958  k = action[sig - 1]
3960  spin_lock_irq( & siglock)
3961  If oact Then oact = k
3964  sigaction_compat_abi(act, oact)
3966  If act Then
3967  sigdelsetmask( & mask last for extensibility , sigmask(SIGKILL) | sigmask(SIGSTOP))
3969  k = act
3981  If sig_handler_ignored(sig_handler(p, sig), sig) Then
3982  sigemptyset( & mask)
3985  for_each_thread(p, t)
3990  spin_unlock_irq( & siglock)
3991  Return 0
Caller
NameDescribe
SYSCALL_DEFINE4sys_rt_sigaction - alter an action taken by a process*@sig: signal to be sent*@act: new sigaction*@oact: used to save the previous sigaction*@sigsetsize: size of sigset_t type
COMPAT_SYSCALL_DEFINE4
SYSCALL_DEFINE2For backwards compatibility. Functionality superseded by sigaction.