svn commit: r231887 - in stable/9/sys: kern sys
Konstantin Belousov
kib at FreeBSD.org
Sat Feb 18 00:45:59 UTC 2012
Author: kib
Date: Sat Feb 18 00:45:59 2012
New Revision: 231887
URL: http://svn.freebsd.org/changeset/base/231887
Log:
MFC r231521:
The PTRACESTOP() macro is used only once. Inline the only use and remove
the macro.
Modified:
stable/9/sys/kern/subr_syscall.c
stable/9/sys/sys/ptrace.h
Directory Properties:
stable/9/sys/ (props changed)
Modified: stable/9/sys/kern/subr_syscall.c
==============================================================================
--- stable/9/sys/kern/subr_syscall.c Sat Feb 18 00:35:23 2012 (r231886)
+++ stable/9/sys/kern/subr_syscall.c Sat Feb 18 00:45:59 2012 (r231887)
@@ -85,7 +85,11 @@ syscallenter(struct thread *td, struct s
if (error == 0) {
STOPEVENT(p, S_SCE, sa->narg);
- PTRACESTOP_SC(p, td, S_PT_SCE);
+ if (p->p_flag & P_TRACED && p->p_stops & S_PT_SCE) {
+ PROC_LOCK(p);
+ ptracestop((td), SIGTRAP);
+ PROC_UNLOCK(p);
+ }
if (td->td_dbgflags & TDB_USERWR) {
/*
* Reread syscall number and arguments if
Modified: stable/9/sys/sys/ptrace.h
==============================================================================
--- stable/9/sys/sys/ptrace.h Sat Feb 18 00:35:23 2012 (r231886)
+++ stable/9/sys/sys/ptrace.h Sat Feb 18 00:45:59 2012 (r231887)
@@ -131,12 +131,6 @@ struct ptrace_vm_entry {
#ifdef _KERNEL
-#define PTRACESTOP_SC(p, td, flag) \
- if ((p)->p_flag & P_TRACED && (p)->p_stops & (flag)) { \
- PROC_LOCK(p); \
- ptracestop((td), SIGTRAP); \
- PROC_UNLOCK(p); \
- }
/*
* The flags below are used for ptrace(2) tracing and have no relation
* to procfs. They are stored in struct proc's p_stops member.
More information about the svn-src-stable-9
mailing list