linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Geert Uytterhoeven <geert@linux-m68k.org>
To: Magnus Damm <magnus.damm@gmail.com>
Cc: Linus Walleij <linus.walleij@linaro.org>,
	Yoshihiro Kaneko <ykaneko0929@gmail.com>,
	Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>,
	"linux-gpio@vger.kernel.org" <linux-gpio@vger.kernel.org>,
	Alexandre Courbot <gnurou@gmail.com>,
	Simon Horman <horms@verge.net.au>,
	"linux-sh@vger.kernel.org" <linux-sh@vger.kernel.org>,
	Geert Uytterhoeven <geert+renesas@glider.be>
Subject: Re: [PATCH] gpio-rcar: .irq_set_wake() support to work with suspend_device_irqs()
Date: Mon, 17 Nov 2014 13:05:24 +0100	[thread overview]
Message-ID: <CAMuHMdUFPVBDbvaMNdPNGG-a9i1d8dAEK5WsREX40iSGVJk8+w@mail.gmail.com> (raw)
In-Reply-To: <CANqRtoTKKuKnfFN4VYhnt1M8jb-2o+PTaivQvu3ELR32c9DhHQ@mail.gmail.com>

Hi Magnus, Kaneko-san,

On Mon, Nov 17, 2014 at 2:06 AM, Magnus Damm <magnus.damm@gmail.com> wrote:
> On Fri, Nov 14, 2014 at 6:53 PM, Linus Walleij <linus.walleij@linaro.org> wrote:
>> On Fri, Nov 7, 2014 at 10:22 AM, Yoshihiro Kaneko <ykaneko0929@gmail.com> wrote:
>>> From: Shinya Kuribayashi <shinya.kuribayashi.px@renesas.com>
>>>
>>> All IRQs in the kernel get disabled by PM core prior to .suspend_noirq()
>>> step through kernel/irq/pm.c::suspend_device_irqs().
>>>
>>> The SYSC hardware block in the R-Car SoCs, on the other hand, uses any
>>> interrupt as wake-up source(es) and requires them to be unmasked during
>>> the system is suspended.
>>>
>>> This patch implements .irq_set_wake() which makes __disable_irq() call
>>> a NOP when a GPIO port is claimed as a wake-up source.
>>>
>>> Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi.px@renesas.com>
>>> Signed-off-by: Koji Matsuoka <koji.matsuoka.xm@renesas.com>
>>> Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com>
>>
>> Patch tentatively applied unless Magnus or Laurent starts complaining...
>
> I'll bite. =)
>
> Thanks for the efforts, but I doubt that this patch is needed. Unless
> I'm mistaken this feature is implemented already in the following
> commits:
>
> 4039611 gpio: rcar: Enable mask on suspend
> fba968a gpio: rcar: Use lazy disable

Good to see you (as the author of the driver and those two fixes) have some
reservations. I also had my doubts about this patch, but I didn't get to
testing it earlier...

I can confirm resume from s2ram works without and with this patch.
So unless this patch is meant to fix something else (is it?), I think it can be
dropped.

>> This driver should be simple to convert to GPIOLIB_IRQCHIP and get
>> rid of some code overhead.
>
> Perhaps Geert [CC:ed] can have a look at this in the not so distant future?

Sure. Will do.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

  reply	other threads:[~2014-11-17 12:05 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-07  9:22 [PATCH] gpio-rcar: .irq_set_wake() support to work with suspend_device_irqs() Yoshihiro Kaneko
2014-11-14  9:53 ` Linus Walleij
2014-11-17  1:06   ` Magnus Damm
2014-11-17 12:05     ` Geert Uytterhoeven [this message]
2014-11-27 14:01       ` Linus Walleij

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=CAMuHMdUFPVBDbvaMNdPNGG-a9i1d8dAEK5WsREX40iSGVJk8+w@mail.gmail.com \
    --to=geert@linux-m68k.org \
    --cc=geert+renesas@glider.be \
    --cc=gnurou@gmail.com \
    --cc=horms@verge.net.au \
    --cc=laurent.pinchart+renesas@ideasonboard.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-sh@vger.kernel.org \
    --cc=magnus.damm@gmail.com \
    --cc=ykaneko0929@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;
as well as URLs for NNTP newsgroup(s).