From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Hans de Goede <hdegoede@redhat.com>,
Mika Westerberg <mika.westerberg@linux.intel.com>,
Linus Walleij <linus.walleij@linaro.org>,
Alexandre Courbot <gnurou@gmail.com>
Cc: linux-acpi@vger.kernel.org, linux-gpio@vger.kernel.org
Subject: Re: [PATCH] gpio: acpi: Call enable_irq_wake for _IAE GpioInts with Wake set
Date: Tue, 21 Mar 2017 14:21:52 +0200 [thread overview]
Message-ID: <1490098912.19767.122.camel@linux.intel.com> (raw)
In-Reply-To: <c9801c6a-b773-b5fd-25dc-6e19053512ac@redhat.com>
On Mon, 2017-03-20 at 18:20 +0100, Hans de Goede wrote:
> Hi,
>
> On 19-03-17 16:25, Andy Shevchenko wrote:
> > On Sun, 2017-03-19 at 00:35 +0100, Hans de Goede wrote:
> > > On baytrail / cherrytrail systems with a LID switch the LID switch
> > > is
> > > often connect to a gpioint handled by an _IAE event handler.
> > > Before this commit such systems would not wake up when opening the
> > > lid,
> > > requiring the powerbutton to be pressed after opening the lid to
> > > wakeup.
> > >
> > > This commit calls enable_irq_wake() for _IAE GpioInts with a valid
> > > event handler which have their Wake flag set. This fixes such
> > > systems
> > > not waking up when opening the lid.
> >
> > I perhaps give up on my nits against Capital Letters :-), though for
> > consistency, please, use Baytrail, Cherry Trail.
>
> Will fix for v2.
>
> >
> > > + if (event->irq_wake_enabled)
> >
> > You may use irqd_is_wakeup_set() instead. IRQ framework keeps this
> > state
> > already.
>
> That requires having irq_data which is only (normally) available to
> irq_chip drivers, so that is not going to work here.
Which you can get easily from IRQ line number.
data = irq_get_irq_data(irq);
if (irqd_is_wakeup_set(data))
Would this work?
--
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy
next prev parent reply other threads:[~2017-03-21 12:23 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-18 23:35 [PATCH] gpio: acpi: Call enable_irq_wake for _IAE GpioInts with Wake set Hans de Goede
2017-03-19 0:25 ` Rafael J. Wysocki
2017-03-20 17:24 ` Hans de Goede
2017-03-19 15:25 ` Andy Shevchenko
2017-03-19 19:48 ` Rafael J. Wysocki
2017-03-20 17:20 ` Hans de Goede
2017-03-21 12:21 ` Andy Shevchenko [this message]
2017-03-20 10:17 ` Mika Westerberg
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=1490098912.19767.122.camel@linux.intel.com \
--to=andriy.shevchenko@linux.intel.com \
--cc=gnurou@gmail.com \
--cc=hdegoede@redhat.com \
--cc=linus.walleij@linaro.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-gpio@vger.kernel.org \
--cc=mika.westerberg@linux.intel.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;
as well as URLs for NNTP newsgroup(s).