The valid selector is 0 ~ 0xbf, so the .n_voltages should be 0xc0.
Signed-off-by: Axel Lin
---
drivers/regulator/mt6315-regulator.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/regulator/mt6315-regulator.c
b/drivers/regulator/mt6315-regulator.c
index fc7654624dd6
Leilk Liu 於 2021年3月3日 週三 上午10:57寫道:
>
> From: "leilk.liu"
>
> It is wanted to use MTK spi bus driver with GPL-2.0 or MIT license.
> But now it is only licensed as GPL-2.0, so re-license it as dual
> MIT/GPL.
>
> Signed-off-by: leilk.liu
Acked-by: Axel Lin
The voltages in pf8x00_sw7_voltages are in ascendant order, so use
regulator_map_voltage_ascend.
Signed-off-by: Axel Lin
---
drivers/regulator/pf8x00-regulator.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/regulator/pf8x00-regulator.c
b/drivers/regulator/pf8x00-regulator.c
-EINVAL is not a valid return value for .of_map_mode, return
REGULATOR_MODE_INVALID instead.
Signed-off-by: Axel Lin
---
drivers/regulator/mt6315-regulator.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/regulator/mt6315-regulator.c
b/drivers/regulator/mt6315
Trivial typo fix.
Signed-off-by: Axel Lin
---
drivers/regulator/pf8x00-regulator.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/regulator/pf8x00-regulator.c
b/drivers/regulator/pf8x00-regulator.c
index 827da25466cc..9b28bd63208d 100644
--- a/drivers/regulator
Fix build error when CONFIG_REGMAP_I2C is not set.
Signed-off-by: Axel Lin
---
drivers/regulator/Kconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/regulator/Kconfig b/drivers/regulator/Kconfig
index ebce11cbab44..f719ed5a8c33 100644
--- a/drivers/regulator/Kconfig
+++ b
Just use regmap_read/regmap_write/regmap_update_bits instead.
Signed-off-by: Axel Lin
---
drivers/regulator/lp8755.c | 82 ++
1 file changed, 21 insertions(+), 61 deletions(-)
diff --git a/drivers/regulator/lp8755.c b/drivers/regulator/lp8755.c
index
Fix possible NULL pointer dereference.
Signed-off-by: Axel Lin
---
drivers/regulator/cros-ec-regulator.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/regulator/cros-ec-regulator.c
b/drivers/regulator/cros-ec-regulator.c
index 3117bbd2826b..eb3fc1db4edc 100644
--- a/drivers
By checking data->pin_ctrl_enable / data->pin_ctrl_hpm flags first, then
use switch-case to improve readability.
Signed-off-by: Axel Lin
---
drivers/regulator/qcom_spmi-regulator.c | 70 -
1 file changed, 34 insertions(+), 36 deletions(-)
diff --git a/drivers/reg
Use module_i2c_driver to simplify driver init boilerplate.
Signed-off-by: Axel Lin
---
drivers/regulator/pca9450-regulator.c | 12 +---
1 file changed, 1 insertion(+), 11 deletions(-)
diff --git a/drivers/regulator/pca9450-regulator.c
b/drivers/regulator/pca9450-regulator.c
index
Fix below build warning:
drivers/mfd/axp20x-i2c.c:82:5: warning: "CONFIG_ACPI" is not defined, evaluates
to 0 [-Wundef]
82 | #if CONFIG_ACPI
| ^~~
Fixes: 20f359cb236b ("mfd: axp20x-i2c: Do not define 'struct acpi_device_id'
when !CONFIG_ACPI")
Sig
Add missing .owner field in regulator_desc, which is used for refcounting.
Signed-off-by: Axel Lin
---
drivers/regulator/fan53880.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/regulator/fan53880.c b/drivers/regulator/fan53880.c
index 285acc705a55..575d289b8e04 100644
The MFD part is merged into v5.8-rc1, thus remove BROKEN dependency.
Signed-off-by: Axel Lin
---
drivers/regulator/Kconfig | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/regulator/Kconfig b/drivers/regulator/Kconfig
index c398e90e0e73..f60eeaae7afd 100644
Mark Brown 於 2019年10月8日 週二 下午6:51寫道:
>
> On Tue, Oct 08, 2019 at 06:48:15PM +0800, Axel Lin wrote:
> > Mark Brown 於 2019年10月8日 週二 下午6:44寫道:
>
> > > It doesn't seem to apply against current code.
>
> > I just test apply it and It looks fine to be applied by lin
Mark Brown 於 2019年10月8日 週二 下午6:44寫道:
>
> On Tue, Oct 08, 2019 at 06:41:21PM +0800, Axel Lin wrote:
>
> > I'm wondering if any issue with this patch?
> > Note, this patch is for da9062 (not for da9063 which is already applied).
>
> It doesn't seem to apply against curr
Axel Lin 於 2019年10月7日 週一 下午7:50寫道:
>
> The sleep flag bit decides the mode for BUCK_MODE_MANUAL case, simplify
> the logic as the result is the same.
>
> Signed-off-by: Axel Lin
> Reviewed-by: Adam Thomson
Hi Mark,
I'm wondering if any issue with this patch?
Note, this p
These regulator_ops variables never need to be modified, make them const so
compiler can put them to .rodata.
Signed-off-by: Axel Lin
---
drivers/regulator/rk808-regulator.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/regulator/rk808-regulator.c
b
The implement is exactly the same as rk808_set_suspend_voltage, so just
use rk808_set_suspend_voltage instead.
Signed-off-by: Axel Lin
---
drivers/regulator/rk808-regulator.c | 17 +
1 file changed, 1 insertion(+), 16 deletions(-)
diff --git a/drivers/regulator/rk808
The default in rk817_set_ramp_delay is 25MV rather than 10MV.
Signed-off-by: Axel Lin
---
drivers/regulator/rk808-regulator.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/regulator/rk808-regulator.c
b/drivers/regulator/rk808-regulator.c
index eda056fce65f
It's more straightforward to use for statement here.
Signed-off-by: Axel Lin
Acked-by: Steve Twiss
---
This was sent on https://lkml.org/lkml/2019/7/11/208 with Adam's Ack.
drivers/regulator/da9062-regulator.c | 5 +
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers
The sleep flag bit decides the mode for BUCK_MODE_MANUAL case, simplify
the logic as the result is the same.
Signed-off-by: Axel Lin
Reviewed-by: Adam Thomson
---
This was sent on https://lkml.org/lkml/2019/9/26/24 with Adam's Review.
drivers/regulator/da9062-regulator.c | 9 +++--
1 file
Only the desc field is really used, so use struct regulator_desc instead.
Then struct pbias_regulator_data can be removed.
Signed-off-by: Axel Lin
---
drivers/regulator/pbias-regulator.c | 69 +++--
1 file changed, 26 insertions(+), 43 deletions(-)
diff --git a/drivers
Adam Thomson 於 2019年9月26日 週四 下午5:22寫道:
>
> On 26 September 2019 06:51, Axel Lin wrote:
>
> > The sleep flag bit decides the mode for BUCK_MODE_MANUAL case, simplify
> > the logic as the result is the same.
> >
> > Signed-off-by: Axel Lin
>
> This patch wi
est
iteration of the while loop. Fix it.
Signed-off-by: Axel Lin
---
drivers/regulator/ti-abb-regulator.c | 26 --
1 file changed, 8 insertions(+), 18 deletions(-)
diff --git a/drivers/regulator/ti-abb-regulator.c
b/drivers/regulator/ti-abb-regulator.c
index cced1ffb8
The sleep flag bit decides the mode for BUCK_MODE_MANUAL case, simplify
the logic as the result is the same.
Signed-off-by: Axel Lin
---
drivers/regulator/da9062-regulator.c | 9 +++--
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/regulator/da9062-regulator.c
b
The sleep flag bit decides the mode for BUCK_MODE_MANUAL case, simplify
the logic as the result is the same.
Signed-off-by: Axel Lin
---
drivers/regulator/da9063-regulator.c | 9 +++--
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/regulator/da9063-regulator.c
b
Use of_device_get_match_data to simplify the code a bit.
Signed-off-by: Axel Lin
---
drivers/regulator/pbias-regulator.c | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/regulator/pbias-regulator.c
b/drivers/regulator/pbias-regulator.c
index 92b41a6a4dc2
Use of_device_get_match_data which has NULL test for match before
dereference match->data. Add NULL test for drvtype so it still works
for fixed_voltage_ops when !CONFIG_OF.
Signed-off-by: Axel Lin
---
drivers/regulator/fixed.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
d
Use rdev->regmap/>dev instead of lp87565->regmap/lp87565->dev.
In additional, the lp87565->dev actually is the parent mfd device,
so the dev_err message is misleading here with lp87565->dev.
Signed-off-by: Axel Lin
---
v2: Add lp87565 prefix in subject line
drivers
Use rdev->regmap/>dev instead of lp87565->regmap/lp87565->dev.
In additional, the lp87565->dev actually is the parent mfd device,
so the dev_err message is misleading here with lp87565->dev.
Signed-off-by: Axel Lin
---
drivers/regulator/lp87565-regulator.c | 5 ++---
pport")
Signed-off-by: Axel Lin
---
This patch was sent on https://lkml.org/lkml/2019/7/11/203
This resend re-generate the patch against regulator tree for-5.3 branch.
Note there is a conflict with commit f3f4363b1239 on Linus' tree which is
merged from mfd tree.
("regulator: lp87565:
Mark Brown 於 2019年7月24日 週三 上午12:35寫道:
>
> On Tue, Jul 23, 2019 at 08:28:35PM +0800, Axel Lin wrote:
> > Mark Brown 於 2019年7月23日 週二 下午7:26寫道:
> > > On Thu, Jul 11, 2019 at 07:35:17PM +0800, Axel Lin wrote:
>
> > > > The "ti,lp87565" compat
Mark Brown 於 2019年7月23日 週二 下午7:26寫道:
>
> On Thu, Jul 11, 2019 at 07:35:17PM +0800, Axel Lin wrote:
> > The "ti,lp87565" compatible string is still in of_lp87565_match_table,
> > but current code will return -EINVAL because lp87565->dev_type is unknown.
> &g
Setting .n_voltages = 1 and .fixed_uV is enough for fixed regulator,
remove the redundant .min_uV and .list_voltage settings.
Signed-off-by: Axel Lin
---
drivers/regulator/stm32-booster.c | 4
1 file changed, 4 deletions(-)
diff --git a/drivers/regulator/stm32-booster.c
b/drivers
-EINVAL is not a valid return value for .of_map_mode, return
REGULATOR_MODE_INVALID instead.
Signed-off-by: Axel Lin
---
drivers/regulator/rk808-regulator.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/regulator/rk808-regulator.c
b/drivers/regulator/rk808
It's more straightforward to use for statement here.
Signed-off-by: Axel Lin
---
drivers/regulator/da9062-regulator.c | 5 +
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/regulator/da9062-regulator.c
b/drivers/regulator/da9062-regulator.c
index 2ffc64622451
pport")
Signed-off-by: Axel Lin
---
Hi Keerthy,
The commit "regulator: lp87565: Add 4-phase lp87561 regulator support" does not
mention why it returns -EINVAL for "ti,lp87565" (The data field is not set for
.compatible = "ti,lp87565"), so I think the support f
Axel Lin 於 2019年6月27日 週四 上午7:58寫道:
>
> > > With your current code where LM36274_LDO_VSEL_MAX and n_voltages is 0x34,
> > > the maximum voltage will become 40 + 5 * 0x34 = 6.6V which
> > > does not match the datasheet.
> >
> > Not sure how you g
Axel Lin 於 2019年6月26日 週三 下午11:12寫道:
>
> Dan Murphy 於 2019年6月26日 週三 下午11:07寫道:
> >
> > Hello
> >
> > On 6/26/19 8:26 AM, Axel Lin wrote:
> > > According to the datasheet https://www.ti.com/lit/ds/symlink/lm3632a.pdf
> > > Table 20. VPOS Bias
Hi Chen,
Chen Feng 於 2019年6月27日 週四 上午10:03寫道:
>
> Thanks
I assume this is an Ack.
If you can add your Acked-by in the reply, it's easier for maintainer to accept
the patch.
>
> On 2019/6/26 21:30, Axel Lin wrote:
> > Since devm_regmap_init_mmio_clk can fail, add ret
> > With your current code where LM36274_LDO_VSEL_MAX and n_voltages is 0x34,
> > the maximum voltage will become 40 + 5 * 0x34 = 6.6V which
> > does not match the datasheet.
>
> Not sure how you get 6.6v the LDO max is 6.5v.
>
> After 0x32->0x7f maps to 6.5v
>
> 00 = 4 V
> 01 =
Dan Murphy 於 2019年6月26日 週三 下午11:07寫道:
>
> Hello
>
> On 6/26/19 8:26 AM, Axel Lin wrote:
> > According to the datasheet http://www.ti.com/lit/ds/symlink/lm36274.pdf:
> > Table 23. VPOS Bias Register Field Descriptions VPOS[5:0]:
> > VPOS voltage (50-mV steps): VPOS
Dan Murphy 於 2019年6月26日 週三 下午11:07寫道:
>
> Hello
>
> On 6/26/19 8:26 AM, Axel Lin wrote:
> > According to the datasheet https://www.ti.com/lit/ds/symlink/lm3632a.pdf
> > Table 20. VPOS Bias Register Field Descriptions VPOS[5:0]
> > Sets the Positive Display Bias
Since devm_regmap_init_mmio_clk can fail, add return value checking.
Signed-off-by: Axel Lin
Acked-by: Chen Feng
---
This was sent on https://lkml.org/lkml/2019/3/6/904
drivers/mfd/hi655x-pmic.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/mfd/hi655x-pmic.c b/drivers/mfd
)
01: 5.55 V
100111: 5.95 V
101000: 6 V
Note: Codes 101001 to 11 map to 6 V
The LM3632_LDO_VSEL_MAX should be 0b101000 (0x28), so the maximum voltage
can match the datasheet.
Fixes: 3a8d1a73a037 ("regulator: add LM363X driver")
Signed-off-by: Axel Lin
---
drivers
pport for LM36274")
Signed-off-by: Axel Lin
---
drivers/regulator/lm363x-regulator.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/regulator/lm363x-regulator.c
b/drivers/regulator/lm363x-regulator.c
index e4a27d63bf90..4b9f618b07e9 100644
--- a/drivers/regula
Just use a local variable *ena_gpiod in slg51000_of_parse_cb instead.
With this change, the struct slg51000_pdata can be removed.
Signed-off-by: Axel Lin
---
drivers/regulator/slg51000-regulator.c | 17 ++---
1 file changed, 6 insertions(+), 11 deletions(-)
diff --git a/drivers
These regulator_ops variables never need to be modified, make them const so
compiler can put them to .rodata.
Signed-off-by: Axel Lin
---
drivers/regulator/slg51000-regulator.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/regulator/slg51000-regulator.c
b
Bartosz Golaszewski 於 2019年5月23日 週四 下午5:28寫道:
>
> Hi Axel,
>
> commit f979c08f7624 ("regulator: tps6507x: Convert to regulator core's
> simplified DT parsing code") causes the following crash on da850-evm
> board with linux v5.2-rc1:
The fix is already in regulator tree and linux-next tree:
t; Link: https://github.com/ClangBuiltLinux/linux/issues/491
> Signed-off-by: Nathan Chancellor
Reviewed-by: Axel Lin
A NULL init_data once incremented will lead to oops, fix it.
Fixes: f979c08f7624 ("regulator: tps6507x: Convert to regulator core's
simplified DT parsing code")
Reported-by: Sekhar Nori
Signed-off-by: Axel Lin
---
Hi Sekhar,
Please check if this patch works, thanks.
Axel
drivers
YueHaibing 於 2019年5月16日 週四 下午3:57寫道:
>
> If spi_register_master fails in spi_bitbang_start
> because device_add failure, We should return the
> error code other than 0, otherwise calling
> spi_bitbang_stop may trigger NULL pointer dereference
> like this:
Reviewed-by: Axel Lin
The logic is equivalent, but it looks more straightforward this way:
If rdev->desc->ops->enable_time is set, call it.
Otherwise fallback to return rdev->desc->enable_time.
Signed-off-by: Axel Lin
---
drivers/regulator/core.c | 6 +++---
1 file changed, 3 insertions(+), 3 del
Convert Dialog Semiconductor DA9xxx regulator drivers to SPDX identifier.
Signed-off-by: Axel Lin
---
drivers/regulator/da903x.c | 16 ++--
drivers/regulator/da9052-regulator.c | 20 +++-
drivers/regulator/da9055-regulator.c | 20
Convert Powerventure Semiconductor PV88060/PV88080/PV88090 regulator
drivers to SPDX identifier.
Signed-off-by: Axel Lin
---
drivers/regulator/pv88060-regulator.c | 18 --
drivers/regulator/pv88060-regulator.h | 11 +--
drivers/regulator/pv88080-regulator.c | 18
Slightly better readability by setting fixed_uV instead of min_uV.
Signed-off-by: Axel Lin
---
drivers/regulator/ab3100.c | 7 +++
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/regulator/ab3100.c b/drivers/regulator/ab3100.c
index edde907a7062..438509f55f05 100644
These regulator_ops variables and ab3100_regulator_desc array never need
to be modified, make them const so compiler can put them to .rodata.
Signed-off-by: Axel Lin
---
drivers/regulator/ab3100.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/drivers
Convert HiSilicon hi6xxx PMIC drivers to SPDX identifier.
Signed-off-by: Axel Lin
---
drivers/regulator/hi6421-regulator.c | 24 +-
drivers/regulator/hi6421v530-regulator.c | 26 ++--
drivers/regulator/hi655x-regulator.c | 22
For fixed regulator, setting .n_voltages = 1 and .fixed_uV is enough,
no need to set .min_uV and .list_volage.
Signed-off-by: Axel Lin
---
drivers/regulator/stm32-pwr.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/regulator/stm32-pwr.c b/drivers/regulator/stm32-pwr.c
index
Just use rdev->desc instead.
Signed-off-by: Axel Lin
---
drivers/regulator/stm32-pwr.c | 8 +++-
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/drivers/regulator/stm32-pwr.c b/drivers/regulator/stm32-pwr.c
index 7b39a41530d4..8bd15e4d2cea 100644
--- a/drivers/regulator/st
Signed-off-by: Axel Lin
---
drivers/regulator/vexpress-regulator.c | 15 +++
1 file changed, 3 insertions(+), 12 deletions(-)
diff --git a/drivers/regulator/vexpress-regulator.c
b/drivers/regulator/vexpress-regulator.c
index a15a1319436a..1235f46e633e 100644
--- a/drivers/regulator
The *regdev and *regmap can be replaced by local variables in probe().
Only desc of struct vexpress_regulator is really need, so just use
struct regulator_desc directly and remove struct vexpress_regulator.
Signed-off-by: Axel Lin
---
drivers/regulator/vexpress-regulator.c | 53
Hi Mark,
I found the commits between 2019-04-10 ~ 2019-04-17 are disappear
since linux-next 20190424:
linux-next 20190418:
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/log/drivers/regulator?h=next-20190418
linux-next 20190424:
Current code always set pmic->rinfo[id] = _regs_info[id];
It should set to either max77620_regs_info or max20024_regs_info
depends on the chip_id.
Signed-off-by: Axel Lin
---
This was sent on https://lkml.org/lkml/2019/2/23/482
drivers/regulator/max77620-regulator.c | 2 +-
1 file changed
Convert MediaTek mt63xx PMIC drivers to SPDX identifier.
Signed-off-by: Axel Lin
---
drivers/regulator/mt6311-regulator.c | 17 -
drivers/regulator/mt6311-regulator.h | 10 +-
drivers/regulator/mt6323-regulator.c | 12
drivers/regulator/mt6380-regulator.c
sky81452_reg_ops is never changed, make it const.
Signed-off-by: Axel Lin
---
drivers/regulator/sky81452-regulator.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/regulator/sky81452-regulator.c
b/drivers/regulator/sky81452-regulator.c
index 647860611916
Signed-off-by: Axel Lin
---
drivers/regulator/sky81452-regulator.c | 24 ++--
1 file changed, 6 insertions(+), 18 deletions(-)
diff --git a/drivers/regulator/sky81452-regulator.c
b/drivers/regulator/sky81452-regulator.c
index eb2b60968a1a..177dede82a61 100644
--- a/drivers
All the fields in struct sy8106a are only used in sy8106a_i2c_probe(), so
use local variables instead.
Signed-off-by: Axel Lin
---
drivers/regulator/sy8106a-regulator.c | 40 +--
1 file changed, 13 insertions(+), 27 deletions(-)
diff --git a/drivers/regulator/sy8106a
The *regmap and *rdev can be replaced by local variables.
The slew_rate is no longer used since commit dd7e71fbeefe
("regulator: fan53555: use set_ramp_delay to set the ramp up slew rate").
Signed-off-by: Axel Lin
---
drivers/regulator/fan53555.c | 36 +
Signed-off-by: Axel Lin
---
drivers/regulator/fan53555.c | 24 ++--
1 file changed, 10 insertions(+), 14 deletions(-)
diff --git a/drivers/regulator/fan53555.c b/drivers/regulator/fan53555.c
index e2caf4173ab5..dbe477da4e55 100644
--- a/drivers/regulator/fan53555.c
+++ b
Use regulator core's simplified DT parsing code to simplify the driver
implementation.
Signed-off-by: Axel Lin
---
drivers/regulator/ltc3589.c | 194 +++-
1 file changed, 58 insertions(+), 136 deletions(-)
diff --git a/drivers/regulator/ltc3589.c b/drivers
Signed-off-by: Axel Lin
---
drivers/regulator/ltc3589.c | 24 ++--
1 file changed, 6 insertions(+), 18 deletions(-)
diff --git a/drivers/regulator/ltc3589.c b/drivers/regulator/ltc3589.c
index 077e73715514..9a037fdc5fc5 100644
--- a/drivers/regulator/ltc3589.c
+++ b/drivers
After converting to use simplified DT parsing, the struct ltc3589_regulator
only has a desc member. So let's remove struct ltc3589_regulator and use
struct regulator_desc instead.
Signed-off-by: Axel Lin
---
drivers/regulator/ltc3589.c | 69 +
1 file changed
Signed-off-by: Axel Lin
---
drivers/regulator/wm8350-regulator.c | 21 -
1 file changed, 8 insertions(+), 13 deletions(-)
diff --git a/drivers/regulator/wm8350-regulator.c
b/drivers/regulator/wm8350-regulator.c
index 0eb3f3a33caa..56d6168a888d 100644
--- a/drivers/regulator
Signed-off-by: Axel Lin
---
drivers/regulator/wm8400-regulator.c | 20 +++-
1 file changed, 7 insertions(+), 13 deletions(-)
diff --git a/drivers/regulator/wm8400-regulator.c
b/drivers/regulator/wm8400-regulator.c
index 5ce86b92851b..6f331b51e479 100644
--- a/drivers/regulator
Signed-off-by: Axel Lin
---
drivers/regulator/arizona-ldo1.c| 19 +++
drivers/regulator/arizona-micsupp.c | 19 +++
2 files changed, 14 insertions(+), 24 deletions(-)
diff --git a/drivers/regulator/arizona-ldo1.c b/drivers/regulator/arizona-ldo1.c
index
Signed-off-by: Axel Lin
---
drivers/regulator/wm8994-regulator.c | 19 +++
1 file changed, 7 insertions(+), 12 deletions(-)
diff --git a/drivers/regulator/wm8994-regulator.c
b/drivers/regulator/wm8994-regulator.c
index 38928cdcb6e6..cadea0344486 100644
--- a/drivers/regulator
Signed-off-by: Axel Lin
---
drivers/regulator/wm831x-dcdc.c | 19 +++
drivers/regulator/wm831x-isink.c | 19 +++
drivers/regulator/wm831x-ldo.c | 19 +++
3 files changed, 21 insertions(+), 36 deletions(-)
diff --git a/drivers/regulator/wm831x
of_iomap returns NULL on error.
Signed-off-by: Axel Lin
---
drivers/regulator/stm32-pwr.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/regulator/stm32-pwr.c b/drivers/regulator/stm32-pwr.c
index 222d593d76a2..dd5c2b383e5b 100644
--- a/drivers/regulator/stm32
These symbols are only used by this driver, make them static.
Signed-off-by: Axel Lin
---
drivers/regulator/stm32-pwr.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/regulator/stm32-pwr.c b/drivers/regulator/stm32-pwr.c
index e434b26d4c8b..222d593d76a2 100644
Signed-off-by: Axel Lin
---
drivers/regulator/tps80031-regulator.c | 34 --
1 file changed, 10 insertions(+), 24 deletions(-)
diff --git a/drivers/regulator/tps80031-regulator.c
b/drivers/regulator/tps80031-regulator.c
index 8e65a13e2ef5..85a6a8ca8c1b 100644
These regulator_ops variables and tps80031_dcdc_voltages array never need
to be modified, make them const so compiler can put them to .rodata.
Signed-off-by: Axel Lin
---
drivers/regulator/tps80031-regulator.c | 12 ++--
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git
The ri-rdev is assigend but not used, so remove it.
Signed-off-by: Axel Lin
---
drivers/regulator/tps80031-regulator.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/regulator/tps80031-regulator.c
b/drivers/regulator/tps80031-regulator.c
index 1001147404c3..d97cd55b6850 100644
The struct voltage_map_desc is used for storing min/max/step fileds, and
then setup the min_uV, uV_step and n_voltages fields for regulator_desc.
Introduce MAX8998_LINEAR_REG/MAX8998_OTHERS_REG macro to setup these filds
directly in regulator_desc to simplify the code.
Signed-off-by: Axel Lin
These regulator_ops variables never need to be modified, make them const so
compiler can put them to .rodata.
Signed-off-by: Axel Lin
---
drivers/regulator/max8998.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/regulator/max8998.c b/drivers/regulator/max8998
Current code is using devm_regulator_register() so we don't need to store
*rdev for clean up, use a local variable instead.
Signed-off-by: Axel Lin
---
drivers/regulator/tps6524x-regulator.c | 9 -
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/drivers/regulator/tps6524x
The regulator_ops is never changed, make it const.
Signed-off-by: Axel Lin
---
drivers/regulator/tps6524x-regulator.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/regulator/tps6524x-regulator.c
b/drivers/regulator/tps6524x-regulator.c
index 67cac2682f50
Use regulator_get_current_limit_regmap helper to save some code.
Signed-off-by: Axel Lin
---
drivers/regulator/tps65218-regulator.c | 48 ++
1 file changed, 19 insertions(+), 29 deletions(-)
diff --git a/drivers/regulator/tps65218-regulator.c
b/drivers/regulator
These regulator_ops variables never need to be modified, make them const so
compiler can put them to .rodata.
Signed-off-by: Axel Lin
---
drivers/regulator/ab8500.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/regulator/ab8500.c b/drivers/regulator
Current code is using devm_regulator_register() so we don't need to save
*regulator for clean up, use a local variable instead.
Signed-off-by: Axel Lin
---
drivers/regulator/ab8500.c | 10 --
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/drivers/regulator/ab8500.c b
Use regulator core's simplified DT parsing code to simplify the driver
implementation.
Signed-off-by: Axel Lin
---
drivers/regulator/ab8500-ext.c | 28 +---
1 file changed, 5 insertions(+), 23 deletions(-)
diff --git a/drivers/regulator/ab8500-ext.c b/drivers/regulator
Current code is using devm_regulator_register() so we don't need to save
*rdev for clean up, use a local variable instead.
Signed-off-by: Axel Lin
---
drivers/regulator/ab8500-ext.c | 19 ---
1 file changed, 8 insertions(+), 11 deletions(-)
diff --git a/drivers/regulator/ab8500
ab8500_ext_regulator_ops never need to be modified, make it const so
compiler can put it to .rodata.
Signed-off-by: Axel Lin
---
drivers/regulator/ab8500-ext.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/regulator/ab8500-ext.c b/drivers/regulator/ab8500-ext.c
Hi Lee,
In ab8500 regulator driver code, I found the AB8505_LDO_USB entry does
not has corresponding entry in ab8505_regulator_match.
ab8505 support is added by below commit:
547f384f33dbd6171607f925ab246e25e315961e regulator: ab8500: add
support for ab8505
For ab8505, I'm wondering if it make
Use regulator core's simplified DT parsing code to simplify the driver
implementation.
Signed-off-by: Axel Lin
---
drivers/regulator/db8500-prcmu.c | 139 ++-
1 file changed, 42 insertions(+), 97 deletions(-)
diff --git a/drivers/regulator/db8500-prcmu.c b/drivers
The *dev is assigned but not used, remove it.
Current driver is using devm_regulator_register(), so no neeed to save
*rdev for clean up. Use a local variable instead.
Signed-off-by: Axel Lin
---
drivers/regulator/db8500-prcmu.c | 10 +-
drivers/regulator/dbx500-prcmu.h | 4
2
These regulator_ops variables never need to be modified, make them const so
compiler can put them to .rodata.
Signed-off-by: Axel Lin
---
drivers/regulator/db8500-prcmu.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/regulator/db8500-prcmu.c b/drivers/regulator
It seems a little bit odd current code pass struct regulator_config rather
than a pointer to setup_regulators. The setup_regulators is so simple and
only has one caller, so remove it.
Signed-off-by: Axel Lin
---
drivers/regulator/mcp16502.c | 37 +++-
1 file
At the context with rdev, we can use rdev->regmap instead of mcp->rmap.
The *rdev[NUM_REGULATORS] is not required because current code uses
devm_regulator_register() so we don't need to store *rdev for clean up
paths.
Signed-off-by: Axel Lin
---
drivers/regulator/mcp16502.
vexpress_regulator_ops_ro and vexpress_regulator_ops are never changed,
make them const.
Signed-off-by: Axel Lin
---
drivers/regulator/vexpress-regulator.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/regulator/vexpress-regulator.c
b/drivers/regulator
1 - 100 of 2364 matches
Mail list logo