]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blame - releases/4.14.60/regulator-pfuze100-add-.is_enable-for-pfuze100_swb_regulator_ops.patch
Fixes for 5.10
[thirdparty/kernel/stable-queue.git] / releases / 4.14.60 / regulator-pfuze100-add-.is_enable-for-pfuze100_swb_regulator_ops.patch
CommitLineData
a65d4bac
GKH
1From foo@baz Sat Jul 28 10:25:26 CEST 2018
2From: Anson Huang <Anson.Huang@nxp.com>
3Date: Thu, 17 May 2018 15:27:22 +0800
4Subject: regulator: pfuze100: add .is_enable() for pfuze100_swb_regulator_ops
5
6From: Anson Huang <Anson.Huang@nxp.com>
7
8[ Upstream commit 0b01fd3d40fe6402e5fa3b491ef23109feb1aaa5 ]
9
10If is_enabled() is not defined, regulator core will assume
11this regulator is already enabled, then it can NOT be really
12enabled after disabled.
13
14Based on Li Jun's patch from the NXP kernel tree.
15
16Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
17Signed-off-by: Mark Brown <broonie@kernel.org>
18Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
19Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
20---
21 drivers/regulator/pfuze100-regulator.c | 1 +
22 1 file changed, 1 insertion(+)
23
24--- a/drivers/regulator/pfuze100-regulator.c
25+++ b/drivers/regulator/pfuze100-regulator.c
26@@ -158,6 +158,7 @@ static const struct regulator_ops pfuze1
27 static const struct regulator_ops pfuze100_swb_regulator_ops = {
28 .enable = regulator_enable_regmap,
29 .disable = regulator_disable_regmap,
30+ .is_enabled = regulator_is_enabled_regmap,
31 .list_voltage = regulator_list_voltage_table,
32 .map_voltage = regulator_map_voltage_ascend,
33 .set_voltage_sel = regulator_set_voltage_sel_regmap,