Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:kill_something_info() interprets pid in interesting ways just like kill(2).* POSIX specifies that kill(-1,sig) is unspecified, but what we have* is probably wrong. Should make it like BSD or SYSV.

Proto:static int kill_something_info(int sig, struct kernel_siginfo *info, pid_t pid)

Type:int

Parameter:

TypeParameterName
intsig
struct kernel_siginfo *info
pid_tpid
1555  If pid > 0 Then
1556  _read_lock() - mark the beginning of an RCU read-side critical section* When synchronize_rcu() is invoked on one CPU while other CPUs* are within RCU read-side critical sections, then the* synchronize_rcu() is guaranteed to block until after all the other
1557  ret = kill_pid_info(sig, info, find_vpid(pid))
1558  _read_unlock() - marks the end of an RCU read-side critical section.* In most situations, rcu_read_unlock() is immune from deadlock.* However, in kernels built with CONFIG_RCU_BOOST, rcu_read_unlock()
1559  Return ret
1563  If pid == INT_MIN Then Return -ESRCH
1566  read_lock( & tasklist_lock)
1567  If pid != -1 Then
1568  ret = __kill_pgrp_info() sends a signal to a process group: this is what the tty* control characters do (^C, ^Z etc)* - the caller must hold at least a readlock on tasklist_lock
1570  Else
1571  retval = 0 , count = 0
1575  If task_pid_vnr(p) > 1 && Not same_thread_group(p, current process) Then
1579  ++count
1580  If err != -EPERM Then retval = err
1584  ret = If count Then retval Else -ESRCH
1586  read_unlock( & tasklist_lock)
1588  Return ret
Caller
NameDescribe
SYSCALL_DEFINE2sys_kill - send a signal to a process*@pid: the PID of the process*@sig: signal to be sent