All of lore.kernel.org
 help / color / mirror / Atom feed
From: Neil Horman <nhorman@tuxdriver.com>
To: Eric Dumazet <eric.dumazet@gmail.com>
Cc: netdev@vger.kernel.org, David Miller <davem@davemloft.net>
Subject: Re: [PATCH v2 1/2] drop_monitor: fix sleeping in invalid context warning
Date: Sat, 28 Apr 2012 10:30:22 -0400	[thread overview]
Message-ID: <20120428143022.GA5944@hmsreliant.think-freely.org> (raw)
In-Reply-To: <1335593473.2900.0.camel@edumazet-glaptop>

On Sat, Apr 28, 2012 at 08:11:13AM +0200, Eric Dumazet wrote:
> On Fri, 2012-04-27 at 16:11 -0400, Neil Horman wrote:
> > Eric Dumazet pointed out this warning in the drop_monitor protocol to me:
> > 
> 
> > It stems from holding a spinlock (trace_state_lock) while attempting to register
> > or unregister tracepoint hooks, making in_atomic() true in this context, leading
> > to the warning when the tracepoint calls might_sleep() while its taking a mutex.
> > Since we only use the trace_state_lock to prevent trace protocol state races, as
> > well as hardware stat list updates on an rcu write side, we can just convert the
> > spinlock to a mutex to avoid this problem.
> > 
> > Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
> > Reported-by: Eric Dumazet <eric.dumazet@gmail.com>
> > CC: David Miller <davem@davemloft.net>
> > ---
> 
> Acked-by: Eric Dumazet <edumazet@google.com>
> 
> Thanks Neil
> 
Anytmie, thanks for reporting it.
Neil

> 
> 
> 

  reply	other threads:[~2012-04-28 14:30 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-26 18:47 [PATCH 0/2] drop_monitor: misc fixes for some recently reported bugs Neil Horman
2012-04-26 18:47 ` [PATCH 1/2] drop_monitor: fix sleeping in invalid context warning Neil Horman
2012-04-26 19:01   ` Eric Dumazet
2012-04-26 19:21     ` Neil Horman
2012-04-26 18:47 ` [PATCH 2/2] drop_monitor: Make updating data->skb smp safe Neil Horman
2012-04-26 19:00   ` Eric Dumazet
2012-04-26 19:18     ` Neil Horman
2012-04-26 19:25       ` Eric Dumazet
2012-04-27 20:11 ` [PATCH v2 0/2] drop_monitor: misc fixes for some recently reported bugs Neil Horman
2012-04-27 20:11   ` [PATCH v2 1/2] drop_monitor: fix sleeping in invalid context warning Neil Horman
2012-04-28  6:11     ` Eric Dumazet
2012-04-28 14:30       ` Neil Horman [this message]
2012-04-27 20:11   ` [PATCH v2 2/2] drop_monitor: Make updating data->skb smp safe Neil Horman
2012-04-28  6:13     ` Eric Dumazet
2012-06-04  7:45     ` Eric Dumazet
2012-06-04 10:39       ` Neil Horman
2012-04-28  6:19   ` [PATCH v2 0/2] drop_monitor: misc fixes for some recently reported bugs David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20120428143022.GA5944@hmsreliant.think-freely.org \
    --to=nhorman@tuxdriver.com \
    --cc=davem@davemloft.net \
    --cc=eric.dumazet@gmail.com \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.