2022-09-15 09:27:48

by Luca Weiss

[permalink] [raw]
Subject: [PATCH v2] mfd: qcom-spmi-pmic: Add more PMIC SUBTYPE IDs

Add more IDs that are found in the downstream msm-4.19 kernel under the
path include/linux/qpnp/qpnp-revid.h.

While we're at it, make sure all hex numbers are uppercase and
consistent in this file.

Signed-off-by: Luca Weiss <[email protected]>
---
Changes in v2:
* Convert existing lowercase hex numbers to uppercase

include/soc/qcom/qcom-spmi-pmic.h | 28 +++++++++++++++++++++-------
1 file changed, 21 insertions(+), 7 deletions(-)

diff --git a/include/soc/qcom/qcom-spmi-pmic.h b/include/soc/qcom/qcom-spmi-pmic.h
index 72398ff44719..f1c9f1676fb4 100644
--- a/include/soc/qcom/qcom-spmi-pmic.h
+++ b/include/soc/qcom/qcom-spmi-pmic.h
@@ -18,26 +18,40 @@
#define PMI8962_SUBTYPE 0x07
#define PMD9635_SUBTYPE 0x08
#define PM8994_SUBTYPE 0x09
-#define PMI8994_SUBTYPE 0x0a
-#define PM8916_SUBTYPE 0x0b
-#define PM8004_SUBTYPE 0x0c
-#define PM8909_SUBTYPE 0x0d
-#define PM8028_SUBTYPE 0x0e
-#define PM8901_SUBTYPE 0x0f
+#define PMI8994_SUBTYPE 0x0A
+#define PM8916_SUBTYPE 0x0B
+#define PM8004_SUBTYPE 0x0C
+#define PM8909_SUBTYPE 0x0D
+#define PM8028_SUBTYPE 0x0E
+#define PM8901_SUBTYPE 0x0F
#define PM8950_SUBTYPE 0x10
#define PMI8950_SUBTYPE 0x11
+#define PMK8001_SUBTYPE 0x12
+#define PMI8996_SUBTYPE 0x13
#define PM8998_SUBTYPE 0x14
#define PMI8998_SUBTYPE 0x15
+#define SMB1381_SUBTYPE 0x17
#define PM8005_SUBTYPE 0x18
#define PM660L_SUBTYPE 0x1A
#define PM660_SUBTYPE 0x1B
+#define SMB1355_SUBTYPE 0x1C
#define PM8150_SUBTYPE 0x1E
-#define PM8150L_SUBTYPE 0x1f
+#define PM8150L_SUBTYPE 0x1F
#define PM8150B_SUBTYPE 0x20
#define PMK8002_SUBTYPE 0x21
+#define SMB1390_SUBTYPE 0x23
#define PM8009_SUBTYPE 0x24
+#define PMI632_SUBTYPE 0x25
#define PM8150C_SUBTYPE 0x26
+#define PM6150_SUBTYPE 0x28
#define SMB2351_SUBTYPE 0x29
+#define PM8008_SUBTYPE 0x2C
+#define PM6125_SUBTYPE 0x2D
+#define PM7250B_SUBTYPE 0x2E
+#define PMK8350_SUBTYPE 0x2F
+#define PMR735B_SUBTYPE 0x34
+#define PM6350_SUBTYPE 0x36
+#define PM2250_SUBTYPE 0x37

#define PMI8998_FAB_ID_SMIC 0x11
#define PMI8998_FAB_ID_GF 0x30
--
2.37.3


2022-09-15 11:38:45

by Dmitry Baryshkov

[permalink] [raw]
Subject: Re: [PATCH v2] mfd: qcom-spmi-pmic: Add more PMIC SUBTYPE IDs

On Thu, 15 Sept 2022 at 11:58, Luca Weiss <[email protected]> wrote:
>
> Add more IDs that are found in the downstream msm-4.19 kernel under the
> path include/linux/qpnp/qpnp-revid.h.
>
> While we're at it, make sure all hex numbers are uppercase and
> consistent in this file.

Please make all hex numbers lowercase. If they are uppercase
somewhere, it's worth fixing.

Additionally, it would be better to split this patch. One fixes the
case, another one adds the new IDs. It would help the review a lot.

>
> Signed-off-by: Luca Weiss <[email protected]>
> ---
> Changes in v2:
> * Convert existing lowercase hex numbers to uppercase
>
> include/soc/qcom/qcom-spmi-pmic.h | 28 +++++++++++++++++++++-------
> 1 file changed, 21 insertions(+), 7 deletions(-)
>
> diff --git a/include/soc/qcom/qcom-spmi-pmic.h b/include/soc/qcom/qcom-spmi-pmic.h
> index 72398ff44719..f1c9f1676fb4 100644
> --- a/include/soc/qcom/qcom-spmi-pmic.h
> +++ b/include/soc/qcom/qcom-spmi-pmic.h
> @@ -18,26 +18,40 @@
> #define PMI8962_SUBTYPE 0x07
> #define PMD9635_SUBTYPE 0x08
> #define PM8994_SUBTYPE 0x09
> -#define PMI8994_SUBTYPE 0x0a
> -#define PM8916_SUBTYPE 0x0b
> -#define PM8004_SUBTYPE 0x0c
> -#define PM8909_SUBTYPE 0x0d
> -#define PM8028_SUBTYPE 0x0e
> -#define PM8901_SUBTYPE 0x0f
> +#define PMI8994_SUBTYPE 0x0A
> +#define PM8916_SUBTYPE 0x0B
> +#define PM8004_SUBTYPE 0x0C
> +#define PM8909_SUBTYPE 0x0D
> +#define PM8028_SUBTYPE 0x0E
> +#define PM8901_SUBTYPE 0x0F
> #define PM8950_SUBTYPE 0x10
> #define PMI8950_SUBTYPE 0x11
> +#define PMK8001_SUBTYPE 0x12
> +#define PMI8996_SUBTYPE 0x13
> #define PM8998_SUBTYPE 0x14
> #define PMI8998_SUBTYPE 0x15
> +#define SMB1381_SUBTYPE 0x17
> #define PM8005_SUBTYPE 0x18
> #define PM660L_SUBTYPE 0x1A
> #define PM660_SUBTYPE 0x1B
> +#define SMB1355_SUBTYPE 0x1C
> #define PM8150_SUBTYPE 0x1E
> -#define PM8150L_SUBTYPE 0x1f
> +#define PM8150L_SUBTYPE 0x1F
> #define PM8150B_SUBTYPE 0x20
> #define PMK8002_SUBTYPE 0x21
> +#define SMB1390_SUBTYPE 0x23
> #define PM8009_SUBTYPE 0x24
> +#define PMI632_SUBTYPE 0x25
> #define PM8150C_SUBTYPE 0x26
> +#define PM6150_SUBTYPE 0x28
> #define SMB2351_SUBTYPE 0x29
> +#define PM8008_SUBTYPE 0x2C
> +#define PM6125_SUBTYPE 0x2D
> +#define PM7250B_SUBTYPE 0x2E
> +#define PMK8350_SUBTYPE 0x2F
> +#define PMR735B_SUBTYPE 0x34
> +#define PM6350_SUBTYPE 0x36
> +#define PM2250_SUBTYPE 0x37
>
> #define PMI8998_FAB_ID_SMIC 0x11
> #define PMI8998_FAB_ID_GF 0x30
> --
> 2.37.3
>


--
With best wishes
Dmitry