From: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org, 13806511171@163.com,
shemminger@linux-foundation.org, maheshb@google.com,
j.vosburgh@gmail.com, vfalico@gmail.com,
gospo@cumulusnetworks.com
Subject: Re: [PATCH net v2] bonding: fix bond_poll_controller bh_enable warning
Date: Fri, 28 Aug 2015 14:59:40 -0700 [thread overview]
Message-ID: <69380EC5-CF63-48BE-AFCB-4F70E6869DFC@cumulusnetworks.com> (raw)
In-Reply-To: <20150828.141351.2056521281131696426.davem@davemloft.net>
> On Aug 28, 2015, at 2:13 PM, David Miller <davem@davemloft.net> wrote:
>
> From: Nikolay Aleksandrov <razor@blackwall.org>
> Date: Fri, 28 Aug 2015 10:22:20 -0700
>
>> The problem is rcu_read_unlock_bh() which triggers a warning when
>> irqs are disabled. ndo_poll_controller can run with bh enabled,
>> disabled or irqs disabled so check if that is the case and acquire
>> rcu_read_lock_bh only when not running with disabled irqs.
>
> I would say that having hard irqs disabled is a strict requirement, as
> per the debugging test in netpoll_send_skb_on_dev():
>
> WARN_ON_ONCE(!irqs_disabled());
>
> If you want to add the same check to netpoll_send_udp(), that's fine.
>
> But what isn't fine is adding all of this conditional locking, we want
> ->poll_controller() implementations to be able to depend upon the IRQ
> environment they execute in, otherwise every single implementation
> might need to have ugly conditional locking as well.
Great, that is what I wanted to know because I got confused by some older
commits. This will simplify the fix and I will add the warn_on in netpoll_send_udp().
v3 coming up
Thank you,
Nik
next prev parent reply other threads:[~2015-08-28 21:59 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-02 0:15 Fw: [Bug 102181] New: kernel soft lockup when using tcp_keepalive_timer Stephen Hemminger
2015-08-28 1:54 ` [PATCH net] bonding: fix bond_poll_controller bh_enable warning Nikolay Aleksandrov
2015-08-28 15:33 ` Nikolay Aleksandrov
2015-08-28 17:22 ` [PATCH net v2] " Nikolay Aleksandrov
2015-08-28 21:13 ` David Miller
2015-08-28 21:59 ` Nikolay Aleksandrov [this message]
2015-08-28 22:05 ` [PATCH net v3] " Nikolay Aleksandrov
2015-08-28 22:32 ` Mahesh Bandewar
2015-08-29 5:26 ` 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=69380EC5-CF63-48BE-AFCB-4F70E6869DFC@cumulusnetworks.com \
--to=nikolay@cumulusnetworks.com \
--cc=13806511171@163.com \
--cc=davem@davemloft.net \
--cc=gospo@cumulusnetworks.com \
--cc=j.vosburgh@gmail.com \
--cc=maheshb@google.com \
--cc=netdev@vger.kernel.org \
--cc=shemminger@linux-foundation.org \
--cc=vfalico@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox