All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: eric.dumazet@gmail.com
Cc: xiyou.wangcong@gmail.com, edumazet@google.com,
	dvyukov@google.com, netdev@vger.kernel.org
Subject: Re: [PATCH net] net: use a work queue to defer net_disable_timestamp() work
Date: Fri, 03 Feb 2017 16:18:16 -0500 (EST)	[thread overview]
Message-ID: <20170203.161816.1608140108344194361.davem@davemloft.net> (raw)
In-Reply-To: <1486060295.21871.19.camel@edumazet-glaptop3.roam.corp.google.com>

From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Thu, 02 Feb 2017 10:31:35 -0800

> From: Eric Dumazet <edumazet@google.com>
> 
> Dmitry reported a warning [1] showing that we were calling 
> net_disable_timestamp() -> static_key_slow_dec() from a non
> process context.
> 
> Grabbing a mutex while holding a spinlock or rcu_read_lock()
> is not allowed.
> 
> As Cong suggested, we now use a work queue.
> 
> It is possible netstamp_clear() exits while netstamp_needed_deferred
> is not zero, but it is probably not worth trying to do better than that.
> 
> netstamp_needed_deferred atomic tracks the exact number of deferred
> decrements.
 ...
> Fixes: b90e5794c5bd ("net: dont call jump_label_dec from irq context")
> Suggested-by: Cong Wang <xiyou.wangcong@gmail.com>
> Reported-by: Dmitry Vyukov <dvyukov@google.com>
> Signed-off-by: Eric Dumazet <edumazet@google.com>

Applied and queued up for -stable, thanks Eric.

      reply	other threads:[~2017-02-03 21:18 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-27 21:15 net: suspicious RCU usage in nf_hook Dmitry Vyukov
2017-01-27 23:22 ` Cong Wang
2017-01-27 23:30   ` Cong Wang
2017-01-27 23:35 ` Eric Dumazet
2017-01-28  1:00   ` Cong Wang
2017-01-28  1:31     ` Eric Dumazet
2017-01-31  6:19       ` Cong Wang
2017-01-31 15:44         ` Eric Dumazet
2017-02-01 20:51           ` Cong Wang
2017-02-01 21:16             ` Eric Dumazet
2017-02-01 21:22               ` Eric Dumazet
2017-02-01 23:29               ` Cong Wang
2017-02-01 23:48                 ` Eric Dumazet
2017-02-01 23:59                   ` Eric Dumazet
2017-02-02 18:01                     ` Cong Wang
2017-02-02 18:31                       ` [PATCH net] net: use a work queue to defer net_disable_timestamp() work Eric Dumazet
2017-02-03 21:18                         ` David Miller [this message]

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=20170203.161816.1608140108344194361.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=dvyukov@google.com \
    --cc=edumazet@google.com \
    --cc=eric.dumazet@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=xiyou.wangcong@gmail.com \
    /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.