LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH] mfd: qcom-spmi-pmic: Add support for pm8005,pm8998,pmi8998
@ 2018-04-19 23:00 Stephen Boyd
2018-04-24 5:26 ` Doug Anderson
2018-04-27 3:14 ` Rob Herring
0 siblings, 2 replies; 4+ messages in thread
From: Stephen Boyd @ 2018-04-19 23:00 UTC (permalink / raw)
To: Lee Jones; +Cc: Rob Herring, linux-arm-msm, linux-kernel, devicetree
Add the compatibles and PMIC ids for the pm8005, pm8998, and pmi8998
PMICS found on MSM8998 and SDM845 based platforms.
Cc: <devicetree@vger.kernel.org>
Signed-off-by: Stephen Boyd <swboyd@chromium.org>
---
Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.txt | 3 +++
drivers/mfd/qcom-spmi-pmic.c | 6 ++++++
2 files changed, 9 insertions(+)
diff --git a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.txt b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.txt
index 6ac06c1b9aec..f708431e2350 100644
--- a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.txt
+++ b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.txt
@@ -29,6 +29,9 @@ Required properties:
"qcom,pm8916",
"qcom,pm8004",
"qcom,pm8909",
+ "qcom,pmi8998",
+ "qcom,pm8005",
+ "qcom,pm8998",
or generalized "qcom,spmi-pmic".
- reg: Specifies the SPMI USID slave address for this device.
For more information see:
diff --git a/drivers/mfd/qcom-spmi-pmic.c b/drivers/mfd/qcom-spmi-pmic.c
index 2022bdfa7ab4..0b26387c22e7 100644
--- a/drivers/mfd/qcom-spmi-pmic.c
+++ b/drivers/mfd/qcom-spmi-pmic.c
@@ -39,6 +39,9 @@
#define PM8916_SUBTYPE 0x0b
#define PM8004_SUBTYPE 0x0c
#define PM8909_SUBTYPE 0x0d
+#define PM8998_SUBTYPE 0x14
+#define PMI8998_SUBTYPE 0x15
+#define PM8005_SUBTYPE 0x18
static const struct of_device_id pmic_spmi_id_table[] = {
{ .compatible = "qcom,spmi-pmic", .data = (void *)COMMON_SUBTYPE },
@@ -54,7 +57,10 @@ static const struct of_device_id pmic_spmi_id_table[] = {
{ .compatible = "qcom,pmi8994", .data = (void *)PMI8994_SUBTYPE },
{ .compatible = "qcom,pm8916", .data = (void *)PM8916_SUBTYPE },
{ .compatible = "qcom,pm8004", .data = (void *)PM8004_SUBTYPE },
+ { .compatible = "qcom,pmi8998", .data = (void *)PMI8998_SUBTYPE },
+ { .compatible = "qcom,pm8005", .data = (void *)PM8005_SUBTYPE },
{ .compatible = "qcom,pm8909", .data = (void *)PM8909_SUBTYPE },
+ { .compatible = "qcom,pm8998", .data = (void *)PM8998_SUBTYPE },
{ }
};
--
Sent by a computer through tubes
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] mfd: qcom-spmi-pmic: Add support for pm8005,pm8998,pmi8998
2018-04-19 23:00 [PATCH] mfd: qcom-spmi-pmic: Add support for pm8005,pm8998,pmi8998 Stephen Boyd
@ 2018-04-24 5:26 ` Doug Anderson
2018-05-02 16:29 ` Stephen Boyd
2018-04-27 3:14 ` Rob Herring
1 sibling, 1 reply; 4+ messages in thread
From: Doug Anderson @ 2018-04-24 5:26 UTC (permalink / raw)
To: Stephen Boyd; +Cc: Lee Jones, Rob Herring, linux-arm-msm, LKML, devicetree
Hi,
On Thu, Apr 19, 2018 at 4:00 PM, Stephen Boyd <swboyd@chromium.org> wrote:
> diff --git a/drivers/mfd/qcom-spmi-pmic.c b/drivers/mfd/qcom-spmi-pmic.c
> index 2022bdfa7ab4..0b26387c22e7 100644
> --- a/drivers/mfd/qcom-spmi-pmic.c
> +++ b/drivers/mfd/qcom-spmi-pmic.c
> @@ -39,6 +39,9 @@
> #define PM8916_SUBTYPE 0x0b
> #define PM8004_SUBTYPE 0x0c
> #define PM8909_SUBTYPE 0x0d
> +#define PM8998_SUBTYPE 0x14
> +#define PMI8998_SUBTYPE 0x15
> +#define PM8005_SUBTYPE 0x18
I was being overly paranoid and double-checking these numbers. I
confirmed PMI8998 and PM8005 from the docs (yay!). The PM8998 docs
didn't have this, but I confirmed that I was talking to PM8998 by
confirming it was on the right USID and and then printing out the
value at probe time. All look good.
> static const struct of_device_id pmic_spmi_id_table[] = {
> { .compatible = "qcom,spmi-pmic", .data = (void *)COMMON_SUBTYPE },
> @@ -54,7 +57,10 @@ static const struct of_device_id pmic_spmi_id_table[] = {
> { .compatible = "qcom,pmi8994", .data = (void *)PMI8994_SUBTYPE },
> { .compatible = "qcom,pm8916", .data = (void *)PM8916_SUBTYPE },
> { .compatible = "qcom,pm8004", .data = (void *)PM8004_SUBTYPE },
> + { .compatible = "qcom,pmi8998", .data = (void *)PMI8998_SUBTYPE },
> + { .compatible = "qcom,pm8005", .data = (void *)PM8005_SUBTYPE },
> { .compatible = "qcom,pm8909", .data = (void *)PM8909_SUBTYPE },
> + { .compatible = "qcom,pm8998", .data = (void *)PM8998_SUBTYPE },
nit: It appears that the above table was previously sorted by SUBTYPE
ID. Could you perhaps move your 3 new PMICs to the bottom to maintain
this? Other than that, you can add my Reviewed-by if you would like
(not that I have _any_ real expertise on SPMI, so might not be worth
it).
-Doug
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] mfd: qcom-spmi-pmic: Add support for pm8005,pm8998,pmi8998
2018-04-19 23:00 [PATCH] mfd: qcom-spmi-pmic: Add support for pm8005,pm8998,pmi8998 Stephen Boyd
2018-04-24 5:26 ` Doug Anderson
@ 2018-04-27 3:14 ` Rob Herring
1 sibling, 0 replies; 4+ messages in thread
From: Rob Herring @ 2018-04-27 3:14 UTC (permalink / raw)
To: Stephen Boyd; +Cc: Lee Jones, linux-arm-msm, linux-kernel, devicetree
On Thu, Apr 19, 2018 at 04:00:32PM -0700, Stephen Boyd wrote:
> Add the compatibles and PMIC ids for the pm8005, pm8998, and pmi8998
> PMICS found on MSM8998 and SDM845 based platforms.
>
> Cc: <devicetree@vger.kernel.org>
> Signed-off-by: Stephen Boyd <swboyd@chromium.org>
> ---
> Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.txt | 3 +++
> drivers/mfd/qcom-spmi-pmic.c | 6 ++++++
> 2 files changed, 9 insertions(+)
Reviewed-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] mfd: qcom-spmi-pmic: Add support for pm8005,pm8998,pmi8998
2018-04-24 5:26 ` Doug Anderson
@ 2018-05-02 16:29 ` Stephen Boyd
0 siblings, 0 replies; 4+ messages in thread
From: Stephen Boyd @ 2018-05-02 16:29 UTC (permalink / raw)
To: Doug Anderson; +Cc: Lee Jones, Rob Herring, linux-arm-msm, LKML, devicetree
Quoting Doug Anderson (2018-04-23 22:26:29)
>
> > static const struct of_device_id pmic_spmi_id_table[] = {
> > { .compatible = "qcom,spmi-pmic", .data = (void *)COMMON_SUBTYPE },
> > @@ -54,7 +57,10 @@ static const struct of_device_id pmic_spmi_id_table[] = {
> > { .compatible = "qcom,pmi8994", .data = (void *)PMI8994_SUBTYPE },
> > { .compatible = "qcom,pm8916", .data = (void *)PM8916_SUBTYPE },
> > { .compatible = "qcom,pm8004", .data = (void *)PM8004_SUBTYPE },
> > + { .compatible = "qcom,pmi8998", .data = (void *)PMI8998_SUBTYPE },
> > + { .compatible = "qcom,pm8005", .data = (void *)PM8005_SUBTYPE },
> > { .compatible = "qcom,pm8909", .data = (void *)PM8909_SUBTYPE },
> > + { .compatible = "qcom,pm8998", .data = (void *)PM8998_SUBTYPE },
>
> nit: It appears that the above table was previously sorted by SUBTYPE
> ID. Could you perhaps move your 3 new PMICs to the bottom to maintain
> this? Other than that, you can add my Reviewed-by if you would like
> (not that I have _any_ real expertise on SPMI, so might not be worth
> it).
Ok. I'll change the order and resend the patch with the reviewed-by
tags.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-05-02 16:29 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-19 23:00 [PATCH] mfd: qcom-spmi-pmic: Add support for pm8005,pm8998,pmi8998 Stephen Boyd
2018-04-24 5:26 ` Doug Anderson
2018-05-02 16:29 ` Stephen Boyd
2018-04-27 3:14 ` Rob Herring
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).