mbox series

[v3,0/5] regulator: qcom,rpmh-regulator: Add support for pmic available on SA8155p-adp board

Message ID 20210617051712.345372-1-bhupesh.sharma@linaro.org
Headers show
Series regulator: qcom,rpmh-regulator: Add support for pmic available on SA8155p-adp board | expand

Message

Bhupesh Sharma June 17, 2021, 5:17 a.m. UTC
Changes since v2:
-----------------
- v2 series can be found here: https://lore.kernel.org/linux-arm-msm/20210615074543.26700-1-bhupesh.sharma@linaro.org/T/#m8303d27d561b30133992da88198abb78ea833e21 
- Addressed review comments from Bjorn and Mark.
- As per suggestion from Bjorn, seperated the patches in different
  patchsets (specific to each subsystem) to ease review and patch application.

Changes since v1:
-----------------
- v1 series can be found here: https://lore.kernel.org/linux-arm-msm/20210607113840.15435-1-bhupesh.sharma@linaro.org/T/#mc524fe82798d4c4fb75dd0333318955e0406ad18
- Addressed review comments from Bjorn and Vinod received on the v1
  series.

This series adds the regulator support code for SA8155p-adp board
which is based on Qualcomm snapdragon sa8155p SoC which in turn is
simiar to the sm8150 SoC. 

This board supports a new PMIC PMM8155AU.

While at it, also make some cosmetic changes to the regulator driver
and dt-bindings to make sure the compatibles are alphabetical and also
fix issues with extra comma(s) at the end of terminator line(s). 

Cc: Mark Brown <broonie@kernel.org>
Cc: Bjorn Andersson <bjorn.andersson@linaro.org>

Bhupesh Sharma (5):
  dt-bindings: regulator: qcom,rpmh-regulator: Arrange compatibles
    alphabetically
  dt-bindings: regulator: qcom,rpmh-regulator: Add compatible for
    SA8155p-adp board pmic
  regulator: qcom-rpmh: Cleanup terminator line commas
  regulator: qcom-rpmh: Add terminator at the end of pm7325x_vreg_data[]
    array
  regulator: qcom-rpmh: Add new regulator found on SA8155p adp board

 .../regulator/qcom,rpmh-regulator.yaml        | 17 ++---
 drivers/regulator/qcom-rpmh-regulator.c       | 62 +++++++++++++++----
 2 files changed, 59 insertions(+), 20 deletions(-)

Comments

Bjorn Andersson June 18, 2021, 6:04 p.m. UTC | #1
On Thu 17 Jun 00:17 CDT 2021, Bhupesh Sharma wrote:

> Arrange the compatibles inside qcom-rpmh regulator device tree
> bindings alphabetically.
> 

Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>

Regards,
Bjorn

> Cc: Mark Brown <broonie@kernel.org>
> Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
> Signed-off-by: Bhupesh Sharma <bhupesh.sharma@linaro.org>
> ---
>  .../bindings/regulator/qcom,rpmh-regulator.yaml  | 16 ++++++++--------
>  1 file changed, 8 insertions(+), 8 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/regulator/qcom,rpmh-regulator.yaml b/Documentation/devicetree/bindings/regulator/qcom,rpmh-regulator.yaml
> index e561a5b941e4..3546c6a966a3 100644
> --- a/Documentation/devicetree/bindings/regulator/qcom,rpmh-regulator.yaml
> +++ b/Documentation/devicetree/bindings/regulator/qcom,rpmh-regulator.yaml
> @@ -33,6 +33,9 @@ description: |
>  
>      The names used for regulator nodes must match those supported by a given
>      PMIC. Supported regulator node names are
> +      For PM6150, smps1 - smps5, ldo1 - ldo19
> +      For PM6150L, smps1 - smps8, ldo1 - ldo11, bob
> +      For PM7325, smps1 - smps8, ldo1 - ldo19
>        For PM8005, smps1 - smps4
>        For PM8009, smps1 - smps2, ldo1 - ldo7
>        For PM8150, smps1 - smps10, ldo1 - ldo18
> @@ -41,15 +44,15 @@ description: |
>        For PM8350C, smps1 - smps10, ldo1 - ldo13, bob
>        For PM8998, smps1 - smps13, ldo1 - ldo28, lvs1 - lvs2
>        For PMI8998, bob
> -      For PM6150, smps1 - smps5, ldo1 - ldo19
> -      For PM6150L, smps1 - smps8, ldo1 - ldo11, bob
> -      For PMX55, smps1 - smps7, ldo1 - ldo16
> -      For PM7325, smps1 - smps8, ldo1 - ldo19
>        For PMR735A, smps1 - smps3, ldo1 - ldo7
> +      For PMX55, smps1 - smps7, ldo1 - ldo16
>  
>  properties:
>    compatible:
>      enum:
> +      - qcom,pm6150-rpmh-regulators
> +      - qcom,pm6150l-rpmh-regulators
> +      - qcom,pm7325-rpmh-regulators
>        - qcom,pm8005-rpmh-regulators
>        - qcom,pm8009-rpmh-regulators
>        - qcom,pm8009-1-rpmh-regulators
> @@ -59,11 +62,8 @@ properties:
>        - qcom,pm8350c-rpmh-regulators
>        - qcom,pm8998-rpmh-regulators
>        - qcom,pmi8998-rpmh-regulators
> -      - qcom,pm6150-rpmh-regulators
> -      - qcom,pm6150l-rpmh-regulators
> -      - qcom,pmx55-rpmh-regulators
> -      - qcom,pm7325-rpmh-regulators
>        - qcom,pmr735a-rpmh-regulators
> +      - qcom,pmx55-rpmh-regulators
>  
>    qcom,pmic-id:
>      description: |
> -- 
> 2.31.1
>
Bjorn Andersson June 18, 2021, 6:06 p.m. UTC | #2
On Thu 17 Jun 00:17 CDT 2021, Bhupesh Sharma wrote:

> SA8155p-adp board supports a new regulator - pmm8155au.
> 
> The output power management circuits in this regulator include:
> - FTS510 smps,
> - HFS510 smps, and
> - LDO510 linear regulators
> 
> Add support for the same.
> 
> Cc: Mark Brown <broonie@kernel.org>
> Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
> Signed-off-by: Bhupesh Sharma <bhupesh.sharma@linaro.org>

Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>

Regards,
Bjorn

> ---
>  drivers/regulator/qcom-rpmh-regulator.c | 36 +++++++++++++++++++++++++
>  1 file changed, 36 insertions(+)
> 
> diff --git a/drivers/regulator/qcom-rpmh-regulator.c b/drivers/regulator/qcom-rpmh-regulator.c
> index af41a517da99..6cca910a76de 100644
> --- a/drivers/regulator/qcom-rpmh-regulator.c
> +++ b/drivers/regulator/qcom-rpmh-regulator.c
> @@ -883,6 +883,38 @@ static const struct rpmh_vreg_init_data pm8150l_vreg_data[] = {
>  	{}
>  };
>  
> +static const struct rpmh_vreg_init_data pmm8155au_vreg_data[] = {
> +	RPMH_VREG("smps1",  "smp%s1",  &pmic5_ftsmps510, "vdd-s1"),
> +	RPMH_VREG("smps2",  "smp%s2",  &pmic5_ftsmps510, "vdd-s2"),
> +	RPMH_VREG("smps3",  "smp%s3",  &pmic5_ftsmps510, "vdd-s3"),
> +	RPMH_VREG("smps4",  "smp%s4",  &pmic5_hfsmps510, "vdd-s4"),
> +	RPMH_VREG("smps5",  "smp%s5",  &pmic5_hfsmps510, "vdd-s5"),
> +	RPMH_VREG("smps6",  "smp%s6",  &pmic5_ftsmps510, "vdd-s6"),
> +	RPMH_VREG("smps7",  "smp%s7",  &pmic5_ftsmps510, "vdd-s7"),
> +	RPMH_VREG("smps8",  "smp%s8",  &pmic5_ftsmps510, "vdd-s8"),
> +	RPMH_VREG("smps9",  "smp%s9",  &pmic5_ftsmps510, "vdd-s9"),
> +	RPMH_VREG("smps10", "smp%s10", &pmic5_ftsmps510, "vdd-s10"),
> +	RPMH_VREG("ldo1",   "ldo%s1",  &pmic5_nldo,      "vdd-l1-l8-l11"),
> +	RPMH_VREG("ldo2",   "ldo%s2",  &pmic5_pldo,      "vdd-l2-l10"),
> +	RPMH_VREG("ldo3",   "ldo%s3",  &pmic5_nldo,      "vdd-l3-l4-l5-l18"),
> +	RPMH_VREG("ldo4",   "ldo%s4",  &pmic5_nldo,      "vdd-l3-l4-l5-l18"),
> +	RPMH_VREG("ldo5",   "ldo%s5",  &pmic5_nldo,      "vdd-l3-l4-l5-l18"),
> +	RPMH_VREG("ldo6",   "ldo%s6",  &pmic5_nldo,      "vdd-l6-l9"),
> +	RPMH_VREG("ldo7",   "ldo%s7",  &pmic5_pldo_lv,   "vdd-l7-l12-l14-l15"),
> +	RPMH_VREG("ldo8",   "ldo%s8",  &pmic5_nldo,      "vdd-l1-l8-l11"),
> +	RPMH_VREG("ldo9",   "ldo%s9",  &pmic5_nldo,      "vdd-l6-l9"),
> +	RPMH_VREG("ldo10",  "ldo%s10", &pmic5_pldo,      "vdd-l2-l10"),
> +	RPMH_VREG("ldo11",  "ldo%s11", &pmic5_nldo,      "vdd-l1-l8-l11"),
> +	RPMH_VREG("ldo12",  "ldo%s12", &pmic5_pldo_lv,   "vdd-l7-l12-l14-l15"),
> +	RPMH_VREG("ldo13",  "ldo%s13", &pmic5_pldo,      "vdd-l13-l16-l17"),
> +	RPMH_VREG("ldo14",  "ldo%s14", &pmic5_pldo_lv,   "vdd-l7-l12-l14-l15"),
> +	RPMH_VREG("ldo15",  "ldo%s15", &pmic5_pldo_lv,   "vdd-l7-l12-l14-l15"),
> +	RPMH_VREG("ldo16",  "ldo%s16", &pmic5_pldo,      "vdd-l13-l16-l17"),
> +	RPMH_VREG("ldo17",  "ldo%s17", &pmic5_pldo,      "vdd-l13-l16-l17"),
> +	RPMH_VREG("ldo18",  "ldo%s18", &pmic5_nldo,      "vdd-l3-l4-l5-l18"),
> +	{}
> +};
> +
>  static const struct rpmh_vreg_init_data pm8350_vreg_data[] = {
>  	RPMH_VREG("smps1",  "smp%s1",  &pmic5_ftsmps510, "vdd-s1"),
>  	RPMH_VREG("smps2",  "smp%s2",  &pmic5_ftsmps510, "vdd-s2"),
> @@ -1177,6 +1209,10 @@ static const struct of_device_id __maybe_unused rpmh_regulator_match_table[] = {
>  		.compatible = "qcom,pmc8180c-rpmh-regulators",
>  		.data = pm8150l_vreg_data,
>  	},
> +	{
> +		.compatible = "qcom,pmm8155au-rpmh-regulators",
> +		.data = pmm8155au_vreg_data,
> +	},
>  	{
>  		.compatible = "qcom,pmx55-rpmh-regulators",
>  		.data = pmx55_vreg_data,
> -- 
> 2.31.1
>
Mark Brown June 21, 2021, 6:45 p.m. UTC | #3
On Thu, 17 Jun 2021 10:47:07 +0530, Bhupesh Sharma wrote:
> Changes since v2:
> -----------------
> - v2 series can be found here: https://lore.kernel.org/linux-arm-msm/20210615074543.26700-1-bhupesh.sharma@linaro.org/T/#m8303d27d561b30133992da88198abb78ea833e21
> - Addressed review comments from Bjorn and Mark.
> - As per suggestion from Bjorn, seperated the patches in different
>   patchsets (specific to each subsystem) to ease review and patch application.
> 
> [...]

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next

Thanks!

[1/5] dt-bindings: regulator: qcom,rpmh-regulator: Arrange compatibles alphabetically
      commit: 85adaac269c36d8e2e0a5de87a1dc4ec06e984f1
[2/5] dt-bindings: regulator: qcom,rpmh-regulator: Add compatible for SA8155p-adp board pmic
      commit: 66376e152303bb60d6a75328b7bc998de86f8c08
[3/5] regulator: qcom-rpmh: Cleanup terminator line commas
      commit: ba5dabf40e9143ff6c48943b76a532d5ab34d0e8
[4/5] regulator: qcom-rpmh: Add terminator at the end of pm7325x_vreg_data[] array
      commit: f26cdadad729743888eb4ac2c17eac3cf845b493
[5/5] regulator: qcom-rpmh: Add new regulator found on SA8155p adp board
      commit: 9a336ed97d00bb69547272fc7d0439802bece375

All 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
Rob Herring June 24, 2021, 9:23 p.m. UTC | #4
On Thu, 17 Jun 2021 10:47:08 +0530, Bhupesh Sharma wrote:
> Arrange the compatibles inside qcom-rpmh regulator device tree

> bindings alphabetically.

> 

> Cc: Mark Brown <broonie@kernel.org>

> Cc: Bjorn Andersson <bjorn.andersson@linaro.org>

> Signed-off-by: Bhupesh Sharma <bhupesh.sharma@linaro.org>

> ---

>  .../bindings/regulator/qcom,rpmh-regulator.yaml  | 16 ++++++++--------

>  1 file changed, 8 insertions(+), 8 deletions(-)

> 


Acked-by: Rob Herring <robh@kernel.org>