netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
To: fbl-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org
Cc: netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	dev-yBygre7rU0SM8Zsap4Y0gw@public.gmane.org
Subject: Re: [PATCH net] openvswitch: fix a possible deadlock and lockdep warning
Date: Fri, 28 Mar 2014 16:36:39 -0400 (EDT)	[thread overview]
Message-ID: <20140328.163639.788185926435545136.davem@davemloft.net> (raw)
In-Reply-To: <1395924836-3182-1-git-send-email-fbl-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>

From: Flavio Leitner <fbl-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
Date: Thu, 27 Mar 2014 09:53:56 -0300

> There are two problematic situations.
> 
> A deadlock can happen when is_percpu is false because it can get
> interrupted while holding the spinlock. Then it executes
> ovs_flow_stats_update() in softirq context which tries to get
> the same lock.
> 
> The second sitation is that when is_percpu is true, the code
> correctly disables BH only for the local CPU, but that confuses
> lockdep enough to trigger the warning below.
> 
> This patch disables BH for both cases fixing the real deadlock
> and the lockdep warning message.
 ...
> Signed-off-by: Flavio Leitner <fbl-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>

I'll let Jesse review and pick this up.

  parent reply	other threads:[~2014-03-28 20:36 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-27 12:53 [PATCH net] openvswitch: fix a possible deadlock and lockdep warning Flavio Leitner
     [not found] ` <1395924836-3182-1-git-send-email-fbl-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2014-03-28 20:36   ` David Miller [this message]
  -- strict thread matches above, loose matches on Subject: below --
2014-03-27  0:56 Flavio Leitner
2014-03-27 12:52 ` Flavio Leitner

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=20140328.163639.788185926435545136.davem@davemloft.net \
    --to=davem-ft/pcqaiutieiz0/mpfg9q@public.gmane.org \
    --cc=dev-yBygre7rU0SM8Zsap4Y0gw@public.gmane.org \
    --cc=fbl-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).