* [PATCH] mfd: tps65090: Return proper error if regmap_init_i2c fails
@ 2012-04-25 1:30 Axel Lin
2012-04-25 5:28 ` Venu Byravarasu
2012-05-09 15:48 ` Samuel Ortiz
0 siblings, 2 replies; 3+ messages in thread
From: Axel Lin @ 2012-04-25 1:30 UTC (permalink / raw)
To: linux-kernel; +Cc: Samuel Ortiz, Venu Byravarasu
Return proper error instead of 0 if regmap_init_i2c fails.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
drivers/mfd/tps65090.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/mfd/tps65090.c b/drivers/mfd/tps65090.c
index 47f802b..da821d9 100644
--- a/drivers/mfd/tps65090.c
+++ b/drivers/mfd/tps65090.c
@@ -286,10 +286,10 @@ static int __devinit tps65090_i2c_probe(struct i2c_client *client,
tps65090->rmap = regmap_init_i2c(tps65090->client,
&tps65090_regmap_config);
if (IS_ERR(tps65090->rmap)) {
- dev_err(&client->dev, "regmap_init failed with err: %ld\n",
- PTR_ERR(tps65090->rmap));
+ ret = PTR_ERR(tps65090->rmap);
+ dev_err(&client->dev, "regmap_init failed with err: %d\n", ret);
goto err_irq_exit;
- };
+ }
ret = mfd_add_devices(tps65090->dev, -1, tps65090s,
ARRAY_SIZE(tps65090s), NULL, 0);
--
1.7.5.4
^ permalink raw reply related [flat|nested] 3+ messages in thread* RE: [PATCH] mfd: tps65090: Return proper error if regmap_init_i2c fails
2012-04-25 1:30 [PATCH] mfd: tps65090: Return proper error if regmap_init_i2c fails Axel Lin
@ 2012-04-25 5:28 ` Venu Byravarasu
2012-05-09 15:48 ` Samuel Ortiz
1 sibling, 0 replies; 3+ messages in thread
From: Venu Byravarasu @ 2012-04-25 5:28 UTC (permalink / raw)
To: Axel Lin, linux-kernel@vger.kernel.org; +Cc: Samuel Ortiz
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 1443 bytes --]
Thanks for the patch.
Acked by: Venu Byravarasu<vbyravarasu@nvidia.com>
> -----Original Message-----
> From: Axel Lin [mailto:axel.lin@gmail.com]
> Sent: Wednesday, April 25, 2012 7:01 AM
> To: linux-kernel@vger.kernel.org
> Cc: Samuel Ortiz; Venu Byravarasu
> Subject: [PATCH] mfd: tps65090: Return proper error if regmap_init_i2c fails
>
> Return proper error instead of 0 if regmap_init_i2c fails.
>
> Signed-off-by: Axel Lin <axel.lin@gmail.com>
> ---
> drivers/mfd/tps65090.c | 6 +++---
> 1 files changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/mfd/tps65090.c b/drivers/mfd/tps65090.c
> index 47f802b..da821d9 100644
> --- a/drivers/mfd/tps65090.c
> +++ b/drivers/mfd/tps65090.c
> @@ -286,10 +286,10 @@ static int __devinit tps65090_i2c_probe(struct
> i2c_client *client,
> tps65090->rmap = regmap_init_i2c(tps65090->client,
> &tps65090_regmap_config);
> if (IS_ERR(tps65090->rmap)) {
> - dev_err(&client->dev, "regmap_init failed with err: %ld\n",
> - PTR_ERR(tps65090->rmap));
> + ret = PTR_ERR(tps65090->rmap);
> + dev_err(&client->dev, "regmap_init failed with err: %d\n", ret);
> goto err_irq_exit;
> - };
> + }
>
> ret = mfd_add_devices(tps65090->dev, -1, tps65090s,
> ARRAY_SIZE(tps65090s), NULL, 0);
> --
> 1.7.5.4
>
>
ÿôèº{.nÇ+·®+%Ëÿ±éݶ\x17¥wÿº{.nÇ+·¥{±þG«éÿ{ayº\x1dÊÚë,j\a¢f£¢·hïêÿêçz_è®\x03(éÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?¨èÚ&£ø§~á¶iOæ¬z·vØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?I¥
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] mfd: tps65090: Return proper error if regmap_init_i2c fails
2012-04-25 1:30 [PATCH] mfd: tps65090: Return proper error if regmap_init_i2c fails Axel Lin
2012-04-25 5:28 ` Venu Byravarasu
@ 2012-05-09 15:48 ` Samuel Ortiz
1 sibling, 0 replies; 3+ messages in thread
From: Samuel Ortiz @ 2012-05-09 15:48 UTC (permalink / raw)
To: Axel Lin; +Cc: linux-kernel, Venu Byravarasu
Hi Axel,
On Wed, Apr 25, 2012 at 09:30:36AM +0800, Axel Lin wrote:
> Return proper error instead of 0 if regmap_init_i2c fails.
>
> Signed-off-by: Axel Lin <axel.lin@gmail.com>
> ---
> drivers/mfd/tps65090.c | 6 +++---
> 1 files changed, 3 insertions(+), 3 deletions(-)
Patch applied, thanks.
Cheers,
Samuel.
--
Intel Open Source Technology Centre
http://oss.intel.com/
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-05-09 15:38 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-04-25 1:30 [PATCH] mfd: tps65090: Return proper error if regmap_init_i2c fails Axel Lin
2012-04-25 5:28 ` Venu Byravarasu
2012-05-09 15:48 ` Samuel Ortiz
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox