All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] regulator: pca9450: Fix return value when failing to get sd-vsel GPIO
@ 2021-02-22 15:08 Schrempf Frieder
  2021-02-22 15:16 ` Frieder Schrempf
  2021-02-24 16:58 ` Mark Brown
  0 siblings, 2 replies; 3+ messages in thread
From: Schrempf Frieder @ 2021-02-22 15:08 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown
  Cc: Frieder Schrempf, Rikard Falkeborn, Robin Gong, Axel Lin, linux-kernel

From: Frieder Schrempf <frieder.schrempf@kontron.de>

This fixes the return value of pca9450_i2c_probe() to use the correct
error code when getting the sd-vsel GPIO fails.

Signed-off-by: Frieder Schrempf <frieder.schrempf@kontron.de>
---
 drivers/regulator/pca9450-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/pca9450-regulator.c b/drivers/regulator/pca9450-regulator.c
index d38109cc3a01..2f7ee212cb8c 100644
--- a/drivers/regulator/pca9450-regulator.c
+++ b/drivers/regulator/pca9450-regulator.c
@@ -822,7 +822,7 @@ static int pca9450_i2c_probe(struct i2c_client *i2c,
 
 	if (IS_ERR(pca9450->sd_vsel_gpio)) {
 		dev_err(&i2c->dev, "Failed to get SD_VSEL GPIO\n");
-		return ret;
+		return PTR_ERR(pca9450->sd_vsel_gpio);
 	}
 
 	dev_info(&i2c->dev, "%s probed.\n",
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] regulator: pca9450: Fix return value when failing to get sd-vsel GPIO
  2021-02-22 15:08 [PATCH] regulator: pca9450: Fix return value when failing to get sd-vsel GPIO Schrempf Frieder
@ 2021-02-22 15:16 ` Frieder Schrempf
  2021-02-24 16:58 ` Mark Brown
  1 sibling, 0 replies; 3+ messages in thread
From: Frieder Schrempf @ 2021-02-22 15:16 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown
  Cc: Rikard Falkeborn, Robin Gong, Axel Lin, linux-kernel

On 22.02.21 16:08, Schrempf Frieder wrote:
> From: Frieder Schrempf <frieder.schrempf@kontron.de>
> 
> This fixes the return value of pca9450_i2c_probe() to use the correct
> error code when getting the sd-vsel GPIO fails.
> 
> Signed-off-by: Frieder Schrempf <frieder.schrempf@kontron.de>

Sorry, I just noticed, that the PR for v5.12 was already sent, but I 
think not yet pulled by Linus. So I probably should have waited for this 
to happen and added a proper Fixes tag. I guess I will just resend after 
the faulty patch found its way into Linus' tree.

> ---
>   drivers/regulator/pca9450-regulator.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/regulator/pca9450-regulator.c b/drivers/regulator/pca9450-regulator.c
> index d38109cc3a01..2f7ee212cb8c 100644
> --- a/drivers/regulator/pca9450-regulator.c
> +++ b/drivers/regulator/pca9450-regulator.c
> @@ -822,7 +822,7 @@ static int pca9450_i2c_probe(struct i2c_client *i2c,
>   
>   	if (IS_ERR(pca9450->sd_vsel_gpio)) {
>   		dev_err(&i2c->dev, "Failed to get SD_VSEL GPIO\n");
> -		return ret;
> +		return PTR_ERR(pca9450->sd_vsel_gpio);
>   	}
>   
>   	dev_info(&i2c->dev, "%s probed.\n",
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] regulator: pca9450: Fix return value when failing to get sd-vsel GPIO
  2021-02-22 15:08 [PATCH] regulator: pca9450: Fix return value when failing to get sd-vsel GPIO Schrempf Frieder
  2021-02-22 15:16 ` Frieder Schrempf
@ 2021-02-24 16:58 ` Mark Brown
  1 sibling, 0 replies; 3+ messages in thread
From: Mark Brown @ 2021-02-24 16:58 UTC (permalink / raw)
  To: Liam Girdwood, Schrempf Frieder
  Cc: Robin Gong, linux-kernel, Rikard Falkeborn, Axel Lin

On Mon, 22 Feb 2021 16:08:04 +0100, Schrempf Frieder wrote:
> This fixes the return value of pca9450_i2c_probe() to use the correct
> error code when getting the sd-vsel GPIO fails.

Applied to

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

Thanks!

[1/1] regulator: pca9450: Fix return value when failing to get sd-vsel GPIO
      commit: ef4848a6532ba0b241d3b6cad70378ff2c5615ca

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

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-02-24 17:03 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-22 15:08 [PATCH] regulator: pca9450: Fix return value when failing to get sd-vsel GPIO Schrempf Frieder
2021-02-22 15:16 ` Frieder Schrempf
2021-02-24 16:58 ` Mark Brown

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.