[Meego-kernel] [PATCH 2/2 v2] dw_spi: add runtime pm support
Kristen Carlson Accardi
kristen at linux.intel.com
Fri Mar 25 12:26:41 PDT 2011
On Fri, 25 Mar 2011 07:44:25 +0800
"Wang, Yong Y" <yong.y.wang at intel.com> wrote:
> > -----Original Message-----
> > From: meego-kernel-bounces at lists.meego.com
> > [mailto:meego-kernel-bounces at lists.meego.com] On Behalf Of Kristen Carlson
> > Accardi
> > Sent: Friday, March 25, 2011 3:26 AM
> > To: meego-kernel at lists.meego.com
> > Subject: [Meego-kernel] [PATCH 2/2 v2] dw_spi: add runtime pm support
> >
> > ---
> > drivers/spi/dw_spi.c | 22 ++++++++---------
> > drivers/spi/dw_spi_pci.c | 54
> > +++++++++++++++++++++++++++++++++++++++++++-
> > include/linux/spi/dw_spi.h | 2 +-
> > 3 files changed, 64 insertions(+), 14 deletions(-)
> >
> > diff --git a/drivers/spi/dw_spi.c b/drivers/spi/dw_spi.c
> ...
> > -int dw_spi_suspend_host(struct dw_spi *dws)
> > +int dw_spi_suspend_host(struct dw_spi *dws, bool runtime)
> > {
> > int ret = 0;
> >
> > @@ -914,7 +911,8 @@ int dw_spi_suspend_host(struct dw_spi *dws)
> > if (ret)
> > return ret;
> > spi_enable_chip(dws, 0);
> > - spi_set_clk(dws, 0);
> > + if (!runtime)
> > + spi_set_clk(dws, 0);
> > return ret;
> > }
> > EXPORT_SYMBOL_GPL(dw_spi_suspend_host);
>
> Is it specific to MRST platform that the serial clock cannot be turned off in runtime suspend? If so, I think we might need to move that platform specific code to dw_spi_pci.c.
>
> Thanks
> -Yong
>
I don't actually know, because I do not yet know why the
serial clock cannot be turned off. I could go ahead and
just move it, and then later if it turns out to be
universally applicable we can move it back.
More information about the MeeGo-kernel
mailing list