mirror of https://github.com/mkerrisk/man-pages
ptrace.2: Reworking of Andrey's patches
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
parent
9a36b8fca0
commit
83894d15e2
|
@ -41,7 +41,7 @@
|
||||||
.\" (Thanks to Blaisorblade, Daniel Jacobowitz and others who helped.)
|
.\" (Thanks to Blaisorblade, Daniel Jacobowitz and others who helped.)
|
||||||
.\" 2011-09, major update by Denys Vlasenko <vda.linux@googlemail.com>
|
.\" 2011-09, major update by Denys Vlasenko <vda.linux@googlemail.com>
|
||||||
.\"
|
.\"
|
||||||
.TH PTRACE 2 2013-07-11 "Linux" "Linux Programmer's Manual"
|
.TH PTRACE 2 2014-01-20 "Linux" "Linux Programmer's Manual"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
ptrace \- process trace
|
ptrace \- process trace
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
@ -325,51 +325,57 @@ structures without removing signals from a queue.
|
||||||
.I addr
|
.I addr
|
||||||
points to a
|
points to a
|
||||||
.I ptrace_peeksiginfo_args
|
.I ptrace_peeksiginfo_args
|
||||||
structure.
|
structure that specifies the ordinal position from which
|
||||||
|
copying of signals should start,
|
||||||
|
and the number of signals to copy.
|
||||||
.I siginfo_t
|
.I siginfo_t
|
||||||
structures are copied into the buffer starting at
|
structures are copied into the buffer pointed to by
|
||||||
.I data.
|
.IR data .
|
||||||
The return value contains a number of copied signals (zero indicates
|
The return value contains the number of copied signals (zero indicates
|
||||||
that a signal with this sequence number doesn't exist).
|
that there is no signal corresponding to the specified ordinal position).
|
||||||
A result
|
Within the returned
|
||||||
.I siginfo
|
.I siginfo
|
||||||
contains a kernel part of
|
structures,
|
||||||
|
the
|
||||||
.IR si_code
|
.IR si_code
|
||||||
(
|
field includes information
|
||||||
.BR __SI_CHLD,
|
.RB ( __SI_CHLD ,
|
||||||
.BR __SI_FAULT,
|
.BR __SI_FAULT ,
|
||||||
etc), which is not shown in other places.
|
etc.), that are not otherwise exposed to user space.
|
||||||
.PP
|
.PP
|
||||||
.in +10n
|
.in +10n
|
||||||
.nf
|
.nf
|
||||||
struct ptrace_peeksiginfo_args {
|
struct ptrace_peeksiginfo_args {
|
||||||
u64 off; /* from which siginfo to start */
|
u64 off; /* Ordinal position in queue at which
|
||||||
u32 flags;
|
to start copying signals */
|
||||||
s32 nr; /* how may siginfos to take */
|
u32 flags; /* PTRACE_PEEKSIGINFO_SHARED or 0 */
|
||||||
|
s32 nr; /* Number of signals to copy */
|
||||||
};
|
};
|
||||||
.fi
|
.fi
|
||||||
|
|
||||||
Currently here is only one flag
|
Currently, there is only one flag,
|
||||||
.BR PTRACE_PEEKSIGINFO_SHARED
|
.BR PTRACE_PEEKSIGINFO_SHARED ,
|
||||||
for dumping signals from process-wide queue.
|
for dumping signals from the process-wide signal queue.
|
||||||
If this flag is not set, signals are read from a per-thread queue.
|
If this flag is not set,
|
||||||
|
signals are read from the per-thread queue of the specified thread.
|
||||||
.in
|
.in
|
||||||
.PP
|
.PP
|
||||||
.TP
|
.TP
|
||||||
.BR PTRACE_GETSIGMASK " (since Linux 3.11)"
|
.BR PTRACE_GETSIGMASK " (since Linux 3.11)"
|
||||||
.\" commit 29000caecbe87b6b66f144f72111f0d02fbbf0c1
|
.\" commit 29000caecbe87b6b66f144f72111f0d02fbbf0c1
|
||||||
Retrieve mask of blocked signals to the address
|
Place a copy of the mask of blocked signals in the buffer pointed to by
|
||||||
.I data.
|
.IR data .
|
||||||
The
|
The
|
||||||
.I addr
|
.I addr
|
||||||
argument contains the size of mask.
|
argument contains the size of mask.
|
||||||
.TP
|
.TP
|
||||||
.BR PTRACE_SETSIGMASK " (since Linux 3.11)"
|
.BR PTRACE_SETSIGMASK " (since Linux 3.11)"
|
||||||
Change mask of blocked signals from the address
|
Change the mask of blocked signals to the value specified
|
||||||
.I data.
|
in the buffer pointed to by
|
||||||
|
.IR data .
|
||||||
The
|
The
|
||||||
.I addr
|
.I addr
|
||||||
argument contains the size of mask.
|
argument contains the size of the mask.
|
||||||
.TP
|
.TP
|
||||||
.BR PTRACE_SETOPTIONS " (since Linux 2.4.6; see BUGS for caveats)"
|
.BR PTRACE_SETOPTIONS " (since Linux 2.4.6; see BUGS for caveats)"
|
||||||
Set ptrace options from
|
Set ptrace options from
|
||||||
|
|
Loading…
Reference in New Issue