lkml.org 
[lkml]   [2002]   [Sep]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] LTT for 2.5.38 1/9: Core infrastructure

On Sun, 22 Sep 2002, Karim Yaghmour wrote:

> Ingo Molnar wrote:
> > +int trace_event(u8 pm_event_id,
> > + void *pm_event_struct)
> > [...]
> > + read_lock(&tracer_register_lock);
> >
> > ie. it's using a global spinlock. (sure, it can be made lockless, as other
> > tracers have done it.)
>
> It is, but this is separate from the trace driver. [...]

it does not matter, it's called for every event.

> [...] This global spinlock is only used to avoid a race condition in the
> registration/ unregistration of the tracing function with the trace
> infrastructure.

(here you make the incorrect assumption that read-locking a rwlock is a
lightweight operation.)

Ingo

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:29    [W:0.092 / U:0.440 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site