[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <903012887a1b2f8f59e44b1cfb472c9362fd964f.1466441036.git.helen.koike@collabora.co.uk>
Date: Mon, 20 Jun 2016 14:12:33 -0300
From: Helen Koike <helen.koike@...labora.co.uk>
To: Sebastian Reichel <sre@...nel.org>
Cc: lgirdwood@...il.com, broonie@...nel.org, peter.ujfalusi@...com,
jarkko.nikula@...mer.com, lars@...afoo.de, k.kozlowski@...sung.com,
alsa-devel@...a-project.org, linux-kernel@...r.kernel.org,
linux-omap@...r.kernel.org, perex@...ex.cz, tiwai@...e.com,
cphealy@...il.com, Helen Koike <helen.koike@...labora.co.uk>
Subject: [PATCH v2 5/5] ASoC: tpa6130a2: Remove goto err_gpio
Replace goto err_gpio by return ret
Signed-off-by: Helen Koike <helen.koike@...labora.co.uk>
---
Changes since v1:
- this is a new patch in the series
sound/soc/codecs/tpa6130a2.c | 11 ++++-------
1 file changed, 4 insertions(+), 7 deletions(-)
diff --git a/sound/soc/codecs/tpa6130a2.c b/sound/soc/codecs/tpa6130a2.c
index cc83870..a919308 100644
--- a/sound/soc/codecs/tpa6130a2.c
+++ b/sound/soc/codecs/tpa6130a2.c
@@ -255,7 +255,7 @@ static int tpa6130a2_probe(struct i2c_client *client,
if (ret < 0) {
dev_err(dev, "Failed to request power GPIO (%d)\n",
data->power_gpio);
- goto err_gpio;
+ return ret;
}
gpio_direction_output(data->power_gpio, 0);
}
@@ -276,12 +276,12 @@ static int tpa6130a2_probe(struct i2c_client *client,
if (IS_ERR(data->supply)) {
ret = PTR_ERR(data->supply);
dev_err(dev, "Failed to request supply: %d\n", ret);
- goto err_gpio;
+ return ret;
}
ret = tpa6130a2_power(data, true);
if (ret != 0)
- goto err_gpio;
+ return ret;
/* Read version */
@@ -293,13 +293,10 @@ static int tpa6130a2_probe(struct i2c_client *client,
/* Disable the chip */
ret = tpa6130a2_power(data, false);
if (ret != 0)
- goto err_gpio;
+ return ret;
return devm_snd_soc_register_component(&client->dev,
&tpa6130a2_component_driver, NULL, 0);
-
-err_gpio:
- return ret;
}
static const struct i2c_device_id tpa6130a2_id[] = {
--
1.9.1
Powered by blists - more mailing lists