* Patch "power: supply: axp288_fuel_gauge: Fix fuel_gauge_reg_readb return on error" has been added to the 4.9-stable tree
@ 2017-10-05 8:30 gregkh
0 siblings, 0 replies; only message in thread
From: gregkh @ 2017-10-05 8:30 UTC (permalink / raw)
To: hdegoede, alexander.levin, gregkh, sre; +Cc: stable, stable-commits
This is a note to let you know that I've just added the patch titled
power: supply: axp288_fuel_gauge: Fix fuel_gauge_reg_readb return on error
to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
power-supply-axp288_fuel_gauge-fix-fuel_gauge_reg_readb-return-on-error.patch
and it can be found in the queue-4.9 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.
>From foo@baz Thu Oct 5 10:28:31 CEST 2017
From: Hans de Goede <hdegoede@redhat.com>
Date: Wed, 14 Dec 2016 17:38:50 +0100
Subject: power: supply: axp288_fuel_gauge: Fix fuel_gauge_reg_readb return on error
From: Hans de Goede <hdegoede@redhat.com>
[ Upstream commit 6f074bc878dc9b00c0df0bf3a8cb1d9e294cd881 ]
If reading the register fails, return the actual error code, instead
of the uninitialized val variable;
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Sebastian Reichel <sre@kernel.org>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
drivers/power/supply/axp288_fuel_gauge.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
--- a/drivers/power/supply/axp288_fuel_gauge.c
+++ b/drivers/power/supply/axp288_fuel_gauge.c
@@ -169,8 +169,10 @@ static int fuel_gauge_reg_readb(struct a
break;
}
- if (ret < 0)
+ if (ret < 0) {
dev_err(&info->pdev->dev, "axp288 reg read err:%d\n", ret);
+ return ret;
+ }
return val;
}
Patches currently in stable-queue which might be from hdegoede@redhat.com are
queue-4.9/iio-adc-axp288-drop-bogus-axp288_adc_ts_pin_ctrl-register-modifications.patch
queue-4.9/power-supply-axp288_fuel_gauge-fix-fuel_gauge_reg_readb-return-on-error.patch
queue-4.9/extcon-axp288-use-vbus-valid-instead-of-present-to-determine-cable-presence.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-10-05 8:32 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-05 8:30 Patch "power: supply: axp288_fuel_gauge: Fix fuel_gauge_reg_readb return on error" has been added to the 4.9-stable tree gregkh
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.