regulator: core.c: Improve a comment
diff mbox series

Message ID 20210421055236.13148-1-sebastian.fricke@posteo.net
State Accepted
Commit 72241e3190f2be668d60493cf0343ec535357b5e
Headers show
Series
  • regulator: core.c: Improve a comment
Related show

Commit Message

Sebastian Fricke April 21, 2021, 5:52 a.m. UTC
s/regulator may on/regulator may already be enabled/
s/or left on/or was left on/

The aim of this patch is to make the comment more readable and to make
it clear, that this is about a regulator, that is already enabled instead
of a regulator that may be switched on.

Signed-off-by: Sebastian Fricke <sebastian.fricke@posteo.net>
---
 drivers/regulator/core.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

Comments

Mark Brown April 21, 2021, 7:03 p.m. UTC | #1
On Wed, 21 Apr 2021 05:52:37 +0000, Sebastian Fricke wrote:
> s/regulator may on/regulator may already be enabled/
> s/or left on/or was left on/
> 
> The aim of this patch is to make the comment more readable and to make
> it clear, that this is about a regulator, that is already enabled instead
> of a regulator that may be switched on.

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next

Thanks!

[1/1] regulator: core.c: Improve a comment
      commit: 72241e3190f2be668d60493cf0343ec535357b5e

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

Patch
diff mbox series

diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
index 16114aea099a..1fb1f586bb6d 100644
--- a/drivers/regulator/core.c
+++ b/drivers/regulator/core.c
@@ -2650,7 +2650,10 @@  static int _regulator_enable(struct regulator *regulator)
 		goto err_disable_supply;
 
 	if (rdev->use_count == 0) {
-		/* The regulator may on if it's not switchable or left on */
+		/*
+		 * The regulator may already be enabled if it's not switchable
+		 * or was left on
+		 */
 		ret = _regulator_is_enabled(rdev);
 		if (ret == -EINVAL || ret == 0) {
 			if (!regulator_ops_is_valid(rdev,