* Purpose of PTRACE_SETSIGINFO for x86
@ 2018-12-14 22:30 Okash Khawaja
0 siblings, 0 replies; only message in thread
From: Okash Khawaja @ 2018-12-14 22:30 UTC (permalink / raw)
To: kernelnewbies
Hi,
What does the PTRACE_SETSIGINFO ptrace command do?
I can see in kernel/ptrace.c:ptrace_request() it calls
ptrace_setsiginfo(), passing it the child's (tracee's) task descriptor
and siginfo_t instance originally passed in from user space.
ptrace_setsiginfo() sets child's last_siginfo to the siginfo_t
instance passed in. Now there are only two places where a
child->last_siginfo's value is read are in kernel/ptrace.c:
1. by the ptrace command PTRACE_GETSIGINFO
2. by the ptrace command PTRACE_LISTEN
There doesn't seem to be a place where value of last_siginfo is read
by signal handling code. There is however this comment in
kernel/signal.c:ptrace_signal():
/*
* Update the siginfo structure if the signal has
* changed. If the debugger wanted something
* specific in the siginfo structure then it should
* have updated *info via PTRACE_SETSIGINFO.
*/
Where does PTRACE_SETSIGINFO update *info?
Thanks,
Okash
_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2018-12-14 22:32 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-14 22:30 Purpose of PTRACE_SETSIGINFO for x86 Okash Khawaja
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).