Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1736202 > unrolled thread

[PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early()

Started byRajat Jain <rajatja@google.com>
First post2017-09-21 00:40 +0200
Last post2017-09-21 17:20 +0200
Articles 7 — 4 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early() Rajat Jain <rajatja@google.com> - 2017-09-21 00:40 +0200
    Re: [PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early() "Rafael J. Wysocki" <rafael@kernel.org> - 2017-09-21 02:30 +0200
      Re: [PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early() Rajat Jain <rajatja@google.com> - 2017-09-21 03:20 +0200
      Re: [PATCH 2/2] mfd: intel-lpss: switch to  suspend_late()/resume_early() Lee Jones <lee.jones@linaro.org> - 2017-09-21 10:50 +0200
        Re: [PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early() "Rafael J. Wysocki" <rjw@rjwysocki.net> - 2017-09-21 16:20 +0200
          Re: [PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early() "Rafael J. Wysocki" <rafael@kernel.org> - 2017-09-21 17:20 +0200
          Re: [PATCH 2/2] mfd: intel-lpss: switch to  suspend_late()/resume_early() Lee Jones <lee.jones@linaro.org> - 2017-09-21 17:20 +0200

#1736202 — [PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early()

FromRajat Jain <rajatja@google.com>
Date2017-09-21 00:40 +0200
Subject[PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early()
Message-ID<urVOW-J7-19@gated-at.bofh.it>
Ref: https://lkml.org/lkml/2017/9/19/649

The intel-lpss hosts the designware i2c controller device, which
needs to be up and running until all its i2c child devices have
suspended (child devices need to be accessible over i2c until
suspend_late() has been called for all those devices).

So lets delay the resetting of the controller until suspend_late().
I thought of renaming function to say *_late / *_early but that
might cause confusion since the same function is also used for runtime
suspend/resume.

Fixes: 0b471aaa0e1a ("Put I2C and SPI controllers into reset state on suspend")
Signed-off-by: Rajat Jain <rajatja@google.com>
---
 drivers/mfd/intel-lpss.h | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/drivers/mfd/intel-lpss.h b/drivers/mfd/intel-lpss.h
index 694116630ffa..865bbeaaf00c 100644
--- a/drivers/mfd/intel-lpss.h
+++ b/drivers/mfd/intel-lpss.h
@@ -38,12 +38,7 @@ int intel_lpss_resume(struct device *dev);
 #ifdef CONFIG_PM_SLEEP
 #define INTEL_LPSS_SLEEP_PM_OPS			\
 	.prepare = intel_lpss_prepare,		\
-	.suspend = intel_lpss_suspend,		\
-	.resume = intel_lpss_resume,		\
-	.freeze = intel_lpss_suspend,		\
-	.thaw = intel_lpss_resume,		\
-	.poweroff = intel_lpss_suspend,		\
-	.restore = intel_lpss_resume,
+	SET_LATE_SYSTEM_SLEEP_PM_OPS(intel_lpss_suspend, intel_lpss_resume)
 #else
 #define INTEL_LPSS_SLEEP_PM_OPS
 #endif
-- 
2.14.1.821.g8fa685d3b7-goog

[toc] | [next] | [standalone]


#1736279

From"Rafael J. Wysocki" <rafael@kernel.org>
Date2017-09-21 02:30 +0200
Message-ID<urXxn-1QS-11@gated-at.bofh.it>
In reply to#1736202
On Thu, Sep 21, 2017 at 12:31 AM, Rajat Jain <rajatja@google.com> wrote:
> Ref: https://lkml.org/lkml/2017/9/19/649
>
> The intel-lpss hosts the designware i2c controller device, which
> needs to be up and running until all its i2c child devices have
> suspended (child devices need to be accessible over i2c until
> suspend_late() has been called for all those devices).
>
> So lets delay the resetting of the controller until suspend_late().
> I thought of renaming function to say *_late / *_early but that
> might cause confusion since the same function is also used for runtime
> suspend/resume.
>
> Fixes: 0b471aaa0e1a ("Put I2C and SPI controllers into reset state on suspend")
> Signed-off-by: Rajat Jain <rajatja@google.com>
> ---
>  drivers/mfd/intel-lpss.h | 7 +------
>  1 file changed, 1 insertion(+), 6 deletions(-)
>
> diff --git a/drivers/mfd/intel-lpss.h b/drivers/mfd/intel-lpss.h
> index 694116630ffa..865bbeaaf00c 100644
> --- a/drivers/mfd/intel-lpss.h
> +++ b/drivers/mfd/intel-lpss.h
> @@ -38,12 +38,7 @@ int intel_lpss_resume(struct device *dev);
>  #ifdef CONFIG_PM_SLEEP
>  #define INTEL_LPSS_SLEEP_PM_OPS                        \
>         .prepare = intel_lpss_prepare,          \
> -       .suspend = intel_lpss_suspend,          \
> -       .resume = intel_lpss_resume,            \
> -       .freeze = intel_lpss_suspend,           \
> -       .thaw = intel_lpss_resume,              \
> -       .poweroff = intel_lpss_suspend,         \
> -       .restore = intel_lpss_resume,
> +       SET_LATE_SYSTEM_SLEEP_PM_OPS(intel_lpss_suspend, intel_lpss_resume)
>  #else
>  #define INTEL_LPSS_SLEEP_PM_OPS
>  #endif

So I sent this exact patch several days ago:
https://patchwork.kernel.org/patch/9939809/

Thanks,
Rafael

[toc] | [prev] | [next] | [standalone]


#1736311

FromRajat Jain <rajatja@google.com>
Date2017-09-21 03:20 +0200
Message-ID<urYjL-2of-3@gated-at.bofh.it>
In reply to#1736279
On Wed, Sep 20, 2017 at 5:27 PM, Rafael J. Wysocki <rafael@kernel.org> wrote:
> On Thu, Sep 21, 2017 at 12:31 AM, Rajat Jain <rajatja@google.com> wrote:
>> Ref: https://lkml.org/lkml/2017/9/19/649
>>
>> The intel-lpss hosts the designware i2c controller device, which
>> needs to be up and running until all its i2c child devices have
>> suspended (child devices need to be accessible over i2c until
>> suspend_late() has been called for all those devices).
>>
>> So lets delay the resetting of the controller until suspend_late().
>> I thought of renaming function to say *_late / *_early but that
>> might cause confusion since the same function is also used for runtime
>> suspend/resume.
>>
>> Fixes: 0b471aaa0e1a ("Put I2C and SPI controllers into reset state on suspend")
>> Signed-off-by: Rajat Jain <rajatja@google.com>
>> ---
>>  drivers/mfd/intel-lpss.h | 7 +------
>>  1 file changed, 1 insertion(+), 6 deletions(-)
>>
>> diff --git a/drivers/mfd/intel-lpss.h b/drivers/mfd/intel-lpss.h
>> index 694116630ffa..865bbeaaf00c 100644
>> --- a/drivers/mfd/intel-lpss.h
>> +++ b/drivers/mfd/intel-lpss.h
>> @@ -38,12 +38,7 @@ int intel_lpss_resume(struct device *dev);
>>  #ifdef CONFIG_PM_SLEEP
>>  #define INTEL_LPSS_SLEEP_PM_OPS                        \
>>         .prepare = intel_lpss_prepare,          \
>> -       .suspend = intel_lpss_suspend,          \
>> -       .resume = intel_lpss_resume,            \
>> -       .freeze = intel_lpss_suspend,           \
>> -       .thaw = intel_lpss_resume,              \
>> -       .poweroff = intel_lpss_suspend,         \
>> -       .restore = intel_lpss_resume,
>> +       SET_LATE_SYSTEM_SLEEP_PM_OPS(intel_lpss_suspend, intel_lpss_resume)
>>  #else
>>  #define INTEL_LPSS_SLEEP_PM_OPS
>>  #endif
>
> So I sent this exact patch several days ago:
> https://patchwork.kernel.org/patch/9939809/

Sorry, I missed it. Please consider my patch withdrawn / self-nack'ed
in favor of Rafael's patch.

>
> Thanks,
> Rafael

[toc] | [prev] | [next] | [standalone]


#1736474 — Re: [PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early()

FromLee Jones <lee.jones@linaro.org>
Date2017-09-21 10:50 +0200
SubjectRe: [PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early()
Message-ID<us5lg-6XJ-17@gated-at.bofh.it>
In reply to#1736279
On Thu, 21 Sep 2017, Rafael J. Wysocki wrote:

> On Thu, Sep 21, 2017 at 12:31 AM, Rajat Jain <rajatja@google.com> wrote:
> > Ref: https://lkml.org/lkml/2017/9/19/649
> >
> > The intel-lpss hosts the designware i2c controller device, which
> > needs to be up and running until all its i2c child devices have
> > suspended (child devices need to be accessible over i2c until
> > suspend_late() has been called for all those devices).
> >
> > So lets delay the resetting of the controller until suspend_late().
> > I thought of renaming function to say *_late / *_early but that
> > might cause confusion since the same function is also used for runtime
> > suspend/resume.
> >
> > Fixes: 0b471aaa0e1a ("Put I2C and SPI controllers into reset state on suspend")
> > Signed-off-by: Rajat Jain <rajatja@google.com>
> > ---
> >  drivers/mfd/intel-lpss.h | 7 +------
> >  1 file changed, 1 insertion(+), 6 deletions(-)
> >
> > diff --git a/drivers/mfd/intel-lpss.h b/drivers/mfd/intel-lpss.h
> > index 694116630ffa..865bbeaaf00c 100644
> > --- a/drivers/mfd/intel-lpss.h
> > +++ b/drivers/mfd/intel-lpss.h
> > @@ -38,12 +38,7 @@ int intel_lpss_resume(struct device *dev);
> >  #ifdef CONFIG_PM_SLEEP
> >  #define INTEL_LPSS_SLEEP_PM_OPS                        \
> >         .prepare = intel_lpss_prepare,          \
> > -       .suspend = intel_lpss_suspend,          \
> > -       .resume = intel_lpss_resume,            \
> > -       .freeze = intel_lpss_suspend,           \
> > -       .thaw = intel_lpss_resume,              \
> > -       .poweroff = intel_lpss_suspend,         \
> > -       .restore = intel_lpss_resume,
> > +       SET_LATE_SYSTEM_SLEEP_PM_OPS(intel_lpss_suspend, intel_lpss_resume)
> >  #else
> >  #define INTEL_LPSS_SLEEP_PM_OPS
> >  #endif
> 
> So I sent this exact patch several days ago:
> https://patchwork.kernel.org/patch/9939809/

You did?  Any reason you didn't send it to me?

-- 
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

[toc] | [prev] | [next] | [standalone]


#1736699

From"Rafael J. Wysocki" <rjw@rjwysocki.net>
Date2017-09-21 16:20 +0200
Message-ID<usauC-25s-3@gated-at.bofh.it>
In reply to#1736474
On Thursday, September 21, 2017 10:41:33 AM CEST Lee Jones wrote:
> On Thu, 21 Sep 2017, Rafael J. Wysocki wrote:
> 
> > On Thu, Sep 21, 2017 at 12:31 AM, Rajat Jain <rajatja@google.com> wrote:
> > > Ref: https://lkml.org/lkml/2017/9/19/649
> > >
> > > The intel-lpss hosts the designware i2c controller device, which
> > > needs to be up and running until all its i2c child devices have
> > > suspended (child devices need to be accessible over i2c until
> > > suspend_late() has been called for all those devices).
> > >
> > > So lets delay the resetting of the controller until suspend_late().
> > > I thought of renaming function to say *_late / *_early but that
> > > might cause confusion since the same function is also used for runtime
> > > suspend/resume.
> > >
> > > Fixes: 0b471aaa0e1a ("Put I2C and SPI controllers into reset state on suspend")
> > > Signed-off-by: Rajat Jain <rajatja@google.com>
> > > ---
> > >  drivers/mfd/intel-lpss.h | 7 +------
> > >  1 file changed, 1 insertion(+), 6 deletions(-)
> > >
> > > diff --git a/drivers/mfd/intel-lpss.h b/drivers/mfd/intel-lpss.h
> > > index 694116630ffa..865bbeaaf00c 100644
> > > --- a/drivers/mfd/intel-lpss.h
> > > +++ b/drivers/mfd/intel-lpss.h
> > > @@ -38,12 +38,7 @@ int intel_lpss_resume(struct device *dev);
> > >  #ifdef CONFIG_PM_SLEEP
> > >  #define INTEL_LPSS_SLEEP_PM_OPS                        \
> > >         .prepare = intel_lpss_prepare,          \
> > > -       .suspend = intel_lpss_suspend,          \
> > > -       .resume = intel_lpss_resume,            \
> > > -       .freeze = intel_lpss_suspend,           \
> > > -       .thaw = intel_lpss_resume,              \
> > > -       .poweroff = intel_lpss_suspend,         \
> > > -       .restore = intel_lpss_resume,
> > > +       SET_LATE_SYSTEM_SLEEP_PM_OPS(intel_lpss_suspend, intel_lpss_resume)
> > >  #else
> > >  #define INTEL_LPSS_SLEEP_PM_OPS
> > >  #endif
> > 
> > So I sent this exact patch several days ago:
> > https://patchwork.kernel.org/patch/9939809/
> 
> You did?

Yes, I did.

> Any reason you didn't send it to me?

Well, Lee Jones <lee@kernel.org> is very much in the CC list of it.

Was I expected to use a different e-mail address for that?

Thanks,
Rafael

[toc] | [prev] | [next] | [standalone]


#1736768

From"Rafael J. Wysocki" <rafael@kernel.org>
Date2017-09-21 17:20 +0200
Message-ID<usbqG-2Ji-27@gated-at.bofh.it>
In reply to#1736699
On Thu, Sep 21, 2017 at 5:17 PM, Lee Jones <lee.jones@linaro.org> wrote:
> On Thu, 21 Sep 2017, Rafael J. Wysocki wrote:
>
>> On Thursday, September 21, 2017 10:41:33 AM CEST Lee Jones wrote:
>> > On Thu, 21 Sep 2017, Rafael J. Wysocki wrote:
>> >
>> > > On Thu, Sep 21, 2017 at 12:31 AM, Rajat Jain <rajatja@google.com> wrote:
>> > > > Ref: https://lkml.org/lkml/2017/9/19/649
>> > > >
>> > > > The intel-lpss hosts the designware i2c controller device, which
>> > > > needs to be up and running until all its i2c child devices have
>> > > > suspended (child devices need to be accessible over i2c until
>> > > > suspend_late() has been called for all those devices).
>> > > >
>> > > > So lets delay the resetting of the controller until suspend_late().
>> > > > I thought of renaming function to say *_late / *_early but that
>> > > > might cause confusion since the same function is also used for runtime
>> > > > suspend/resume.
>> > > >
>> > > > Fixes: 0b471aaa0e1a ("Put I2C and SPI controllers into reset state on suspend")
>> > > > Signed-off-by: Rajat Jain <rajatja@google.com>
>> > > > ---
>> > > >  drivers/mfd/intel-lpss.h | 7 +------
>> > > >  1 file changed, 1 insertion(+), 6 deletions(-)
>> > > >
>> > > > diff --git a/drivers/mfd/intel-lpss.h b/drivers/mfd/intel-lpss.h
>> > > > index 694116630ffa..865bbeaaf00c 100644
>> > > > --- a/drivers/mfd/intel-lpss.h
>> > > > +++ b/drivers/mfd/intel-lpss.h
>> > > > @@ -38,12 +38,7 @@ int intel_lpss_resume(struct device *dev);
>> > > >  #ifdef CONFIG_PM_SLEEP
>> > > >  #define INTEL_LPSS_SLEEP_PM_OPS                        \
>> > > >         .prepare = intel_lpss_prepare,          \
>> > > > -       .suspend = intel_lpss_suspend,          \
>> > > > -       .resume = intel_lpss_resume,            \
>> > > > -       .freeze = intel_lpss_suspend,           \
>> > > > -       .thaw = intel_lpss_resume,              \
>> > > > -       .poweroff = intel_lpss_suspend,         \
>> > > > -       .restore = intel_lpss_resume,
>> > > > +       SET_LATE_SYSTEM_SLEEP_PM_OPS(intel_lpss_suspend, intel_lpss_resume)
>> > > >  #else
>> > > >  #define INTEL_LPSS_SLEEP_PM_OPS
>> > > >  #endif
>> > >
>> > > So I sent this exact patch several days ago:
>> > > https://patchwork.kernel.org/patch/9939809/
>> >
>> > You did?
>>
>> Yes, I did.
>>
>> > Any reason you didn't send it to me?
>>
>> Well, Lee Jones <lee@kernel.org> is very much in the CC list of it.
>>
>> Was I expected to use a different e-mail address for that?
>
> I don't monitor that one.  Better to use the one in MAINTAINERS.

OK, I will in the future.

[toc] | [prev] | [next] | [standalone]


#1736769 — Re: [PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early()

FromLee Jones <lee.jones@linaro.org>
Date2017-09-21 17:20 +0200
SubjectRe: [PATCH 2/2] mfd: intel-lpss: switch to suspend_late()/resume_early()
Message-ID<usbqG-2Ji-19@gated-at.bofh.it>
In reply to#1736699
On Thu, 21 Sep 2017, Rafael J. Wysocki wrote:

> On Thursday, September 21, 2017 10:41:33 AM CEST Lee Jones wrote:
> > On Thu, 21 Sep 2017, Rafael J. Wysocki wrote:
> > 
> > > On Thu, Sep 21, 2017 at 12:31 AM, Rajat Jain <rajatja@google.com> wrote:
> > > > Ref: https://lkml.org/lkml/2017/9/19/649
> > > >
> > > > The intel-lpss hosts the designware i2c controller device, which
> > > > needs to be up and running until all its i2c child devices have
> > > > suspended (child devices need to be accessible over i2c until
> > > > suspend_late() has been called for all those devices).
> > > >
> > > > So lets delay the resetting of the controller until suspend_late().
> > > > I thought of renaming function to say *_late / *_early but that
> > > > might cause confusion since the same function is also used for runtime
> > > > suspend/resume.
> > > >
> > > > Fixes: 0b471aaa0e1a ("Put I2C and SPI controllers into reset state on suspend")
> > > > Signed-off-by: Rajat Jain <rajatja@google.com>
> > > > ---
> > > >  drivers/mfd/intel-lpss.h | 7 +------
> > > >  1 file changed, 1 insertion(+), 6 deletions(-)
> > > >
> > > > diff --git a/drivers/mfd/intel-lpss.h b/drivers/mfd/intel-lpss.h
> > > > index 694116630ffa..865bbeaaf00c 100644
> > > > --- a/drivers/mfd/intel-lpss.h
> > > > +++ b/drivers/mfd/intel-lpss.h
> > > > @@ -38,12 +38,7 @@ int intel_lpss_resume(struct device *dev);
> > > >  #ifdef CONFIG_PM_SLEEP
> > > >  #define INTEL_LPSS_SLEEP_PM_OPS                        \
> > > >         .prepare = intel_lpss_prepare,          \
> > > > -       .suspend = intel_lpss_suspend,          \
> > > > -       .resume = intel_lpss_resume,            \
> > > > -       .freeze = intel_lpss_suspend,           \
> > > > -       .thaw = intel_lpss_resume,              \
> > > > -       .poweroff = intel_lpss_suspend,         \
> > > > -       .restore = intel_lpss_resume,
> > > > +       SET_LATE_SYSTEM_SLEEP_PM_OPS(intel_lpss_suspend, intel_lpss_resume)
> > > >  #else
> > > >  #define INTEL_LPSS_SLEEP_PM_OPS
> > > >  #endif
> > > 
> > > So I sent this exact patch several days ago:
> > > https://patchwork.kernel.org/patch/9939809/
> > 
> > You did?
> 
> Yes, I did.
> 
> > Any reason you didn't send it to me?
> 
> Well, Lee Jones <lee@kernel.org> is very much in the CC list of it.
> 
> Was I expected to use a different e-mail address for that?

I don't monitor that one.  Better to use the one in MAINTAINERS.

-- 
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web