* [PATCH v2 0/2] Support for pmic-glink in SM8475
@ 2026-07-31 5:00 ` Esteban Urrutia
0 siblings, 0 replies; 9+ messages in thread
From: Esteban Urrutia via B4 Relay @ 2026-07-31 5:00 UTC (permalink / raw)
To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Heikki Krogerus, Greg Kroah-Hartman
Cc: linux-arm-msm, devicetree, linux-kernel, linux-usb, phone-devel,
Esteban Urrutia
This series adds a compatible string for SM8475 for supporting
pmic-glink.
This way, confusion is avoided, because SM8475 takes most
(CPU/GPU/reserved-memory/etc.) things from SM8450 and some (PHY/eUSB)
from SM8550.
Instead of using one or the other, add a different compatible string.
Signed-off-by: Esteban Urrutia <esteuwu@proton.me>
---
Changes in v2:
- Apply suggestions from Krzysztof
- Link to v1: https://patch.msgid.link/20260729-sm8475-pmic-glink-v1-0-c2e1967c04de@proton.me
---
Esteban Urrutia (2):
dt-bindings: soc: qcom: qcom,pmic-glink: Add compatible string for SM8475
usb: typec: ucsi: ucsi_glink: Add compatible string for SM8475
Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml | 1 +
drivers/usb/typec/ucsi/ucsi_glink.c | 1 +
2 files changed, 2 insertions(+)
---
base-commit: 95d6a9ccef99117115e41e9adb271243bd5e985b
change-id: 20260729-sm8475-pmic-glink-57e56f98d2b3
Best regards,
--
Esteban Urrutia <esteuwu@proton.me>
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH v2 0/2] Support for pmic-glink in SM8475
@ 2026-07-31 5:00 ` Esteban Urrutia
0 siblings, 0 replies; 9+ messages in thread
From: Esteban Urrutia @ 2026-07-31 5:00 UTC (permalink / raw)
To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Heikki Krogerus, Greg Kroah-Hartman
Cc: linux-arm-msm, devicetree, linux-kernel, linux-usb, phone-devel,
Esteban Urrutia
This series adds a compatible string for SM8475 for supporting
pmic-glink.
This way, confusion is avoided, because SM8475 takes most
(CPU/GPU/reserved-memory/etc.) things from SM8450 and some (PHY/eUSB)
from SM8550.
Instead of using one or the other, add a different compatible string.
Signed-off-by: Esteban Urrutia <esteuwu@proton.me>
---
Changes in v2:
- Apply suggestions from Krzysztof
- Link to v1: https://patch.msgid.link/20260729-sm8475-pmic-glink-v1-0-c2e1967c04de@proton.me
---
Esteban Urrutia (2):
dt-bindings: soc: qcom: qcom,pmic-glink: Add compatible string for SM8475
usb: typec: ucsi: ucsi_glink: Add compatible string for SM8475
Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml | 1 +
drivers/usb/typec/ucsi/ucsi_glink.c | 1 +
2 files changed, 2 insertions(+)
---
base-commit: 95d6a9ccef99117115e41e9adb271243bd5e985b
change-id: 20260729-sm8475-pmic-glink-57e56f98d2b3
Best regards,
--
Esteban Urrutia <esteuwu@proton.me>
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH v2 1/2] dt-bindings: soc: qcom: qcom,pmic-glink: Add compatible string for SM8475
2026-07-31 5:00 ` Esteban Urrutia
@ 2026-07-31 5:00 ` Esteban Urrutia
-1 siblings, 0 replies; 9+ messages in thread
From: Esteban Urrutia via B4 Relay @ 2026-07-31 5:00 UTC (permalink / raw)
To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Heikki Krogerus, Greg Kroah-Hartman
Cc: linux-arm-msm, devicetree, linux-kernel, linux-usb, phone-devel,
Esteban Urrutia
From: Esteban Urrutia <esteuwu@proton.me>
Due to a different process design, SM8475 (4 nm) SoC takes things from both
SM8450 (4 LPX) and SM8550 (4 nm) SoCs.
Add a separate compatible string for this SoC to avoid possible confusions.
Signed-off-by: Esteban Urrutia <esteuwu@proton.me>
---
Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml b/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml
index 16ad4f5698fc..c80c72411381 100644
--- a/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml
+++ b/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml
@@ -30,6 +30,7 @@ properties:
- qcom,sc8280xp-pmic-glink
- qcom,sm8350-pmic-glink
- qcom,sm8450-pmic-glink
+ - qcom,sm8475-pmic-glink
- qcom,sm8550-pmic-glink
- const: qcom,pmic-glink
- items:
--
2.55.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH v2 1/2] dt-bindings: soc: qcom: qcom,pmic-glink: Add compatible string for SM8475
@ 2026-07-31 5:00 ` Esteban Urrutia
0 siblings, 0 replies; 9+ messages in thread
From: Esteban Urrutia @ 2026-07-31 5:00 UTC (permalink / raw)
To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Heikki Krogerus, Greg Kroah-Hartman
Cc: linux-arm-msm, devicetree, linux-kernel, linux-usb, phone-devel,
Esteban Urrutia
Due to a different process design, SM8475 (4 nm) SoC takes things from both
SM8450 (4 LPX) and SM8550 (4 nm) SoCs.
Add a separate compatible string for this SoC to avoid possible confusions.
Signed-off-by: Esteban Urrutia <esteuwu@proton.me>
---
Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml b/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml
index 16ad4f5698fc..c80c72411381 100644
--- a/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml
+++ b/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml
@@ -30,6 +30,7 @@ properties:
- qcom,sc8280xp-pmic-glink
- qcom,sm8350-pmic-glink
- qcom,sm8450-pmic-glink
+ - qcom,sm8475-pmic-glink
- qcom,sm8550-pmic-glink
- const: qcom,pmic-glink
- items:
--
2.55.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH v2 2/2] usb: typec: ucsi: ucsi_glink: Add compatible string for SM8475
2026-07-31 5:00 ` Esteban Urrutia
@ 2026-07-31 5:00 ` Esteban Urrutia
-1 siblings, 0 replies; 9+ messages in thread
From: Esteban Urrutia via B4 Relay @ 2026-07-31 5:00 UTC (permalink / raw)
To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Heikki Krogerus, Greg Kroah-Hartman
Cc: linux-arm-msm, devicetree, linux-kernel, linux-usb, phone-devel,
Esteban Urrutia
From: Esteban Urrutia <esteuwu@proton.me>
Add compatible string for the PMIC GLINK service running on the coprocessor
found in the SM8475 SoC.
Signed-off-by: Esteban Urrutia <esteuwu@proton.me>
---
drivers/usb/typec/ucsi/ucsi_glink.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/usb/typec/ucsi/ucsi_glink.c b/drivers/usb/typec/ucsi/ucsi_glink.c
index 12e07b9fe622..78a0ea349ed4 100644
--- a/drivers/usb/typec/ucsi/ucsi_glink.c
+++ b/drivers/usb/typec/ucsi/ucsi_glink.c
@@ -381,6 +381,7 @@ static const struct of_device_id pmic_glink_ucsi_of_quirks[] = {
{ .compatible = "qcom,sc8280xp-pmic-glink", .data = &quirk_sc8280xp, },
{ .compatible = "qcom,sm8350-pmic-glink", .data = &quirk_sc8180x, },
{ .compatible = "qcom,sm8450-pmic-glink", .data = &quirk_sm8450, },
+ { .compatible = "qcom,sm8475-pmic-glink", .data = &quirk_sm8450, },
{ .compatible = "qcom,sm8550-pmic-glink", .data = &quirk_sm8450, },
{ .compatible = "qcom,x1e80100-pmic-glink", .data = &quirk_x1e80100, },
{}
--
2.55.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH v2 2/2] usb: typec: ucsi: ucsi_glink: Add compatible string for SM8475
@ 2026-07-31 5:00 ` Esteban Urrutia
0 siblings, 0 replies; 9+ messages in thread
From: Esteban Urrutia @ 2026-07-31 5:00 UTC (permalink / raw)
To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Heikki Krogerus, Greg Kroah-Hartman
Cc: linux-arm-msm, devicetree, linux-kernel, linux-usb, phone-devel,
Esteban Urrutia
Add compatible string for the PMIC GLINK service running on the coprocessor
found in the SM8475 SoC.
Signed-off-by: Esteban Urrutia <esteuwu@proton.me>
---
drivers/usb/typec/ucsi/ucsi_glink.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/usb/typec/ucsi/ucsi_glink.c b/drivers/usb/typec/ucsi/ucsi_glink.c
index 12e07b9fe622..78a0ea349ed4 100644
--- a/drivers/usb/typec/ucsi/ucsi_glink.c
+++ b/drivers/usb/typec/ucsi/ucsi_glink.c
@@ -381,6 +381,7 @@ static const struct of_device_id pmic_glink_ucsi_of_quirks[] = {
{ .compatible = "qcom,sc8280xp-pmic-glink", .data = &quirk_sc8280xp, },
{ .compatible = "qcom,sm8350-pmic-glink", .data = &quirk_sc8180x, },
{ .compatible = "qcom,sm8450-pmic-glink", .data = &quirk_sm8450, },
+ { .compatible = "qcom,sm8475-pmic-glink", .data = &quirk_sm8450, },
{ .compatible = "qcom,sm8550-pmic-glink", .data = &quirk_sm8450, },
{ .compatible = "qcom,x1e80100-pmic-glink", .data = &quirk_x1e80100, },
{}
--
2.55.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH v2 1/2] dt-bindings: soc: qcom: qcom,pmic-glink: Add compatible string for SM8475
2026-07-31 5:00 ` Esteban Urrutia
(?)
@ 2026-07-31 5:10 ` sashiko-bot
-1 siblings, 0 replies; 9+ messages in thread
From: sashiko-bot @ 2026-07-31 5:10 UTC (permalink / raw)
To: Esteban Urrutia; +Cc: devicetree, conor+dt, robh
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] The new compatible string `qcom,sm8475-pmic-glink` is missing from driver match tables, which will cause functional failures for UCSI (Type-C PD) and potentially the Battery Manager.
--
--- Patch [1]: [PATCH v2 1/2] dt-bindings: soc: qcom: qcom,pmic-glink: Add compatible string for SM8475 ---
commit 6029f64195b0d5f78f56d1dc22f18faabeb47c53
Author: Esteban Urrutia <esteuwu@proton.me>
dt-bindings: soc: qcom: qcom,pmic-glink: Add compatible string for SM8475
This commit adds a new compatible string for the SM8475 SoC to the pmic-glink
binding. It separates the SM8475 from SM8450 and SM8550 due to process design
differences.
> diff --git a/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml b/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml
> index 16ad4f5698fc3..c80c724113816 100644
> --- a/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml
> +++ b/Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml
> @@ -30,6 +30,7 @@ properties:
> - qcom,sc8280xp-pmic-glink
> - qcom,sm8350-pmic-glink
> - qcom,sm8450-pmic-glink
> + - qcom,sm8475-pmic-glink
[Severity: High]
Should this compatible string also be added to the driver match tables in
drivers/usb/typec/ucsi/ucsi_glink.c and drivers/power/supply/qcom_battmgr.c?
Looking at pmic_glink_ucsi_of_quirks in drivers/usb/typec/ucsi/ucsi_glink.c,
missing this compatible string causes of_match_device to return NULL. Since
both SM8450 and SM8550 require quirk_sm8450 to enable UCSI_DELAY_DEVICE_PDOS,
missing this quirk on SM8475 might lead to USB Type-C Power Delivery
negotiation failures.
Additionally, in qcom_battmgr_of_variants in qcom_battmgr.c, an unlisted
compatible string implicitly falls back to QCOM_BATTMGR_SM8350. Does SM8475
require the QCOM_BATTMGR_SM8550 variant instead, and could this cause battery
manager regressions?
> - qcom,sm8550-pmic-glink
> - const: qcom,pmic-glink
> - items:
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260731-sm8475-pmic-glink-v2-0-28c04928ef22@proton.me?part=1
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v2 2/2] usb: typec: ucsi: ucsi_glink: Add compatible string for SM8475
2026-07-31 5:00 ` Esteban Urrutia
(?)
@ 2026-07-31 5:17 ` sashiko-bot
-1 siblings, 0 replies; 9+ messages in thread
From: sashiko-bot @ 2026-07-31 5:17 UTC (permalink / raw)
To: Esteban Urrutia; +Cc: conor+dt, devicetree, robh
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
Pre-existing issues:
- [High] The format specifier %pOFn is incorrectly used with a struct fwnode_handle pointer.
--
--- Patch [2]: [PATCH v2 2/2] usb: typec: ucsi: ucsi_glink: Add compatible string for SM8475 ---
commit d37a66c9dfca5e74cbcec6a0c03a891ac3e2d3bd
Author: Esteban Urrutia <esteuwu@proton.me>
usb: typec: ucsi: ucsi_glink: Add compatible string for SM8475
Add compatible string for the PMIC GLINK service running on the coprocessor
found in the SM8475 SoC.
> diff --git a/drivers/usb/typec/ucsi/ucsi_glink.c b/drivers/usb/typec/ucsi/ucsi_glink.c
> index 12e07b9fe6228..78a0ea349ed41 100644
> --- a/drivers/usb/typec/ucsi/ucsi_glink.c
> +++ b/drivers/usb/typec/ucsi/ucsi_glink.c
> @@ -381,6 +381,7 @@ static const struct of_device_id pmic_glink_ucsi_of_quirks[] = {
> { .compatible = "qcom,sc8280xp-pmic-glink", .data = &quirk_sc8280xp, },
> { .compatible = "qcom,sm8350-pmic-glink", .data = &quirk_sc8180x, },
> { .compatible = "qcom,sm8450-pmic-glink", .data = &quirk_sm8450, },
> + { .compatible = "qcom,sm8475-pmic-glink", .data = &quirk_sm8450, },
> { .compatible = "qcom,sm8550-pmic-glink", .data = &quirk_sm8450, },
> { .compatible = "qcom,x1e80100-pmic-glink", .data = &quirk_x1e80100, },
> {}
[Severity: High]
This is a pre-existing issue, but does pmic_glink_ucsi_probe() pass the
wrong pointer type to dev_err() when handling a missing property?
drivers/usb/typec/ucsi/ucsi_glink.c:pmic_glink_ucsi_probe() {
...
device_for_each_child_node_scoped(dev, fwnode) {
struct gpio_desc *desc;
u32 port;
ret = fwnode_property_read_u32(fwnode, "reg", &port);
if (ret < 0) {
dev_err(dev, "missing reg property of %pOFn\n", fwnode);
return ret;
}
...
}
The %pOFn format specifier expects a struct device_node pointer, but it is
being passed a struct fwnode_handle pointer here.
When vsnprintf processes %pOFn, it will cast the pointer to struct device_node
and read the name or full_name fields at offsets that do not match struct
fwnode_handle.
Can this exceed the size of the structure and result in reading unrelated kernel
memory, potentially causing a kernel panic due to an invalid memory access if a
child node is missing the reg property?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260731-sm8475-pmic-glink-v2-0-28c04928ef22@proton.me?part=2
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v2 2/2] usb: typec: ucsi: ucsi_glink: Add compatible string for SM8475
2026-07-31 5:00 ` Esteban Urrutia
(?)
(?)
@ 2026-07-31 5:40 ` Esteban Urrutia
-1 siblings, 0 replies; 9+ messages in thread
From: Esteban Urrutia @ 2026-07-31 5:40 UTC (permalink / raw)
To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Heikki Krogerus, Greg Kroah-Hartman
Cc: linux-arm-msm, devicetree, linux-kernel, linux-usb, phone-devel
On 7/31/26 1:00 AM, Esteban Urrutia via B4 Relay wrote:
> Add compatible string for the PMIC GLINK service running on the coprocessor
> found in the SM8475 SoC.
Just realized I forgot to change the commit title... Will fix in v3.
Regards,
Esteban
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2026-07-31 5:40 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-31 5:00 [PATCH v2 0/2] Support for pmic-glink in SM8475 Esteban Urrutia via B4 Relay
2026-07-31 5:00 ` Esteban Urrutia
2026-07-31 5:00 ` [PATCH v2 1/2] dt-bindings: soc: qcom: qcom,pmic-glink: Add compatible string for SM8475 Esteban Urrutia via B4 Relay
2026-07-31 5:00 ` Esteban Urrutia
2026-07-31 5:10 ` sashiko-bot
2026-07-31 5:00 ` [PATCH v2 2/2] usb: typec: ucsi: ucsi_glink: " Esteban Urrutia via B4 Relay
2026-07-31 5:00 ` Esteban Urrutia
2026-07-31 5:17 ` sashiko-bot
2026-07-31 5:40 ` Esteban Urrutia
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.