linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andy Shevchenko <andy.shevchenko@gmail.com>
To: Aswath Govindraju <a-govindraju@ti.com>
Cc: Vignesh Raghavendra <vigneshr@ti.com>,
	Devarsh Thakkar <devarsht@ti.com>, Keerthy <j-keerthy@ti.com>,
	Linus Walleij <linus.walleij@linaro.org>,
	Bartosz Golaszewski <brgl@bgdev.pl>,
	"open list:GPIO SUBSYSTEM" <linux-gpio@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2] gpio: davinci: Add support for system suspend/resume PM
Date: Fri, 10 Jun 2022 14:20:51 +0200	[thread overview]
Message-ID: <CAHp75VdPXHF96B5QWNOS3zfF+EOnWeRe+LCGnjvLBcb30kVzWg@mail.gmail.com> (raw)
In-Reply-To: <20220610054622.21281-1-a-govindraju@ti.com>

On Fri, Jun 10, 2022 at 8:08 AM Aswath Govindraju <a-govindraju@ti.com> wrote:
>
> From: Devarsh Thakkar <devarsht@ti.com>
>
> Add support for system suspend/resume PM hooks, save the
> register context of all the required gpio registers on suspend
> and restore the context on resume.

the resume

...

> +       writel_relaxed(0xFFFFFFFF, &g->intstat);

GENMASK(31, 0) ?

...

> +static int __maybe_unused davinci_gpio_suspend(struct device *dev)

> +static int __maybe_unused davinci_gpio_resume(struct device *dev)

> +static const struct dev_pm_ops davinci_gpio_dev_pm_ops = {
> +       SET_SYSTEM_SLEEP_PM_OPS(davinci_gpio_suspend, davinci_gpio_resume)
> +};

> +               .pm = &davinci_gpio_dev_pm_ops,

Can you utilize pm_sleep_ptr() and corresponding macros instead of
__maybe_unused?

-- 
With Best Regards,
Andy Shevchenko

  reply	other threads:[~2022-06-10 12:21 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-10  5:46 [PATCH v2] gpio: davinci: Add support for system suspend/resume PM Aswath Govindraju
2022-06-10 12:20 ` Andy Shevchenko [this message]
2022-06-13  5:46   ` Aswath Govindraju

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=CAHp75VdPXHF96B5QWNOS3zfF+EOnWeRe+LCGnjvLBcb30kVzWg@mail.gmail.com \
    --to=andy.shevchenko@gmail.com \
    --cc=a-govindraju@ti.com \
    --cc=brgl@bgdev.pl \
    --cc=devarsht@ti.com \
    --cc=j-keerthy@ti.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=vigneshr@ti.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).