Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757278AbcC2O6q (ORCPT ); Tue, 29 Mar 2016 10:58:46 -0400 Received: from mezzanine.sirena.org.uk ([106.187.55.193]:51028 "EHLO mezzanine.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751105AbcC2O6o (ORCPT ); Tue, 29 Mar 2016 10:58:44 -0400 Date: Tue, 29 Mar 2016 07:58:23 -0700 From: Mark Brown To: Geert Uytterhoeven Cc: Bjorn Andersson , Krzysztof Kozlowski , Ivaylo Dimitrov , Liam Girdwood , "linux-kernel@vger.kernel.org" , Ulf Hansson , linux-mmc , linux-samsung-soc , Javier Martinez Canillas , Marek Szyprowski , linux-renesas-soc@vger.kernel.org Message-ID: <20160329145823.GK2350@sirena.org.uk> References: <1458587912-32665-1-git-send-email-broonie@kernel.org> <1458587912-32665-2-git-send-email-broonie@kernel.org> <56F0624C.8010004@gmail.com> <20160327090859.GH5028@sirena.org.uk> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="cN0A5YokcrYPGsSB" Content-Disposition: inline In-Reply-To: X-Cookie: If anything can go wrong, it will. User-Agent: Mutt/1.5.24 (2015-08-30) X-SA-Exim-Connect-IP: 12.139.153.2 X-SA-Exim-Mail-From: broonie@sirena.org.uk Subject: Re: [PATCH 2/2] regulator: core: Ensure we are at least in bounds for our constraints X-SA-Exim-Version: 4.2.1 (built Mon, 26 Dec 2011 16:24:06 +0000) X-SA-Exim-Scanned: Yes (on mezzanine.sirena.org.uk) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2208 Lines: 58 --cN0A5YokcrYPGsSB Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Tue, Mar 29, 2016 at 02:00:52PM +0200, Geert Uytterhoeven wrote: > On Sun, Mar 27, 2016 at 11:08 AM, Mark Brown wrote: > > The existing check in the patch should be an || not an ==, or possibly > > we should just not bother looking for min_uV at all. I just pushed out > > a version of that, let's see how that goes. > Has the fix really been pushed out? Yes. > WARNING: CPU: 1 PID: 31 at drivers/regulator/core.c:2223 > _regulator_disable+0x2c/0x128 > unbalanced disables for SDHI0 VccQ > when booting on r8a7791/koelsch. This seems like a bug somewhere else in your code, we're looking at changes in the voltage setting code but this is an unbalanced disable. > I'm a bit confused by the discussion of "&&" vs. "||" vs. "==", but the > warnings do go away when using "!=", cfr. the whitespace-damaged patch below. > /* Voltage change possible? */ > - if (constraints->min_uV && constraints->max_uV) { > + if (constraints->min_uV != constraints->max_uV) { Do you have constraints that specify a maximum voltage but no minimum (which I'd say are broken), or constraints that are just plain wrong but are now being applied like specifying the entire range of the regulator? The above might be some follow on error handling from something that happened the change in handling of the constraints. You need to look at what the relevant regulator constraints are... Previously both voltages needed to be non-zero and equal for anything to happen, now they only need to both be non-zero. --cN0A5YokcrYPGsSB Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJW+pgMAAoJECTWi3JdVIfQCucH/1/USTGFrgDo9MmHSTdjircd 2/eqh3nsosSxmmlgjURnNI30aTA+GnRt4RQKudT4FrlYdKfTjLwi3pIBG+ErOHHq wD8C0Zt6JKfb68Ghzgsf63kM7wHwL6VCBVOFxP55KzYAhtiAnb0Dsu10c/coeNNM aaSqhy31/0MoU0p4f/OF+9h8NqR84nWS7qnJcTNS20FHV5iVhs75X3Q1csTfetoT PuVvJ260fDrfsf778Ex9+To0CHkaKJYfcmCKfvNev869C4RGwBDfHHqey2XmlIUW +CH7aj13KOJLxwvvF+Bj4Y+l3wJ4WWSb+y5dnTFZHQfGQz+oTIobckSl0we0NYs= =hoVL -----END PGP SIGNATURE----- --cN0A5YokcrYPGsSB--