From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mark Brown Subject: Re: [RFC PATCH v1 1/3] regulator: helpers: consider constriants in list_voltage_linear_range Date: Thu, 2 Jun 2016 12:05:57 +0100 Message-ID: <20160602110557.GH2282@sirena.org.uk> References: <1464862996-3147-1-git-send-email-srinivas.kandagatla@linaro.org> <1464862996-3147-2-git-send-email-srinivas.kandagatla@linaro.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="PNpeiK4tTqhYOExY" Return-path: Received: from mezzanine.sirena.org.uk ([106.187.55.193]:34974 "EHLO mezzanine.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932504AbcFBLGQ (ORCPT ); Thu, 2 Jun 2016 07:06:16 -0400 Content-Disposition: inline In-Reply-To: <1464862996-3147-2-git-send-email-srinivas.kandagatla@linaro.org> Sender: linux-arm-msm-owner@vger.kernel.org List-Id: linux-arm-msm@vger.kernel.org To: Srinivas Kandagatla Cc: bjorn.andersson@linaro.org, linux-kernel@vger.kernel.org, Liam Girdwood , linux-arm-msm@vger.kernel.org --PNpeiK4tTqhYOExY Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, Jun 02, 2016 at 11:23:14AM +0100, Srinivas Kandagatla wrote: > Regulator drivers can have linear range which is according to the > regualtor hardware spec, however the board level device tree files > can restrict this range by adding constriants. > These constriants are not considered in the exsiting code, which > gives false supported voltage range to the consumers. ... > For now I have added this support for regulator_list_voltage_linear_range() > If it makes sense we can extend this to other list voltage helpers too. Why are you making this change? The obvious problem here is that drivers should not be looking at constraints - it would be silly to duplicate constraint enforcing code in individual drivers and would lead to inconsistent performance of constraints. This is why we do this in the core, in _regulator_list_voltage(), which means that if this change has any effect there's something else going on that needs to be investigated. --PNpeiK4tTqhYOExY Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJXUBMUAAoJECTWi3JdVIfQeFMH/2FgzkplFUuMVg0pAefKiTK/ awDlzhwsjvTGYvYUcAgV+wm31EgglQLEHJ3i4VD0+KN0DpYU20z5R48TJdXY9GUS LnRqp1f1tO1QrSxYzzjw9uXntWIacJty02TfPrYSslCIf/vn6/H+uTDxHhvaLyDo SDovvcnnuxncjAmvhAcdWOylR94cTxToKrVgJvIRDAtJmOFp+rcLmxPIC7IaoyZD QH4/ygbC1lbQOwf8ASzWr4bhocOvYrMlfh1BpE3n36Hg1zuQ2xATSUd023mRJzwf Z4cvMw+9gLmenu+JehErEKiuOnYqIGiUEb5FkmyAzjtzFNMRM5gITk0kPeVc+Dc= =A7OZ -----END PGP SIGNATURE----- --PNpeiK4tTqhYOExY--