From: Nishanth Menon <nm@ti.com>
To: Sebastian Andrzej Siewior <bigeasy@linutronix.de>,
linux-serial@vger.kernel.org,
"tony@atomide.com" <tony@atomide.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
linux-omap@vger.kernel.org, Dave Gerlach <d-gerlach@ti.com>
Subject: Re: [PATCH] tty: serial: 8250: omap: Add pinctrl support for suspend
Date: Thu, 6 Nov 2014 13:15:13 -0600 [thread overview]
Message-ID: <545BC8C1.4070503@ti.com> (raw)
In-Reply-To: <1415300850-21452-1-git-send-email-bigeasy@linutronix.de>
On 11/06/2014 01:07 PM, Sebastian Andrzej Siewior wrote:
> This is mostly an equivalent for the 8250-omap driver based on a patch
> of Dave Gerlach for the omap-serial driver (which is not yet merged).
>
> From his changelog:
> |By optionally putting the pins into sleep state in the suspend callback
> |we can accomplish two things.
> |- minimize current leakage from pins and thus save power,
> |- prevent the IP from driving pins output in an uncontrolled manner,
> | which may happen if the power domain drops the domain regulator.
>
> The pinctlr change is put before enable_wakeup logic as per Nishanth
> Menon (slightly reworded):
> |When wakeup is enabled, I/O daisy chain based wakeup is used by
> |reconfiguring the padconfig register. However, this gets overriden by
> |sleep/wakeup configuration. Therefore we need first to allow pinctrl to
> |play with the wakeup bits as needed beyond the sleep configuration.
>
> Cc: Dave Gerlach <d-gerlach@ti.com>
> Cc: Nishanth Menon <nm@ti.com>
> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
> ---
> drivers/tty/serial/8250/8250_omap.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/tty/serial/8250/8250_omap.c b/drivers/tty/serial/8250/8250_omap.c
> index 57a8b1241b85..1681875f2996 100644
> --- a/drivers/tty/serial/8250/8250_omap.c
> +++ b/drivers/tty/serial/8250/8250_omap.c
> @@ -1156,6 +1156,7 @@ static int omap8250_suspend(struct device *dev)
> serial8250_suspend_port(priv->line);
> flush_work(&priv->qos_work);
>
> + pinctrl_pm_select_sleep_state(dev);
> if (device_may_wakeup(dev))
> omap8250_enable_wakeup(priv, true);
> else
> @@ -1167,6 +1168,7 @@ static int omap8250_resume(struct device *dev)
> {
> struct omap8250_priv *priv = dev_get_drvdata(dev);
>
> + pinctrl_pm_select_default_state(dev);
> if (device_may_wakeup(dev))
> omap8250_enable_wakeup(priv, false);
>
>
sounds good to me *IF* omap8250_enable_wakeup (wakeirq handling) is
the way we want to continue doing things for daisychain? -> Tony, can
you comment?
http://marc.info/?l=linux-omap&m=141222144402707&w=2
I wonder if wakeirq explicit handling is valid anymore and something
given the potential race and alternate approach proposed?
--
Regards,
Nishanth Menon
next prev parent reply other threads:[~2014-11-06 19:15 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-06 19:07 [PATCH] tty: serial: 8250: omap: Add pinctrl support for suspend Sebastian Andrzej Siewior
2014-11-06 19:15 ` Nishanth Menon [this message]
2014-11-06 19:42 ` Sebastian Andrzej Siewior
2014-11-06 19:57 ` Nishanth Menon
2014-11-06 20:35 ` Tony Lindgren
2014-11-25 18:05 ` Sebastian Andrzej Siewior
2014-11-25 18:22 ` Tony Lindgren
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=545BC8C1.4070503@ti.com \
--to=nm@ti.com \
--cc=bigeasy@linutronix.de \
--cc=d-gerlach@ti.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-omap@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=tony@atomide.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.