From: Thomas Gleixner <tglx@linutronix.de>
To: Brian Norris <briannorris@chromium.org>
Cc: jeffy <jeffy.chen@rock-chips.com>,
LKML <linux-kernel@vger.kernel.org>,
dianders@chromium.org, tfiga@chromium.org,
Johannes Berg <johannes.berg@intel.com>
Subject: Re: [PATCH] genirq: Check irq disabled & masked states in irq_shutdown
Date: Wed, 31 May 2017 11:22:14 +0200 (CEST) [thread overview]
Message-ID: <alpine.DEB.2.20.1705311121050.1909@nanos> (raw)
In-Reply-To: <20170530231956.GA25960@google.com>
On Tue, 30 May 2017, Brian Norris wrote:
> On Sat, May 27, 2017 at 10:16:37AM +0200, Thomas Gleixner wrote:
> > On Sat, 27 May 2017, jeffy wrote:
> > > for example when a driver(drivers/net/wireless/marvell/mwifiex/main.c) try to
> > > do these:
> > >
> > > devm_request_irq->irq_startup->irq_enable
> > > disable_irq <-- disabled and masked
> > > devm_free_irq->irq_shutdown <-- disable it again
> >
> > This driver is broken as hell.
>
> No argument on the general statement :)
>
> > It requests the interrupt _BEFORE_ the whole
> > thing is initialized. If there is a pending interrupt on that line, it will
> > explode nicely before it is able to disable the irq. But that's a different
> > problem.
>
> For that particular interrupt, it's mostly an informational interrupt
> regarding wakeups. We don't do anything that could blow up there, except
> report a (spurious) wakeup event. (And this spurious wakeup event only
> occurs because the Wifi firmware may toggle its "wake" pin even when the
> system is already awake. A weird behavior...)
>
> So yes, the pattern isn't great, but no, it's not going to blow up,
> AFAIK.
Fair enough.
Thanks,
tglx
prev parent reply other threads:[~2017-05-31 9:22 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-26 13:17 Jeffy Chen
2017-05-26 13:20 ` Thomas Gleixner
2017-05-27 4:52 ` jeffy
2017-05-27 8:16 ` Thomas Gleixner
2017-05-30 23:20 ` Brian Norris
2017-05-30 23:32 ` Brian Norris
2017-05-31 8:38 ` Thomas Gleixner
2017-05-31 9:22 ` Thomas Gleixner [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=alpine.DEB.2.20.1705311121050.1909@nanos \
--to=tglx@linutronix.de \
--cc=briannorris@chromium.org \
--cc=dianders@chromium.org \
--cc=jeffy.chen@rock-chips.com \
--cc=johannes.berg@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=tfiga@chromium.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
all inboxes | Powered by JetHome®