rpms/kernel/F-13 kernel.spec, 1.2027, 1.2028 linux-2.6-tracehook.patch, 1.11, 1.12 linux-2.6-utrace-ptrace.patch, 1.2, 1.3 linux-2.6-utrace.patch, 1.121, 1.122
roland
roland at fedoraproject.org
Wed May 12 00:31:54 UTC 2010
Author: roland
Update of /cvs/pkgs/rpms/kernel/F-13
In directory cvs01.phx2.fedoraproject.org:/tmp/cvs-serv23083
Modified Files:
kernel.spec linux-2.6-tracehook.patch
linux-2.6-utrace-ptrace.patch linux-2.6-utrace.patch
Log Message:
utrace update (#590954)
Index: kernel.spec
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/F-13/kernel.spec,v
retrieving revision 1.2027
retrieving revision 1.2028
diff -u -p -r1.2027 -r1.2028
--- kernel.spec 10 May 2010 19:35:41 -0000 1.2027
+++ kernel.spec 12 May 2010 00:31:53 -0000 1.2028
@@ -2205,6 +2205,9 @@ fi
# and build.
%changelog
+* Wed May 12 2010 Roland McGrath <roland at redhat.com>
+- utrace update (#590954)
+
* Mon May 10 2010 Kyle McMartin <kyle at redhat.com>
- don't link binutils against perf. sigh. stupid gpl versions.
@@ -2316,7 +2319,7 @@ fi
* Thu Apr 22 2010 Matthew Garrett <mjg at redhat.com>
- linux-2.6-pci-fixup-resume.patch: Make sure we enable power resources on D0
-* Wed Apr 21 2010 Justin M. Forbes <jforbes at redhat.com>
+* Wed Apr 21 2010 Justin M. Forbes <jforbes at redhat.com>
- vhost-net fixes from upstream
* Wed Apr 21 2010 Roland McGrath <roland at redhat.com> 2.6.33.2-60
linux-2.6-tracehook.patch:
include/linux/ptrace.h | 1 +
include/linux/sched.h | 1 +
include/linux/tracehook.h | 10 +++++-----
kernel/ptrace.c | 2 +-
kernel/signal.c | 4 ++--
5 files changed, 10 insertions(+), 8 deletions(-)
Index: linux-2.6-tracehook.patch
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/F-13/linux-2.6-tracehook.patch,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -p -r1.11 -r1.12
--- linux-2.6-tracehook.patch 11 Jan 2010 19:38:47 -0000 1.11
+++ linux-2.6-tracehook.patch 12 May 2010 00:31:53 -0000 1.12
@@ -106,10 +106,10 @@ index 23bd09c..b7c1d32 100644
__ptrace_unlink(p);
diff --git a/kernel/signal.c b/kernel/signal.c
-index d09692b..9de342f 100644
+index 934ae5e..9551cec 100644
--- a/kernel/signal.c
+++ b/kernel/signal.c
-@@ -1497,7 +1497,7 @@ int do_notify_parent(struct task_struct
+@@ -1498,7 +1498,7 @@ int do_notify_parent(struct task_struct
return ret;
}
@@ -118,7 +118,7 @@ index d09692b..9de342f 100644
{
struct siginfo info;
unsigned long flags;
-@@ -1767,7 +1767,7 @@ static int do_signal_stop(int signr)
+@@ -1768,7 +1768,7 @@ static int do_signal_stop(int signr)
static int ptrace_signal(int signr, siginfo_t *info,
struct pt_regs *regs, void *cookie)
{
linux-2.6-utrace-ptrace.patch:
include/linux/ptrace.h | 2
kernel/Makefile | 1
kernel/ptrace-utrace.c | 1080 +++++++++++++++++++++++++++++++++++++++++++++++++
kernel/ptrace.c | 597 +++++++++++++--------------
kernel/utrace.c | 16
5 files changed, 1391 insertions(+), 305 deletions(-)
Index: linux-2.6-utrace-ptrace.patch
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/F-13/linux-2.6-utrace-ptrace.patch,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -p -r1.2 -r1.3
--- linux-2.6-utrace-ptrace.patch 18 Dec 2009 09:56:47 -0000 1.2
+++ linux-2.6-utrace-ptrace.patch 12 May 2010 00:31:53 -0000 1.3
@@ -1,17 +1,16 @@
-utrace: ptrace cooperation
+implement utrace-ptrace
-This adds the CONFIG_UTRACE_PTRACE option under CONFIG_UTRACE.
-When set, parts of ptrace are replaced so it uses the utrace
-facilities for noticing events, stopping and resuming threads.
+The patch adds the new file, kernel/ptrace-utrace.c, which contains
+the new implementation of ptrace over utrace.
-This makes ptrace play nicely with other utrace-based things
-tracing the same threads. It also makes all ptrace uses rely on
-some of the utrace code working right, even when you are not
-using any other utrace-based things. So it's experimental and
-not real well proven yet. But it's recommended if you enable
-CONFIG_UTRACE and want to try new utrace things.
+This file is not compiled until we have CONFIG_UTRACE option, will be
+added by the next "utrace core" patch.
+
+It's supposed to be an invisible implementation change, nothing should
+change to userland when CONFIG_UTRACE is enabled.
Signed-off-by: Roland McGrath <roland at redhat.com>
+Signed-off-by: Oleg Nesterov <oleg at redhat.com>
---
include/linux/ptrace.h | 2 +-
kernel/Makefile | 1 +
@@ -34,10 +33,10 @@ index 4802e2a..03f8fc7 100644
extern int ptrace_traceme(void);
extern int ptrace_readdata(struct task_struct *tsk, unsigned long src, char __user *dst, int len);
diff --git a/kernel/Makefile b/kernel/Makefile
-index 263bb19..42cb1ec 100644
+index 8a0185e..30a118d 100644
--- a/kernel/Makefile
+++ b/kernel/Makefile
-@@ -69,6 +69,7 @@ obj-$(CONFIG_RESOURCE_COUNTERS) += res_c
+@@ -70,6 +70,7 @@ obj-$(CONFIG_RESOURCE_COUNTERS) += res_c
obj-$(CONFIG_STOP_MACHINE) += stop_machine.o
obj-$(CONFIG_KPROBES_SANITY_TEST) += test_kprobes.o
obj-$(CONFIG_UTRACE) += utrace.o
@@ -1798,7 +1797,7 @@ index a408bf7..4e87441 100644
#endif /* CONFIG_COMPAT */
+#endif /* CONFIG_UTRACE */
diff --git a/kernel/utrace.c b/kernel/utrace.c
-index 84d965d..ead1f13 100644
+index f003e34..f5a9e2c 100644
--- a/kernel/utrace.c
+++ b/kernel/utrace.c
@@ -811,6 +811,22 @@ relock:
linux-2.6-utrace.patch:
Documentation/DocBook/Makefile | 2
Documentation/DocBook/utrace.tmpl | 590 +++++++++
fs/proc/array.c | 3
include/linux/sched.h | 5
include/linux/tracehook.h | 87 +
include/linux/utrace.h | 692 ++++++++++
init/Kconfig | 9
kernel/Makefile | 1
kernel/fork.c | 3
kernel/ptrace.c | 14
kernel/utrace.c | 2436 ++++++++++++++++++++++++++++++++++++++
11 files changed, 3840 insertions(+), 2 deletions(-)
Index: linux-2.6-utrace.patch
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/F-13/linux-2.6-utrace.patch,v
retrieving revision 1.121
retrieving revision 1.122
diff -u -p -r1.121 -r1.122
--- linux-2.6-utrace.patch 11 Jan 2010 19:38:47 -0000 1.121
+++ linux-2.6-utrace.patch 12 May 2010 00:31:53 -0000 1.122
@@ -35,8 +35,8 @@ Signed-off-by: Roland McGrath <roland at re
kernel/Makefile | 1 +
kernel/fork.c | 3 +
kernel/ptrace.c | 14 +
- kernel/utrace.c | 2427 +++++++++++++++++++++++++++++++++++++
- 11 files changed, 3831 insertions(+), 2 deletions(-)
+ kernel/utrace.c | 2436 +++++++++++++++++++++++++++++++++++++
+ 11 files changed, 3840 insertions(+), 2 deletions(-)
diff --git a/Documentation/DocBook/Makefile b/Documentation/DocBook/Makefile
index 325cfd1..a45e4e6 100644
@@ -648,7 +648,7 @@ index ...e149f49 100644
+
+</book>
diff --git a/fs/proc/array.c b/fs/proc/array.c
-index f560325..2805b44 100644
+index 13b5d07..cda9489 100644
--- a/fs/proc/array.c
+++ b/fs/proc/array.c
@@ -82,6 +82,7 @@
@@ -1621,10 +1621,10 @@ index ...f251efe 100644
+
+#endif /* linux/utrace.h */
diff --git a/init/Kconfig b/init/Kconfig
-index a23da9f..9bbc195 100644
+index d95ca7c..6d52a08 100644
--- a/init/Kconfig
+++ b/init/Kconfig
-@@ -310,6 +310,15 @@ config AUDIT_TREE
+@@ -320,6 +320,15 @@ config AUDIT_TREE
depends on AUDITSYSCALL
select INOTIFY
@@ -1721,14 +1721,14 @@ index b7c1d32..a408bf7 100644
if (!current->ptrace) {
diff --git a/kernel/utrace.c b/kernel/utrace.c
new file mode 100644
-index ...84d965d 100644
+index ...f003e34 100644
--- /dev/null
+++ b/kernel/utrace.c
-@@ -0,0 +1,2427 @@
+@@ -0,0 +1,2436 @@
+/*
+ * utrace infrastructure interface for debugging user processes
+ *
-+ * Copyright (C) 2006-2009 Red Hat, Inc. All rights reserved.
++ * Copyright (C) 2006-2010 Red Hat, Inc. All rights reserved.
+ *
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
@@ -2570,6 +2570,7 @@ index ...84d965d 100644
+ bool reap)
+{
+ struct utrace_engine *engine, *next;
++ struct list_head attached;
+
+ spin_lock(&utrace->lock);
+
@@ -2608,16 +2609,24 @@ index ...84d965d 100644
+ }
+
+ /*
-+ * utrace_add_engine() checks ->utrace_flags != 0.
-+ * Since @utrace->reap is set, nobody can set or clear
-+ * UTRACE_EVENT(REAP) in @engine->flags or change
-+ * @engine->ops, and nobody can change @utrace->attached.
++ * utrace_add_engine() checks ->utrace_flags != 0. Since
++ * @utrace->reap is set, nobody can set or clear UTRACE_EVENT(REAP)
++ * in @engine->flags or change @engine->ops and nobody can change
++ * @utrace->attached after we drop the lock.
+ */
+ target->utrace_flags = 0;
-+ splice_attaching(utrace);
++
++ /*
++ * We clear out @utrace->attached before we drop the lock so
++ * that find_matching_engine() can't come across any old engine
++ * while we are busy tearing it down.
++ */
++ list_replace_init(&utrace->attached, &attached);
++ list_splice_tail_init(&utrace->attaching, &attached);
++
+ spin_unlock(&utrace->lock);
+
-+ list_for_each_entry_safe(engine, next, &utrace->attached, entry) {
++ list_for_each_entry_safe(engine, next, &attached, entry) {
+ if (engine->flags & UTRACE_EVENT(REAP))
+ engine->ops->report_reap(engine, target);
+
More information about the scm-commits
mailing list