Received: by 10.192.165.148 with SMTP id m20csp5093187imm; Tue, 8 May 2018 22:09:13 -0700 (PDT) X-Google-Smtp-Source: AB8JxZpVXwQGEZhbygGPIHxvcXHXf+LBryzfwLSnwjOw9ngj2LmwCD14p33X0KXAiK8bkb15mp/Y X-Received: by 2002:a17:902:74c6:: with SMTP id f6-v6mr30333766plt.7.1525842553388; Tue, 08 May 2018 22:09:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525842553; cv=none; d=google.com; s=arc-20160816; b=XaA0HykpnYs48MqBEW9KxbhnpiS10uQ1/Bt7JypkRY0K97Gq9DV3HBy95R+EziyuWs Zct9lM7I/UCl+w/dsht6ht/ABFn1UbCUM6jed4csBolGFXayU4vpffcoJmi1nia+XBza OUZEmKLZwjWw29GTiu9DjQ87THZb2IpAKrr2eg7CuFCp3oAgNiR2k40wfEQ8504hzimI rW74qjGiscOmnuovsWA2RZCfHKjznsAIMSUxgRg/XtQTRpbo6fVLiRqK8/bh9tCaIfZM MH7JNH+W/9xIHO6Nczpr+0WlF+AuB7np4+e8fPHw3aRcOizyiHBEeja/HNiyyQXOpUOx C7Kg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=huMhz+XruJLcza2SdzQCVxRAx+NPlOEvtJjnNyYEMwQ=; b=F1VpG1+IFQcIS4o+qVePltI3Z3WAcL7ekp2KzMeMWliTCODACa2GHGAs5gST2XbB85 B1Q5lbjRLVHkGcvBF7/StSESD76kJ473heNlE5bZFPJEVG9kchRDq0UO/bzf/WWV5EhF SPiiptKvVaJE580EV66W2HC8zwzZwrPehxIg2wQ7jmBSIZLi9enZmZx0eY57CBiR5/MJ shhNsllTBkAm8WPZQMpCCP5AMkFcR9EMDwNyhG6yYGr3XbM/Y3bmXxdGOc9U0N30O4U9 Aoqd9EJuQNmszevK/0igtonp9HdXJBB+ScCG16iL6q/Gh/IR8R36zv2zle3ktuleLi5l ijHA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b190-v6si12696192pgc.18.2018.05.08.22.08.58; Tue, 08 May 2018 22:09:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756064AbeEIFGv (ORCPT + 99 others); Wed, 9 May 2018 01:06:51 -0400 Received: from metis.ext.pengutronix.de ([85.220.165.71]:43053 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756020AbeEIFGu (ORCPT ); Wed, 9 May 2018 01:06:50 -0400 Received: from pty.hi.pengutronix.de ([2001:67c:670:100:1d::c5]) by metis.ext.pengutronix.de with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1fGHJA-0004il-81; Wed, 09 May 2018 07:06:32 +0200 Received: from ore by pty.hi.pengutronix.de with local (Exim 4.89) (envelope-from ) id 1fGHJ6-0003iU-ES; Wed, 09 May 2018 07:06:28 +0200 Date: Wed, 9 May 2018 07:06:28 +0200 From: Oleksij Rempel To: Russell King - ARM Linux Cc: Mark Rutland , devicetree@vger.kernel.org, Michael Turquette , Stephen Boyd , linux-kernel@vger.kernel.org, Rob Herring , Liam Girdwood , Mark Brown , kernel@pengutronix.de, Fabio Estevam , Andrew Morton , Leonard Crestez , Shawn Guo , linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v6 2/6] ARM: imx6: register pm_power_off handler if "fsl,pmic-stby-poweroff" is set Message-ID: <20180509050628.csbusplowpvmmiwa@pengutronix.de> References: <20180305102524.5905-1-o.rempel@pengutronix.de> <20180305102524.5905-3-o.rempel@pengutronix.de> <20180508124033.GL16141@n2100.armlinux.org.uk> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="soqpjcx3im3qprt5" Content-Disposition: inline In-Reply-To: <20180508124033.GL16141@n2100.armlinux.org.uk> X-Sent-From: Pengutronix Hildesheim X-URL: http://www.pengutronix.de/ X-IRC: #ptxdist @freenode X-Accept-Language: de,en X-Accept-Content-Type: text/plain X-Uptime: 07:01:48 up 138 days, 17:39, 70 users, load average: 0.68, 0.23, 0.07 User-Agent: NeoMutt/20170113 (1.7.2) X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::c5 X-SA-Exim-Mail-From: ore@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --soqpjcx3im3qprt5 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, May 08, 2018 at 01:40:33PM +0100, Russell King - ARM Linux wrote: > On Mon, Mar 05, 2018 at 11:25:19AM +0100, Oleksij Rempel wrote: > > One of the Freescale recommended sequences for power off with external > > PMIC is the following: > > ... > > 3. SoC is programming PMIC for power off when standby is asserted. > > 4. In CCM STOP mode, Standby is asserted, PMIC gates SoC supplies. > >=20 > > See: > > http://www.nxp.com/assets/documents/data/en/reference-manuals/IMX6DQRM.= pdf > > page 5083 > >=20 > > This patch implements step 4. of this sequence. > >=20 > > Signed-off-by: Oleksij Rempel > > --- > > arch/arm/mach-imx/pm-imx6.c | 25 +++++++++++++++++++++++++ > > 1 file changed, 25 insertions(+) > >=20 > > diff --git a/arch/arm/mach-imx/pm-imx6.c b/arch/arm/mach-imx/pm-imx6.c > > index ecdf071653d4..24689260a2a5 100644 > > --- a/arch/arm/mach-imx/pm-imx6.c > > +++ b/arch/arm/mach-imx/pm-imx6.c > > @@ -604,6 +604,28 @@ static void __init imx6_pm_common_init(const struc= t imx6_pm_socdata > > IMX6Q_GPR1_GINT); > > } > > =20 > > +static void imx6_pm_stby_poweroff(void) > > +{ > > + imx6_set_lpm(STOP_POWER_OFF); > > + cpu_suspend(0, imx6q_suspend_finish); >=20 > Do you actually need to save the processor state etc here - the request > is after all to power down the system and not to suspend. Would calling > imx6q_suspend_finish() directly work (and hence simplify the code) ? yes you right. This will work as well. I'll send changed version after Rafaels feedback for kernel/reboot.c part. Russell, can I expect your Signed-off-by for changed patch? --=20 Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | --soqpjcx3im3qprt5 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCAAdFiEEpENFL0P3hvQ7p0DDdQOiSHVI77QFAlrygdAACgkQdQOiSHVI 77R93Qf+K3DxiMZbVQizzjCvsHOT4tntdIwXjwTzgw8o/vU1QDCNU+NK+vbFnbFW D6BlSnJyU03IivY4Z1+5m/J3xzYvqWiXjyVwuOEVk9HRpbIgEQkZP7ClXvC7ZJo0 chLpRlDSvejxp1M5dhyuvZqK60IMnRdqdqQnWy24neucvK1l301w8C1cY2ZIP6IN SxVDOw6Li+BDcS6eFxGlORVXpJcej6ulWYtsxLyWQtFM8VqPB+uK/GvUHG9ZQsd+ Fx4Y2XwvVALPK33HNjgV2m/gkGc2tC2IOniIg6v16LXiqTV9d5jMS75jpAUnxWQH woku+n846M17jvaOU2uUe35+tpWY6g== =M5Xn -----END PGP SIGNATURE----- --soqpjcx3im3qprt5--