Address some issues at hi6421v600 regulator driver
PATCH 1/2 regulator: hi6421v600: use lowercase for ldo
In reply to Mauro Carvalho ChehabAs lowercase is generally preferred for node names, while it is not too late, change the LDO DT properties to lower case.
--- drivers/regulator/hi6421v600-regulator.c | 36 ++++++++++++------------ 1 file changed, 18 insertions(+), 18 deletions(-)
drivers/regulator/hi6421v600-regulator.c +18 -18
@@ -73,14 +73,14 @@ static const unsigned int ldo34_voltages[] = {*/ #define HI6421V600_LDO (_id, vtable, ereg, emask, vreg, \ odelay, etime, ecomask, ecoamp) \ - [HI6421V600_##_id] = { \ + [hi6421v600_##_id] = { \ .desc = { \ .name = #_id, \ .of_match = of_match_ptr(#_id), \ .regulators_node = of_match_ptr("regulators"), \ .ops = &hi6421_spmi_ldo_rops, \ .type = REGULATOR_VOLTAGE, \ - .id = HI6421V600_##_id, \ + .id = hi6421v600_##_id, \ .owner = THIS_MODULE, \ .volt_table = vtable, \ .n_voltages = ARRAY_SIZE(vtable), \
@@ -185,46 +185,46 @@ static const struct regulator_ops hi6421_spmi_ldo_rops = {/* HI6421v600 regulators with known registers */ enum hi6421_spmi_regulator_id { -HI6421V600_LDO3 , -HI6421V600_LDO4 , -HI6421V600_LDO9 , -HI6421V600_LDO15 , -HI6421V600_LDO16 , -HI6421V600_LDO17 , -HI6421V600_LDO33 , -HI6421V600_LDO34 , + hi6421v600_ldo3, + hi6421v600_ldo4, + hi6421v600_ldo9, + hi6421v600_ldo15, + hi6421v600_ldo16, + hi6421v600_ldo17, + hi6421v600_ldo33, + hi6421v600_ldo34, };static struct hi6421_spmi_reg_info regulator_info[] = { -HI6421V600_LDO (LDO3 , ldo3_voltages, +HI6421V600_LDO (ldo3, ldo3_voltages,0x16 ,0x01 ,0x51 ,20000 ,120 ,0 ,0 ), -HI6421V600_LDO (LDO4 , ldo4_voltages, +HI6421V600_LDO (ldo4, ldo4_voltages,0x17 ,0x01 ,0x52 ,20000 ,120 ,0x10 ,10000 ), -HI6421V600_LDO (LDO9 , ldo9_voltages, +HI6421V600_LDO (ldo9, ldo9_voltages,0x1c ,0x01 ,0x57 ,20000 ,360 ,0x10 ,10000 ), -HI6421V600_LDO (LDO15 , ldo15_voltages, +HI6421V600_LDO (ldo15, ldo15_voltages,0x21 ,0x01 ,0x5c ,20000 ,360 ,0x10 ,10000 ), -HI6421V600_LDO (LDO16 , ldo15_voltages, +HI6421V600_LDO (ldo16, ldo15_voltages,0x22 ,0x01 ,0x5d ,20000 ,360 ,0x10 ,10000 ), -HI6421V600_LDO (LDO17 , ldo17_voltages, +HI6421V600_LDO (ldo17, ldo17_voltages,0x23 ,0x01 ,0x5e ,20000 ,120 ,0x10 ,10000 ), -HI6421V600_LDO (LDO33 , ldo17_voltages, +HI6421V600_LDO (ldo33, ldo17_voltages,0x32 ,0x01 ,0x6d ,20000 ,120 ,0 ,0 ), -HI6421V600_LDO (LDO34 , ldo34_voltages, +HI6421V600_LDO (ldo34, ldo34_voltages,0x33 ,0x01 ,0x6e ,20000 ,120 ,0 ,0 ),
Signature · 1 line
2.31.1
PATCH 2/2 regulator: hi6421v600: rename voltage range arrays
In reply to Mauro Carvalho ChehabThe arrays containing the regulator's voltage ranges are currently named after the first ldo which uses such range.
However, it sounds a lot clearer if those are named with the voltage range instead.
No functional changes.
--- drivers/regulator/hi6421v600-regulator.c | 28 ++++++++++++------------ 1 file changed, 14 insertions(+), 14 deletions(-)
drivers/regulator/hi6421v600-regulator.c +14 -14
@@ -27,34 +27,34 @@ struct hi6421_spmi_reg_info {u32 eco_uA; }; -static const unsigned int ldo3_voltages[] = { +static const unsigned int range_1v5_to_2v0[] = {1500000 ,1550000 ,1600000 ,1650000 ,1700000 ,1725000 ,1750000 ,1775000 ,1800000 ,1825000 ,1850000 ,1875000 ,1900000 ,1925000 ,1950000 ,2000000 }; -static const unsigned int ldo4_voltages[] = { +static const unsigned int range_1v725_to_1v9[] = {1725000 ,1750000 ,1775000 ,1800000 ,1825000 ,1850000 ,1875000 ,1900000 }; -static const unsigned int ldo9_voltages[] = { +static const unsigned int range_1v75_to_3v3[] = {1750000 ,1800000 ,1825000 ,2800000 ,2850000 ,2950000 ,3000000 ,3300000 }; -static const unsigned int ldo15_voltages[] = { +static const unsigned int range_1v8_to_3v0[] = {1800000 ,1850000 ,2400000 ,2600000 ,2700000 ,2850000 ,2950000 ,3000000 }; -static const unsigned int ldo17_voltages[] = { +static const unsigned int range_2v5_to_3v3[] = {2500000 ,2600000 ,2700000 ,2800000 ,3000000 ,3100000 ,3200000 ,3300000 }; -static const unsigned int ldo34_voltages[] = { +static const unsigned int range_2v6_to_3v3[] = {2600000 ,2700000 ,2800000 ,2900000 ,3000000 ,3100000 ,3200000 ,3300000 };
@@ -196,35 +196,35 @@ enum hi6421_spmi_regulator_id { };static struct hi6421_spmi_reg_info regulator_info[] = { -HI6421V600_LDO (ldo3, ldo3_voltages, +HI6421V600_LDO (ldo3, range_1v5_to_2v0,0x16 ,0x01 ,0x51 ,20000 ,120 ,0 ,0 ), -HI6421V600_LDO (ldo4, ldo4_voltages, +HI6421V600_LDO (ldo4, range_1v725_to_1v9,0x17 ,0x01 ,0x52 ,20000 ,120 ,0x10 ,10000 ), -HI6421V600_LDO (ldo9, ldo9_voltages, +HI6421V600_LDO (ldo9, range_1v75_to_3v3,0x1c ,0x01 ,0x57 ,20000 ,360 ,0x10 ,10000 ), -HI6421V600_LDO (ldo15, ldo15_voltages, +HI6421V600_LDO (ldo15, range_1v8_to_3v0,0x21 ,0x01 ,0x5c ,20000 ,360 ,0x10 ,10000 ), -HI6421V600_LDO (ldo16, ldo15_voltages, +HI6421V600_LDO (ldo16, range_1v8_to_3v0,0x22 ,0x01 ,0x5d ,20000 ,360 ,0x10 ,10000 ), -HI6421V600_LDO (ldo17, ldo17_voltages, +HI6421V600_LDO (ldo17, range_2v5_to_3v3,0x23 ,0x01 ,0x5e ,20000 ,120 ,0x10 ,10000 ), -HI6421V600_LDO (ldo33, ldo17_voltages, +HI6421V600_LDO (ldo33, range_2v5_to_3v3,0x32 ,0x01 ,0x6d ,20000 ,120 ,0 ,0 ), -HI6421V600_LDO (ldo34, ldo34_voltages, +HI6421V600_LDO (ldo34, range_2v6_to_3v3,0x33 ,0x01 ,0x6e ,20000 ,120 ,0 ,0 ),
Signature · 1 line
2.31.1
cover Address some issues at hi6421v600 regulator driver
Hi Mark,
Patch 1 on this series address a review made by Rob Herring for the dt-bindings. It basically use "ldo" instead of "LDO", in order to match the patch I wrote to dt-bindings:
https://lore.kernel.org/lkml/b7a775808d9c3a87fbe1c5a6dd71f8f18be7e649.1627116034.git.mchehab+huawei@kernel.org/T/#u
Patch 2 is just a cleanup patch, changing the namespace for the voltage range arrays. IMO, the new names fit better than the previous ones.
Mauro Carvalho Chehab (2):
regulator: hi6421v600: use lowercase for ldo
regulator: hi6421v600: rename voltage range arrays
drivers/regulator/hi6421v600-regulator.c | 48 ++++++++++++------------ 1 file changed, 24 insertions(+), 24 deletions(-)
Signature · 1 line
2.31.1
Mark Brown
maintainerQuoted 9 lines · Mauro Carvalho Chehab
Patch 1 on this series address a review made by Rob Herring for the dt-bindings. It basically use "ldo" instead of "LDO", in order to match the patch I wrote to dt-bindings:
https://lore.kernel.org/lkml/b7a775808d9c3a87fbe1c5a6dd71f8f18be7e649.1627116034.git.mchehab+huawei@kernel.org/T/#uPatch 2 is just a cleanup patch, changing the namespace for the voltage range arrays. IMO, the new names fit better than the previous ones.
[...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next
Thanks!
[1/2] regulator: hi6421v600: use lowercase for ldo
commit: ccb2a74eec211c368ddbe3eaec4a20292e431095
[2/2] regulator: hi6421v600: rename voltage range arrays
commit: 5e36129f2b4e9629513670fc1df97545ab4bd5a1All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark