All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: Claudiu.Beznea@microchip.com
Cc: Nicolas.Ferre@microchip.com, alexandre.belloni@bootlin.com,
	Ludovic.Desroches@microchip.com, linux@armlinux.org.uk,
	lgirdwood@gmail.com, broonie@kernel.org, rjw@rjwysocki.net,
	len.brown@intel.com, linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org
Subject: Re: [PATCH v2 1/3] PM / Suspend: Add support to check if platform's power is off in suspend
Date: Wed, 9 Jan 2019 15:14:17 +0100	[thread overview]
Message-ID: <20190109141417.GA8529@amd> (raw)
In-Reply-To: <1546944944-13911-2-git-send-email-claudiu.beznea@microchip.com>

[-- Attachment #1: Type: text/plain, Size: 1632 bytes --]

Hi!

> Add support to check if platform's power will be cut off in suspend.
> This will help drivers shared by multiple platforms to take only the
> necessary actions while suspending/resuming (some platform may not need
> to save/restore all the registers if platforms remains powered while
> suspended). In this way suspend/resume time could be improved.
> 
> Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
> ---
>  include/linux/suspend.h |  6 ++++++
>  kernel/power/suspend.c  | 13 +++++++++++++
>  2 files changed, 19 insertions(+)
> 
> diff --git a/include/linux/suspend.h b/include/linux/suspend.h
> index 3f529ad9a9d2..21f19b167fe2 100644
> --- a/include/linux/suspend.h
> +++ b/include/linux/suspend.h
> @@ -173,6 +173,9 @@ static inline void dpm_save_failed_step(enum suspend_stat_step step)
>   *	Called by the PM core if the suspending of devices fails.
>   *	This callback is optional and should only be implemented by platforms
>   *	which require special recovery actions in that situation.
> + *
> + * @off_in_suspend: Returns wether the platform's power will be cut off at

wether -- spelling?

> @@ -185,6 +188,7 @@ struct platform_suspend_ops {
>  	bool (*suspend_again)(void);
>  	void (*end)(void);
>  	void (*recover)(void);
> +	bool (*off_in_suspend)(suspend_state_t state);
>  };

Dunno, should it be per-regulator? SoCs commonly have more than one
power supply, with some of them off during suspend...
									Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

WARNING: multiple messages have this Message-ID (diff)
From: Pavel Machek <pavel@ucw.cz>
To: Claudiu.Beznea@microchip.com
Cc: len.brown@intel.com, alexandre.belloni@bootlin.com,
	linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org,
	rjw@rjwysocki.net, lgirdwood@gmail.com,
	Ludovic.Desroches@microchip.com, broonie@kernel.org,
	linux@armlinux.org.uk, linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v2 1/3] PM / Suspend: Add support to check if platform's power is off in suspend
Date: Wed, 9 Jan 2019 15:14:17 +0100	[thread overview]
Message-ID: <20190109141417.GA8529@amd> (raw)
In-Reply-To: <1546944944-13911-2-git-send-email-claudiu.beznea@microchip.com>


[-- Attachment #1.1: Type: text/plain, Size: 1632 bytes --]

Hi!

> Add support to check if platform's power will be cut off in suspend.
> This will help drivers shared by multiple platforms to take only the
> necessary actions while suspending/resuming (some platform may not need
> to save/restore all the registers if platforms remains powered while
> suspended). In this way suspend/resume time could be improved.
> 
> Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
> ---
>  include/linux/suspend.h |  6 ++++++
>  kernel/power/suspend.c  | 13 +++++++++++++
>  2 files changed, 19 insertions(+)
> 
> diff --git a/include/linux/suspend.h b/include/linux/suspend.h
> index 3f529ad9a9d2..21f19b167fe2 100644
> --- a/include/linux/suspend.h
> +++ b/include/linux/suspend.h
> @@ -173,6 +173,9 @@ static inline void dpm_save_failed_step(enum suspend_stat_step step)
>   *	Called by the PM core if the suspending of devices fails.
>   *	This callback is optional and should only be implemented by platforms
>   *	which require special recovery actions in that situation.
> + *
> + * @off_in_suspend: Returns wether the platform's power will be cut off at

wether -- spelling?

> @@ -185,6 +188,7 @@ struct platform_suspend_ops {
>  	bool (*suspend_again)(void);
>  	void (*end)(void);
>  	void (*recover)(void);
> +	bool (*off_in_suspend)(suspend_state_t state);
>  };

Dunno, should it be per-regulator? SoCs commonly have more than one
power supply, with some of them off during suspend...
									Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

[-- Attachment #1.2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

[-- Attachment #2: Type: text/plain, Size: 176 bytes --]

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2019-01-09 14:14 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-08 10:56 [PATCH v2 0/3] add support for power off check in suspend Claudiu.Beznea
2019-01-08 10:56 ` Claudiu.Beznea
2019-01-08 10:56 ` Claudiu.Beznea
2019-01-08 10:56 ` [PATCH v2 1/3] PM / Suspend: Add support to check if platform's power is off " Claudiu.Beznea
2019-01-08 10:56   ` Claudiu.Beznea
2019-01-08 10:56   ` Claudiu.Beznea
2019-01-09 14:14   ` Pavel Machek [this message]
2019-01-09 14:14     ` Pavel Machek
2019-01-10 10:24     ` Claudiu.Beznea
2019-01-10 10:24       ` Claudiu.Beznea
2019-01-10 10:24       ` Claudiu.Beznea
2019-01-08 10:56 ` [PATCH v2 2/3] regulator: core: add helper to check if regulator is disabled " Claudiu.Beznea
2019-01-08 10:56   ` Claudiu.Beznea
2019-01-08 10:56   ` Claudiu.Beznea
2019-01-09 16:57   ` Mark Brown
2019-01-09 16:57     ` Mark Brown
2019-01-10 10:24     ` Claudiu.Beznea
2019-01-10 10:24       ` Claudiu.Beznea
2019-01-10 10:24       ` Claudiu.Beznea
2019-01-11 12:39       ` Mark Brown
2019-01-11 12:39         ` Mark Brown
2019-01-11 14:08         ` Claudiu.Beznea
2019-01-11 14:08           ` Claudiu.Beznea
2019-01-11 14:08           ` Claudiu.Beznea
2019-01-14 22:53           ` Mark Brown
2019-01-14 22:53             ` Mark Brown
2019-01-15  9:19             ` Claudiu.Beznea
2019-01-15  9:19               ` Claudiu.Beznea
2019-01-15  9:19               ` Claudiu.Beznea
2019-01-08 10:56 ` [PATCH v2 3/3] ARM: at91: pm: add support for .off_in_suspend Claudiu.Beznea
2019-01-08 10:56   ` Claudiu.Beznea
2019-01-08 10:56   ` Claudiu.Beznea
2019-01-08 11:46 ` [PATCH v2 0/3] add support for power off check in suspend Rafael J. Wysocki
2019-01-08 11:46   ` Rafael J. Wysocki
2019-01-08 14:07   ` Claudiu.Beznea
2019-01-08 14:07     ` Claudiu.Beznea
2019-01-08 14:07     ` Claudiu.Beznea
2019-01-28  9:50 ` Claudiu.Beznea
2019-01-28  9:50   ` Claudiu.Beznea
2019-01-28  9:50   ` Claudiu.Beznea

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=20190109141417.GA8529@amd \
    --to=pavel@ucw.cz \
    --cc=Claudiu.Beznea@microchip.com \
    --cc=Ludovic.Desroches@microchip.com \
    --cc=Nicolas.Ferre@microchip.com \
    --cc=alexandre.belloni@bootlin.com \
    --cc=broonie@kernel.org \
    --cc=len.brown@intel.com \
    --cc=lgirdwood@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=rjw@rjwysocki.net \
    /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.