lkml.org 
[lkml]   [2009]   [Apr]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 2/4] ftrace: introduce workqueue_handler_exit tracepoint and rename workqueue_execution to workqueue_handler_entry

* Oleg Nesterov <oleg@redhat.com> wrote:

> > > lock_map_acquire(&lockdep_map);
> > > + trace_workqueue_handler_entry(cwq->thread, work);
> > > f(work);
> > > + trace_workqueue_handler_exit(cwq->thread, work);
>
> This doesn't look right. We must not use "work" after f(work).
> work->func() can kfree its work.

We can use it as long as we use it as a 'cookie' - i.e. an
identifier for visualization/statistics, but dont actually
dereference it, right?

Ingo


\
 
 \ /
  Last update: 2009-04-15 13:13    [W:0.276 / U:0.888 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site