On Thu, Aug 01, 2013 at 03:32:17PM +0200, Jiri Olsa wrote:
> On Thu, Aug 01, 2013 at 03:28:34PM +0200, Frederic Weisbecker wrote:
> 
> SNIP
> 
> > > also for following case:
> > > 
> > >         count = atomic_inc_return(&nr_callchain_events);
> > >         if (WARN_ON_ONCE(count < 1)) {
> > >                 err = -EINVAL;
> > >                 goto exit;
> > >         }
> > > 
> > > seems like it screws the count
> > 
> > I'm not sure what you mean here. You mean that it could be negative when 
> > the dec is done
> > outside the lock?
> 
> yes
> 

I don't understand why.
--
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