From: Horia Geanta <horia.geanta@nxp.com>
To: "André Draszik" <git@andred.net>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Cc: Anson Huang <anson.huang@nxp.com>,
Dmitry Torokhov <dmitry.torokhov@gmail.com>,
Aymen Sghaier <aymen.sghaier@nxp.com>,
Herbert Xu <herbert@gondor.apana.org.au>,
"David S. Miller" <davem@davemloft.net>,
Rob Herring <robh+dt@kernel.org>,
Mark Rutland <mark.rutland@arm.com>,
"linux-crypto@vger.kernel.org" <linux-crypto@vger.kernel.org>,
"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
"linux-input@vger.kernel.org" <linux-input@vger.kernel.org>,
Robin Gong <yibin.gong@nxp.com>, dl-linux-imx <linux-imx@nxp.com>
Subject: Re: [PATCH 1/3] ARM: dts: imx7s: add snvs clock to pwrkey
Date: Fri, 7 Feb 2020 07:36:59 +0000 [thread overview]
Message-ID: <VI1PR0402MB3485BFC1B2BD9842ACE2E834981C0@VI1PR0402MB3485.eurprd04.prod.outlook.com> (raw)
In-Reply-To: 20200130204516.4760-1-git@andred.net
On 1/30/2020 10:45 PM, André Draszik wrote:
> On i.MX7, the SNVS requires a clock. This is similar to the clock
> bound to the SNVS RTC node, but if the SNVS RTC driver isn't enabled,
> then SNVS doesn't work, and as such the pwrkey driver doesn't
> work (i.e. hangs the kernel, as the clock isn't enabled).
>
This is true also for i.MX8M.
For this reason it would probably better splitting the
DT bindings update in a separate patch.
> Also see commit ec2a844ef7c1
> ("ARM: dts: imx7s: add snvs rtc clock")
> for a similar fix.
>
> Signed-off-by: André Draszik <git@andred.net>
> Cc: Anson Huang <Anson.Huang@nxp.com>
> Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>
> Cc: "Horia Geantă" <horia.geanta@nxp.com>
> Cc: Aymen Sghaier <aymen.sghaier@nxp.com>
> Cc: Herbert Xu <herbert@gondor.apana.org.au>
> Cc: "David S. Miller" <davem@davemloft.net>
> Cc: Rob Herring <robh+dt@kernel.org>
> Cc: Mark Rutland <mark.rutland@arm.com>
> Cc: linux-crypto@vger.kernel.org
> Cc: devicetree@vger.kernel.org
> Cc: linux-input@vger.kernel.org
Reviewed-by: Horia Geantă <horia.geanta@nxp.com>
> ---
> .../devicetree/bindings/crypto/fsl-sec4.txt | 17 +++++++++++++++++
> arch/arm/boot/dts/imx7s.dtsi | 2 ++
> 2 files changed, 19 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/crypto/fsl-sec4.txt b/Documentation/devicetree/bindings/crypto/fsl-sec4.txt
> index 2fe245ca816a..755c2838d658 100644
> --- a/Documentation/devicetree/bindings/crypto/fsl-sec4.txt
> +++ b/Documentation/devicetree/bindings/crypto/fsl-sec4.txt
> @@ -449,6 +449,19 @@ System ON/OFF key driver
> Value type: <phandle>
> Definition: this is phandle to the register map node.
>
> + - clocks
> + Usage: optional, required if SNVS LP requires explicit
> + enablement of clocks
> + Value type: <prop_encoded-array>
> + Definition: a clock specifier describing the clock required for
> + enabling and disabling SNVS LP RTC.
> +
> + - clock-names
> + Usage: optional, required if SNVS LP requires explicit
> + enablement of clocks
> + Value type: <string>
> + Definition: clock name string should be "snvs-pwrkey".
> +
> EXAMPLE:
> snvs-pwrkey@020cc000 {
> compatible = "fsl,sec-v4.0-pwrkey";
> @@ -456,6 +469,8 @@ EXAMPLE:
> interrupts = <0 4 0x4>
> linux,keycode = <116>; /* KEY_POWER */
> wakeup-source;
> + clocks = <&clks IMX7D_SNVS_CLK>;
> + clock-names = "snvs-pwrkey";
> };
>
> =====================================================================
> @@ -547,6 +562,8 @@ FULL EXAMPLE
> interrupts = <0 4 0x4>;
> linux,keycode = <116>; /* KEY_POWER */
> wakeup-source;
> + clocks = <&clks IMX7D_SNVS_CLK>;
> + clock-names = "snvs-pwrkey";
> };
> };
>
> diff --git a/arch/arm/boot/dts/imx7s.dtsi b/arch/arm/boot/dts/imx7s.dtsi
> index 1b812f4e7453..6240a6f58048 100644
> --- a/arch/arm/boot/dts/imx7s.dtsi
> +++ b/arch/arm/boot/dts/imx7s.dtsi
> @@ -614,6 +614,8 @@
> linux,keycode = <KEY_POWER>;
> wakeup-source;
> status = "disabled";
> + clocks = <&clks IMX7D_SNVS_CLK>;
> + clock-names = "snvs-pwrkey";
> };
> };
>
>
prev parent reply other threads:[~2020-02-07 7:37 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-30 20:45 [PATCH 1/3] ARM: dts: imx7s: add snvs clock to pwrkey André Draszik
2020-01-30 20:45 ` [PATCH 2/3] Input: snvs_pwrkey - enable snvs clock as needed André Draszik
2020-02-07 8:10 ` Horia Geanta
2020-02-09 22:38 ` Dmitry Torokhov
2020-02-10 2:03 ` Robin Gong
2020-02-10 6:33 ` Horia Geanta
2020-02-10 17:55 ` Dmitry Torokhov
2020-02-11 1:54 ` Robin Gong
2020-02-11 9:13 ` André Draszik
2020-02-12 0:58 ` Robin Gong
2020-02-06 18:30 ` [PATCH 1/3] ARM: dts: imx7s: add snvs clock to pwrkey Rob Herring
2020-02-07 7:36 ` Horia Geanta [this message]
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=VI1PR0402MB3485BFC1B2BD9842ACE2E834981C0@VI1PR0402MB3485.eurprd04.prod.outlook.com \
--to=horia.geanta@nxp.com \
--cc=anson.huang@nxp.com \
--cc=aymen.sghaier@nxp.com \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=dmitry.torokhov@gmail.com \
--cc=git@andred.net \
--cc=herbert@gondor.apana.org.au \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-imx@nxp.com \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=robh+dt@kernel.org \
--cc=yibin.gong@nxp.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).