From: Alexandre Belloni <alexandre.belloni@bootlin.com>
To: Biwen Li <biwen.li@oss.nxp.com>
Cc: leoyang.li@nxp.com, linux-rtc@vger.kernel.org,
linux-kernel@vger.kernel.org, jiafei.pan@nxp.com,
Biwen Li <biwen.li@nxp.com>
Subject: Re: rtc: fsl-ftm-alarm: add shutdown interface
Date: Mon, 30 Mar 2020 18:44:00 +0200 [thread overview]
Message-ID: <20200330164400.GE846876@piout.net> (raw)
In-Reply-To: <20200330122616.24044-1-biwen.li@oss.nxp.com>
On 30/03/2020 20:26:16+0800, Biwen Li wrote:
> From: Biwen Li <biwen.li@nxp.com>
>
> Add shutdown interface
>
> Signed-off-by: Biwen Li <biwen.li@nxp.com>
> ---
> drivers/rtc/rtc-fsl-ftm-alarm.c | 10 ++++++++++
> 1 file changed, 10 insertions(+)
>
> diff --git a/drivers/rtc/rtc-fsl-ftm-alarm.c b/drivers/rtc/rtc-fsl-ftm-alarm.c
> index d7fa6c16f47b..118a775e8316 100644
> --- a/drivers/rtc/rtc-fsl-ftm-alarm.c
> +++ b/drivers/rtc/rtc-fsl-ftm-alarm.c
> @@ -307,6 +307,15 @@ static int ftm_rtc_probe(struct platform_device *pdev)
> return 0;
> }
>
> +static void ftm_rtc_shutdown(struct platform_device *pdev)
> +{
> + struct ftm_rtc *rtc = platform_get_drvdata(pdev);
> +
> + ftm_irq_acknowledge(rtc);
> + ftm_irq_disable(rtc);
> + ftm_clean_alarm(rtc);
If the alarm is able to start the platform, then you probably don't want
to disable the alarm on shutdown.
--
Alexandre Belloni, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
next prev parent reply other threads:[~2020-03-30 16:44 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-30 12:26 rtc: fsl-ftm-alarm: add shutdown interface Biwen Li
2020-03-30 16:44 ` Alexandre Belloni [this message]
2020-09-15 10:28 ` Alexandre Belloni
2020-09-15 10:35 ` [EXT] " Biwen Li
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=20200330164400.GE846876@piout.net \
--to=alexandre.belloni@bootlin.com \
--cc=biwen.li@nxp.com \
--cc=biwen.li@oss.nxp.com \
--cc=jiafei.pan@nxp.com \
--cc=leoyang.li@nxp.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rtc@vger.kernel.org \
/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.