Received: by 10.213.65.68 with SMTP id h4csp813689imn; Wed, 4 Apr 2018 07:43:15 -0700 (PDT) X-Google-Smtp-Source: AIpwx48KE66H2f1HGHgPhEjKeE4ucdt7M2OX1yQKSRL7Nj8SDTwZBHR3t+11+a5h7ymNYxYzgl4Q X-Received: by 10.101.97.16 with SMTP id z16mr12412114pgu.23.1522852995880; Wed, 04 Apr 2018 07:43:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522852995; cv=none; d=google.com; s=arc-20160816; b=ykr9hNaUA7+EPHJM4XBtbT8rX26GHb1CfHJUMEvZLOy+yV8y24u+ERrFRBn8n5eB4d porxQru7UjNp2ztFyjvqd6lro195jZi8F64Jv8WLIeBIeUWLE0kpzQ9OTLKo8e/6HOzF Bt1mokrDTnO6PjYvUu+7u2lHdP1i8Xk8T2NG2Fq3xSQDDS093UN2gdTRLeE/VK9Mbu0i jfLqSZ5S0jMDhZ3eT0G+iAMYw9USSRkRjw5zBzakQW5OGgwSan7B5NIy4IPJCJxgWvWi 2d2ZiVdD2ale8hp1Yx717TKTWlxZHcEgxJ3NezWWF9b04wo4BjUscekNnrP+FJnkEkIq V2gA== 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:dkim-signature:arc-authentication-results; bh=vc1urwU6bZOmVpyhDDbsIdl3Qd+2sxG0cIW953zEhzU=; b=O/oRz21LqwbkYFVqOe4BgBQWL2ED33uOxbCwQvJMhK7LlQy47ZSo/BKrN2/QABP8hB TGrfQQnNoZ1fgX5n7S+lsyOmuXr66r82VOyawLXdZfRS5ieJ5lQhX2VG+4KFDSETSa/j cEOV5cDmdlL1MELMNhW+Rq6Iwc4vMr7K0J4L9IVqpmXrcZXLck8xF7UEh6hLCeN7TSgK dIQISiolpTnO/Hio0PqErJXONOpYot8zvVpIFEb29CndK/86iQ44f6mDBj9x12jAqw2r sgCqd6g9Ds0qEXhIBwC0h6hwVv6RZ3Y5AOz9JspVWJTl5jVHl/qiwKOyIe09j24nMSTI o+FQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=CJa8ZmcO; 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 64-v6si3196058plk.152.2018.04.04.07.43.00; Wed, 04 Apr 2018 07:43:15 -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; dkim=fail header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=CJa8ZmcO; 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 S1751442AbeDDOlr (ORCPT + 99 others); Wed, 4 Apr 2018 10:41:47 -0400 Received: from heliosphere.sirena.org.uk ([172.104.155.198]:53270 "EHLO heliosphere.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751247AbeDDOlp (ORCPT ); Wed, 4 Apr 2018 10:41:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sirena.org.uk; s=20170815-heliosphere; h=In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=vc1urwU6bZOmVpyhDDbsIdl3Qd+2sxG0cIW953zEhzU=; b=CJa8ZmcORjedIB1hXZhiInM+L D6NFG5yfyzgnQECswrh7enZHQVk/U4QZxtX46BgDWwpIRVXb0p9Dsa0QVqSUqQ3wK+e/dGizf0DCb QEt1EjxLNJusn2iscGxx0eV4g6KRw/gTH2hsYmdLIfo1EB+nn5BvJ/lVjj1MaqFeGX7JQ=; Received: from debutante.sirena.org.uk ([2001:470:1f1d:6b5::3] helo=debutante) by heliosphere.sirena.org.uk with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1f3jbE-00055z-BJ; Wed, 04 Apr 2018 14:41:20 +0000 Received: from broonie by debutante with local (Exim 4.90_1) (envelope-from ) id 1f3jbD-0001sj-Df; Wed, 04 Apr 2018 15:41:19 +0100 Date: Wed, 4 Apr 2018 15:41:19 +0100 From: Mark Brown To: Andrew Lunn Cc: Tim Harvey , Lee Jones , Rob Herring , Mark Rutland , Dmitry Torokhov , Wim Van Sebroeck , Guenter Roeck , linux-hwmon@vger.kernel.org, devicetree@vger.kernel.org, linux-watchdog@vger.kernel.org, Randy Dunlap , linux-kernel@vger.kernel.org, linux-input@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v3 2/4] mfd: add Gateworks System Controller core driver Message-ID: <20180404144119.GD7691@sirena.org.uk> References: <1522250043-8065-1-git-send-email-tharvey@gateworks.com> <1522250043-8065-3-git-send-email-tharvey@gateworks.com> <20180403164715.GA5676@lunn.ch> <20180404131239.GD20869@lunn.ch> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="5gxpn/Q6ypwruk0T" Content-Disposition: inline In-Reply-To: <20180404131239.GD20869@lunn.ch> X-Cookie: An idle mind is worth two in the bush. User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --5gxpn/Q6ypwruk0T Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Apr 04, 2018 at 03:12:39PM +0200, Andrew Lunn wrote: > > What about the 'reset' functionality? Is there something in the power > > supply API for hooking in a GPIO based power switch (in my case it > > would be i2c) as I would think that would be common for ATX supplies? > > I didn't see anything in Documentation/power. > > This is what led me to the restart handler idea. Ultimately when > > someone issues a 'reboot' I would like it to use the GSC to > > power-cycle the board. > I think you end up with the same problem. By the time you need to turn > the power supply off, too much of the kernel is shut down to be able > to use I2C. And if you are in the middle of an Oops, you have no idea > of the current state. Another I2C transaction could be under way etc. > All the current reset drivers are pretty much self contained, atomic > and use KISS hardware like a GPIO. > Maybe you best bet is to see if you can find any other I2C PMICs which > the kernel supports. Most systems have a handshake for final power down via asserting signals rather than using register writes, the final power down sequence usually runs way after software. There's a few things that don't which just unceremoniously cut the power earlier on without completing the full power down sequence which for all practical purposes mostly works. --5gxpn/Q6ypwruk0T Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAlrE5A4ACgkQJNaLcl1U h9DgoAf+NlREIN0n4GCyKvQf462pdjqt/gmnsC2BNEK8Mj1EUiX+m6x776go5EtQ 1Ss8tiBw6FqizVl/UEreGaSKAla/G3ksf4WXY8Y1DLnh86vLF13njlSFTSTUd+9I R+FuERcjkksvH47j2+xhznMf8gTSrlzJnnuWPjqfFXMlGCeOIdeiNpg/CzcTYnBD q2SZYWYAaqA9fJ8rc6ZDealK5U1cnCzyZiJCqGDBHtl3PgmZWFXjHAMfM86MfY9p 2yur6ADSkx9kOwe20LA8aZGcU9EZzAhiRakUm4d/ovXH+w+faj+rt+UH943uabZW 8i7kHaRzOBsVCA11FgDYY14UcJcXDQ== =3nwB -----END PGP SIGNATURE----- --5gxpn/Q6ypwruk0T--