Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp558832imm; Wed, 23 May 2018 01:30:21 -0700 (PDT) X-Google-Smtp-Source: AB8JxZqIo/jcPbkjtc/QwjC9y6jqDsbkFDR3OfsDm+Dtjct+vrGw9PaPMIIAIwNxanSdnniqUIUL X-Received: by 2002:a62:e801:: with SMTP id c1-v6mr1962846pfi.184.1527064221212; Wed, 23 May 2018 01:30:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527064221; cv=none; d=google.com; s=arc-20160816; b=0JgHGzfWJuQ+nvO4OsXt7VSdHIlgvce6syPqxqJadcGV4/v6Ithqqq1tNtPmEMqE08 GYtfM73iuQ5tgW19Wmkr1RvoQqEBnrUGcnntxAZglKUFYaYm/HuEL7XxIrOZr3StxtRH ITP9vZgaqTwvATCNtVu1OUwAieT8OPVMYKeDV21+9Z55mmYBvRxu5tIU/uSax3XOm7da e2uc2d8pahYC24CD77ycd2GnkCFrCP1csMeQV8LzS209bKWJ0qxBfwcE4Ma3+Rj2mDXq JzXGihm99xDM2ftfO0/95zlj8nJx7rVcYlJ49jlQJ/wZMwZL2NTgsel543vS6dd9O9Bw cRtQ== 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=6M8njPukCdgIprwLGNpp0rCou+zGcH2TbqzEtGBxxzE=; b=WMNoK1evuxhadHPSvScrIO1Sg540fTpnRg7dvss0djIOTSx4Th6ZsScJ3eVTxR1B+G 8l3tNSsn3VYLb5a7Lb2G68WhGAhIa27+pyAsPl9XE8CNGYJSdaDIqRN1bED6ffYadyzz cmKZzLzg9EcyabDVoE0A97TS3aAqtugz8yR7MUWO8OXKoAaTzOT6qyy5bN4fEuVNXfRv PmZbLUpQuWdVmlD7m0Q1WY2kmnqwCMCndIIu9nbn0OcOxcfToDGyYLKQluKPQZN0zDho KQKvc0oqSL2LK8nig2D0p7xE1/WNZLBeJl9hDpw7ybRxTF9F75+J/vb6ia6jlxlGL24u zFXg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=WhZH3fCF; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q4-v6si15039918pgr.549.2018.05.23.01.30.06; Wed, 23 May 2018 01:30:21 -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=WhZH3fCF; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754547AbeEWI3R (ORCPT + 99 others); Wed, 23 May 2018 04:29:17 -0400 Received: from heliosphere.sirena.org.uk ([172.104.155.198]:57908 "EHLO heliosphere.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754340AbeEWI3M (ORCPT ); Wed, 23 May 2018 04:29:12 -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=6M8njPukCdgIprwLGNpp0rCou+zGcH2TbqzEtGBxxzE=; b=WhZH3fCFedfJ/eyTM/e9m0Lao aTBgQlGiSloYuqd4dKEO3pw2nqI9CcjtYlvBK6XwXJz0/y0JM67/IKFA2u80CjvfLuGj9+p0rT89d /Sd8fDp6nd4VKx17Eg1+bZAGPPFrR0/lpGmlBk1E9Vr6aZJQt4tIJJYWrAW0UqGG/012U=; 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 1fLP8v-00039Q-17; Wed, 23 May 2018 08:29:09 +0000 Received: from broonie by debutante with local (Exim 4.91) (envelope-from ) id 1fLP8u-0008Gx-It; Wed, 23 May 2018 09:29:08 +0100 Date: Wed, 23 May 2018 09:29:08 +0100 From: Mark Brown To: Doug Anderson Cc: David Collins , Liam Girdwood , Rob Herring , Mark Rutland , linux-arm-msm@vger.kernel.org, Linux ARM , devicetree@vger.kernel.org, LKML , Rajendra Nayak , Stephen Boyd Subject: Re: [PATCH v3 1/2] regulator: dt-bindings: add QCOM RPMh regulator bindings Message-ID: <20180523082908.GB4828@sirena.org.uk> References: <41d5df73ddac772551d2966e0752bb0c357b1ded.1526088081.git.collinsd@codeaurora.org> <869aad59-1cc5-28ef-1fb5-4ef846696c40@codeaurora.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="H1spWtNR+x+ondvy" Content-Disposition: inline In-Reply-To: X-Cookie: Excellent day to have a rotten day. User-Agent: Mutt/1.9.5 (2018-04-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --H1spWtNR+x+ondvy Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Tue, May 22, 2018 at 05:08:45PM -0700, Doug Anderson wrote: > So one client's vote for a voltage continues to be in effect even if > that client votes to have the regulator disabled? That seems > fundamentally broken in RPMh. I guess my take would be to work around It's arguable either way - you could say that the client gets to specify a safe range at all times or you could say that the machine constraints should cover all cases where the hardware is idling. Of course RPMh is missing anything like the machine constraints (as we can see from all the fixing up of undesirable hard coding we have to do) so it's kind of pushed towards the first case. > >> A) Turn off VMMC and VQMMC > >> B) Program VMMC and VQMMC to defaults > >> C) Turn on VMMC and VQMMC > >> ...right now we bootup and pretend to Linux that VMMC and VQMMC start > >> off, so step A) will be no-op. Sigh. > > Step A) would not work because the regulator's use_count would be 0 and > > regulator_disable() can only be called successfully if use_count > 0. The > > call would have no impact and it would return an error. > Are you sure regulator_force_disable() won't do the trick on most > boards (which will report the regulator being enabled at bootup)? I > haven't tried it, but it seems like it might. It does mean that things will go wrong if the regulator is shared. --H1spWtNR+x+ondvy Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAlsFJlMACgkQJNaLcl1U h9DDuQf+LqojdX4Kf5LOlLl6Y8kajKuiwIsdkNPtMsadit8Pr7L/0QQsSaY4haiX a49Bd610TYihV89EUS1KM/SxFbqqpvfhMN0vdYn9Txy7ysCjo5eJGpdoiFHaZul7 dLHn39zxKPdfcAJrNAJ084ZM4Yn2Qe3foD26yq63Gp0CueSYjzf2yO7knWEMPDDO VrTmjuMN2FJjdw4fP+QVhazikQnupACvbx3EykmuekymxXvGdEdgg1wBjQdfdvw6 oiSBFRB96KrIk392N07JqJ9OPEhMYZGrbzP7/wD4x9ABhOrIL66x2xk3KMsq8WKs U3qA3uBseAFOZboOt4PZcV8RsvFn9A== =VPXr -----END PGP SIGNATURE----- --H1spWtNR+x+ondvy--