Linus,

Please pull the latest perf-urgent-for-linus git tree from:

   git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git 
perf-urgent-for-linus

   HEAD: c79aa0d96548aee50570209eb2d45c8f4ac49230 events: Protect access via 
task_subsys_state_check()

This fix adds missing RCU read protection.

 Thanks,

        Ingo

------------------>
Paul E. McKenney (1):
      events: Protect access via task_subsys_state_check()


 kernel/events/core.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/kernel/events/core.c b/kernel/events/core.c
index 4d3124b..9fcb094 100644
--- a/kernel/events/core.c
+++ b/kernel/events/core.c
@@ -4596,6 +4596,7 @@ void perf_event_comm(struct task_struct *task)
        struct perf_event_context *ctx;
        int ctxn;
 
+       rcu_read_lock();
        for_each_task_context_nr(ctxn) {
                ctx = task->perf_event_ctxp[ctxn];
                if (!ctx)
@@ -4603,6 +4604,7 @@ void perf_event_comm(struct task_struct *task)
 
                perf_event_enable_on_exec(ctx);
        }
+       rcu_read_unlock();
 
        if (!atomic_read(&nr_comm_events))
                return;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to