This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug runtime/17052] race between _stp_ctl_work_callback and _stp_runtime_contexts_free


https://sourceware.org/bugzilla/show_bug.cgi?id=17052

--- Comment #1 from Josh Stone <jistone at redhat dot com> ---
I was speculating a little bit about the root cause, so here's some
confirmation.

--- a/runtime/linux/runtime_context.h
+++ b/runtime/linux/runtime_context.h
@@ -38,6 +38,7 @@ static void _stp_runtime_contexts_free(void)
        for_each_possible_cpu(cpu) {
                if (contexts[cpu] != NULL) {
                        _stp_vfree(contexts[cpu]);
+                       ssleep(1);
                        contexts[cpu] = NULL;
                }
        }

Adding this delay between free and NULL makes sure we get a timer in the
meantime, and indeed this triggers the same panic.

-- 
You are receiving this mail because:
You are the assignee for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]