* [PATCH v2 01/16] dt-bindings: display/msm: dsi-controller-main: Combine if:then: entries
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-19 23:19 ` Rob Herring (Arm)
2025-02-17 16:41 ` [PATCH v2 02/16] dt-bindings: display/msm: dsi-controller-main: Add missing minItems Krzysztof Kozlowski
` (15 subsequent siblings)
16 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Several devices have the same clock inputs, thus they can be in the same
if:then: clause, making everything smaller. No functional impact.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
.../bindings/display/msm/dsi-controller-main.yaml | 64 ++--------------------
1 file changed, 5 insertions(+), 59 deletions(-)
diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
index ffbd1dc9470e2091b477b0c88392d81802119f48..e496e5430918d54b2f07f1d5b64de85d29256951 100644
--- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
@@ -248,24 +248,6 @@ allOf:
contains:
enum:
- qcom,msm8916-dsi-ctrl
- then:
- properties:
- clocks:
- maxItems: 6
- clock-names:
- items:
- - const: mdp_core
- - const: iface
- - const: bus
- - const: byte
- - const: pixel
- - const: core
-
- - if:
- properties:
- compatible:
- contains:
- enum:
- qcom,msm8953-dsi-ctrl
- qcom,msm8976-dsi-ctrl
then:
@@ -328,28 +310,13 @@ allOf:
contains:
enum:
- qcom,msm8998-dsi-ctrl
- - qcom,sm6125-dsi-ctrl
- - qcom,sm6350-dsi-ctrl
- then:
- properties:
- clocks:
- maxItems: 6
- clock-names:
- items:
- - const: byte
- - const: byte_intf
- - const: pixel
- - const: core
- - const: iface
- - const: bus
-
- - if:
- properties:
- compatible:
- contains:
- enum:
- qcom,sc7180-dsi-ctrl
- qcom,sc7280-dsi-ctrl
+ - qcom,sdm845-dsi-ctrl
+ - qcom,sm6115-dsi-ctrl
+ - qcom,sm6125-dsi-ctrl
+ - qcom,sm6350-dsi-ctrl
+ - qcom,sm6375-dsi-ctrl
- qcom,sm6150-dsi-ctrl
- qcom,sm7150-dsi-ctrl
- qcom,sm8150-dsi-ctrl
@@ -393,27 +360,6 @@ allOf:
- const: pixel
- const: core
- - if:
- properties:
- compatible:
- contains:
- enum:
- - qcom,sdm845-dsi-ctrl
- - qcom,sm6115-dsi-ctrl
- - qcom,sm6375-dsi-ctrl
- then:
- properties:
- clocks:
- maxItems: 6
- clock-names:
- items:
- - const: byte
- - const: byte_intf
- - const: pixel
- - const: core
- - const: iface
- - const: bus
-
unevaluatedProperties: false
examples:
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 01/16] dt-bindings: display/msm: dsi-controller-main: Combine if:then: entries
2025-02-17 16:41 ` [PATCH v2 01/16] dt-bindings: display/msm: dsi-controller-main: Combine if:then: entries Krzysztof Kozlowski
@ 2025-02-19 23:19 ` Rob Herring (Arm)
0 siblings, 0 replies; 54+ messages in thread
From: Rob Herring (Arm) @ 2025-02-19 23:19 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Krzysztof Kozlowski, Thomas Zimmermann, Kuogee Hsieh, dri-devel,
Neil Armstrong, Conor Dooley, linux-arm-msm, Rob Clark, freedreno,
David Airlie, devicetree, Krishna Manikandan, linux-kernel,
Marijn Suijten, Jonathan Marek, Abhinav Kumar, Srini Kandagatla,
Simona Vetter, Dmitry Baryshkov, Maxime Ripard, Sean Paul,
Maarten Lankhorst
On Mon, 17 Feb 2025 17:41:22 +0100, Krzysztof Kozlowski wrote:
> Several devices have the same clock inputs, thus they can be in the same
> if:then: clause, making everything smaller. No functional impact.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> .../bindings/display/msm/dsi-controller-main.yaml | 64 ++--------------------
> 1 file changed, 5 insertions(+), 59 deletions(-)
>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 02/16] dt-bindings: display/msm: dsi-controller-main: Add missing minItems
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
2025-02-17 16:41 ` [PATCH v2 01/16] dt-bindings: display/msm: dsi-controller-main: Combine if:then: entries Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-19 23:20 ` Rob Herring (Arm)
2025-02-17 16:41 ` [PATCH v2 03/16] dt-bindings: display/msm: dsi-phy-7nm: Add SM8750 Krzysztof Kozlowski
` (14 subsequent siblings)
16 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Specific constrain in if:then: blocks for variable lists, like clocks
and clock-names, should have a fixed upper and lower size. Older
dtschema implied minItems, but that's not true since 2024 and missing
minItems means that lower bound is not set.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
.../devicetree/bindings/display/msm/dsi-controller-main.yaml | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
index e496e5430918d54b2f07f1d5b64de85d29256951..2aab33cd0017cd4a0c915b7297bb3952e62561fa 100644
--- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
@@ -231,6 +231,7 @@ allOf:
then:
properties:
clocks:
+ minItems: 7
maxItems: 7
clock-names:
items:
@@ -253,6 +254,7 @@ allOf:
then:
properties:
clocks:
+ minItems: 6
maxItems: 6
clock-names:
items:
@@ -273,6 +275,7 @@ allOf:
then:
properties:
clocks:
+ minItems: 7
maxItems: 7
clock-names:
items:
@@ -293,6 +296,7 @@ allOf:
then:
properties:
clocks:
+ minItems: 7
maxItems: 7
clock-names:
items:
@@ -328,6 +332,7 @@ allOf:
then:
properties:
clocks:
+ minItems: 6
maxItems: 6
clock-names:
items:
@@ -347,6 +352,7 @@ allOf:
then:
properties:
clocks:
+ minItems: 9
maxItems: 9
clock-names:
items:
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 02/16] dt-bindings: display/msm: dsi-controller-main: Add missing minItems
2025-02-17 16:41 ` [PATCH v2 02/16] dt-bindings: display/msm: dsi-controller-main: Add missing minItems Krzysztof Kozlowski
@ 2025-02-19 23:20 ` Rob Herring (Arm)
0 siblings, 0 replies; 54+ messages in thread
From: Rob Herring (Arm) @ 2025-02-19 23:20 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Neil Armstrong, Maxime Ripard, linux-arm-msm, Rob Clark,
Krishna Manikandan, Conor Dooley, Thomas Zimmermann, devicetree,
Marijn Suijten, Krzysztof Kozlowski, Simona Vetter, Abhinav Kumar,
Dmitry Baryshkov, Srini Kandagatla, Sean Paul, linux-kernel,
Maarten Lankhorst, Jonathan Marek, David Airlie, Kuogee Hsieh,
freedreno, dri-devel
On Mon, 17 Feb 2025 17:41:23 +0100, Krzysztof Kozlowski wrote:
> Specific constrain in if:then: blocks for variable lists, like clocks
> and clock-names, should have a fixed upper and lower size. Older
> dtschema implied minItems, but that's not true since 2024 and missing
> minItems means that lower bound is not set.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> .../devicetree/bindings/display/msm/dsi-controller-main.yaml | 6 ++++++
> 1 file changed, 6 insertions(+)
>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 03/16] dt-bindings: display/msm: dsi-phy-7nm: Add SM8750
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
2025-02-17 16:41 ` [PATCH v2 01/16] dt-bindings: display/msm: dsi-controller-main: Combine if:then: entries Krzysztof Kozlowski
2025-02-17 16:41 ` [PATCH v2 02/16] dt-bindings: display/msm: dsi-controller-main: Add missing minItems Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-19 23:20 ` Rob Herring (Arm)
2025-02-17 16:41 ` [PATCH v2 04/16] dt-bindings: display/msm: dsi-controller-main: " Krzysztof Kozlowski
` (13 subsequent siblings)
16 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Add DSI PHY v7.0 for Qualcomm SM8750 SoC which is quite different from
previous (SM8650) generation.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
Documentation/devicetree/bindings/display/msm/dsi-phy-7nm.yaml | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/devicetree/bindings/display/msm/dsi-phy-7nm.yaml b/Documentation/devicetree/bindings/display/msm/dsi-phy-7nm.yaml
index 321470435e654f1d569fc54f6a810e3f70fb168c..4ac262d3feb1293c65633f3b804b4f34c518400c 100644
--- a/Documentation/devicetree/bindings/display/msm/dsi-phy-7nm.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dsi-phy-7nm.yaml
@@ -23,6 +23,7 @@ properties:
- qcom,sm8450-dsi-phy-5nm
- qcom,sm8550-dsi-phy-4nm
- qcom,sm8650-dsi-phy-4nm
+ - qcom,sm8750-dsi-phy-3nm
reg:
items:
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 03/16] dt-bindings: display/msm: dsi-phy-7nm: Add SM8750
2025-02-17 16:41 ` [PATCH v2 03/16] dt-bindings: display/msm: dsi-phy-7nm: Add SM8750 Krzysztof Kozlowski
@ 2025-02-19 23:20 ` Rob Herring (Arm)
0 siblings, 0 replies; 54+ messages in thread
From: Rob Herring (Arm) @ 2025-02-19 23:20 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Thomas Zimmermann, Krishna Manikandan, linux-arm-msm,
linux-kernel, Marijn Suijten, Neil Armstrong, Conor Dooley,
Simona Vetter, Jonathan Marek, Maxime Ripard, Srini Kandagatla,
freedreno, Dmitry Baryshkov, devicetree, Maarten Lankhorst,
Sean Paul, David Airlie, Rob Clark, Abhinav Kumar, Kuogee Hsieh,
dri-devel, Krzysztof Kozlowski
On Mon, 17 Feb 2025 17:41:24 +0100, Krzysztof Kozlowski wrote:
> Add DSI PHY v7.0 for Qualcomm SM8750 SoC which is quite different from
> previous (SM8650) generation.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> Documentation/devicetree/bindings/display/msm/dsi-phy-7nm.yaml | 1 +
> 1 file changed, 1 insertion(+)
>
Acked-by: Rob Herring (Arm) <robh@kernel.org>
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 04/16] dt-bindings: display/msm: dsi-controller-main: Add SM8750
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (2 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 03/16] dt-bindings: display/msm: dsi-phy-7nm: Add SM8750 Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-19 23:21 ` Rob Herring (Arm)
2025-02-17 16:41 ` [PATCH v2 05/16] dt-bindings: display/msm: dp-controller: " Krzysztof Kozlowski
` (12 subsequent siblings)
16 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Add DSI controller for Qualcomm SM8750 SoC which is quite different from
previous (SM8650) generation.
It does not allow the display clock controller clocks like "byte" and
"pixel" to be reparented to DSI PHY PLLs while the DSI PHY PLL is not
configured (not prepared, rate not set). Therefore
assigned-clock-parents are not working here and driver is responsible
for reparenting clocks with proper procedure. These clocks are now
inputs to the DSI controller device.
Except that SM8750 DSI comes with several differences, new blocks and
changes in registers, making it incompatible with SM8650.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
.../bindings/display/msm/dsi-controller-main.yaml | 54 ++++++++++++++++++++--
1 file changed, 49 insertions(+), 5 deletions(-)
diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
index 2aab33cd0017cd4a0c915b7297bb3952e62561fa..8ecb2d8e296edf555df7380eac284b41a3f000a5 100644
--- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
@@ -40,6 +40,7 @@ properties:
- qcom,sm8450-dsi-ctrl
- qcom,sm8550-dsi-ctrl
- qcom,sm8650-dsi-ctrl
+ - qcom,sm8750-dsi-ctrl
- const: qcom,mdss-dsi-ctrl
- enum:
- qcom,dsi-ctrl-6g-qcm2290
@@ -68,11 +69,11 @@ properties:
- mnoc:: MNOC clock
- pixel:: Display pixel clock.
minItems: 3
- maxItems: 9
+ maxItems: 12
clock-names:
minItems: 3
- maxItems: 9
+ maxItems: 12
phys:
maxItems: 1
@@ -107,7 +108,8 @@ properties:
minItems: 2
maxItems: 4
description: |
- Parents of "byte" and "pixel" for the given platform.
+ For DSI on SM8650 and older: parents of "byte" and "pixel" for the given
+ platform.
For DSIv2 platforms this should contain "byte", "esc", "src" and
"pixel_src" clocks.
@@ -216,8 +218,6 @@ required:
- clocks
- clock-names
- phys
- - assigned-clocks
- - assigned-clock-parents
- ports
allOf:
@@ -242,6 +242,9 @@ allOf:
- const: byte
- const: pixel
- const: core
+ required:
+ - assigned-clocks
+ - assigned-clock-parents
- if:
properties:
@@ -264,6 +267,9 @@ allOf:
- const: byte
- const: pixel
- const: core
+ required:
+ - assigned-clocks
+ - assigned-clock-parents
- if:
properties:
@@ -286,6 +292,9 @@ allOf:
- const: pixel
- const: core
- const: core_mmss
+ required:
+ - assigned-clocks
+ - assigned-clock-parents
- if:
properties:
@@ -307,6 +316,9 @@ allOf:
- const: core_mmss
- const: pixel
- const: core
+ required:
+ - assigned-clocks
+ - assigned-clock-parents
- if:
properties:
@@ -342,6 +354,35 @@ allOf:
- const: core
- const: iface
- const: bus
+ required:
+ - assigned-clocks
+ - assigned-clock-parents
+
+ - if:
+ properties:
+ compatible:
+ contains:
+ enum:
+ - qcom,sm8750-dsi-ctrl
+ then:
+ properties:
+ clocks:
+ minItems: 12
+ maxItems: 12
+ clock-names:
+ items:
+ - const: byte
+ - const: byte_intf
+ - const: pixel
+ - const: core
+ - const: iface
+ - const: bus
+ - const: dsi_pll_pixel
+ - const: dsi_pll_byte
+ - const: esync
+ - const: osc
+ - const: byte_src
+ - const: pixel_src
- if:
properties:
@@ -365,6 +406,9 @@ allOf:
- const: core_mmss
- const: pixel
- const: core
+ required:
+ - assigned-clocks
+ - assigned-clock-parents
unevaluatedProperties: false
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 04/16] dt-bindings: display/msm: dsi-controller-main: Add SM8750
2025-02-17 16:41 ` [PATCH v2 04/16] dt-bindings: display/msm: dsi-controller-main: " Krzysztof Kozlowski
@ 2025-02-19 23:21 ` Rob Herring (Arm)
0 siblings, 0 replies; 54+ messages in thread
From: Rob Herring (Arm) @ 2025-02-19 23:21 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Dmitry Baryshkov, Krzysztof Kozlowski, Marijn Suijten,
Jonathan Marek, Maarten Lankhorst, freedreno, Rob Clark,
Srini Kandagatla, Conor Dooley, Thomas Zimmermann, Sean Paul,
Kuogee Hsieh, David Airlie, Abhinav Kumar, dri-devel,
linux-arm-msm, devicetree, Maxime Ripard, Krishna Manikandan,
Neil Armstrong, linux-kernel, Simona Vetter
On Mon, 17 Feb 2025 17:41:25 +0100, Krzysztof Kozlowski wrote:
> Add DSI controller for Qualcomm SM8750 SoC which is quite different from
> previous (SM8650) generation.
>
> It does not allow the display clock controller clocks like "byte" and
> "pixel" to be reparented to DSI PHY PLLs while the DSI PHY PLL is not
> configured (not prepared, rate not set). Therefore
> assigned-clock-parents are not working here and driver is responsible
> for reparenting clocks with proper procedure. These clocks are now
> inputs to the DSI controller device.
>
> Except that SM8750 DSI comes with several differences, new blocks and
> changes in registers, making it incompatible with SM8650.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> .../bindings/display/msm/dsi-controller-main.yaml | 54 ++++++++++++++++++++--
> 1 file changed, 49 insertions(+), 5 deletions(-)
>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 05/16] dt-bindings: display/msm: dp-controller: Add SM8750
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (3 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 04/16] dt-bindings: display/msm: dsi-controller-main: " Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-17 18:58 ` Dmitry Baryshkov
2025-02-17 16:41 ` [PATCH v2 06/16] dt-bindings: display/msm: qcom,sm8650-dpu: " Krzysztof Kozlowski
` (11 subsequent siblings)
16 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Add DisplayPort controller for Qualcomm SM8750 SoC which so far looks
fully compatible with earlier SM8650 variant.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
Documentation/devicetree/bindings/display/msm/dp-controller.yaml | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml
index e00b88332f2fed2fc33f6d72c5cc3d827cd7594e..a4bf9e07a28355c0391d1757fab16ebe5ff14a44 100644
--- a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml
@@ -37,6 +37,10 @@ properties:
- qcom,sm8450-dp
- qcom,sm8550-dp
- const: qcom,sm8350-dp
+ - items:
+ - enum:
+ - qcom,sm8750-dp
+ - const: qcom,sm8650-dp
reg:
minItems: 4
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 05/16] dt-bindings: display/msm: dp-controller: Add SM8750
2025-02-17 16:41 ` [PATCH v2 05/16] dt-bindings: display/msm: dp-controller: " Krzysztof Kozlowski
@ 2025-02-17 18:58 ` Dmitry Baryshkov
2025-02-19 17:02 ` Krzysztof Kozlowski
0 siblings, 1 reply; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-17 18:58 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Mon, Feb 17, 2025 at 05:41:26PM +0100, Krzysztof Kozlowski wrote:
> Add DisplayPort controller for Qualcomm SM8750 SoC which so far looks
> fully compatible with earlier SM8650 variant.
As that became a question for QCS8300, does SM8750 also support exactly
two MST streams?
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> Documentation/devicetree/bindings/display/msm/dp-controller.yaml | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml
> index e00b88332f2fed2fc33f6d72c5cc3d827cd7594e..a4bf9e07a28355c0391d1757fab16ebe5ff14a44 100644
> --- a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml
> +++ b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml
> @@ -37,6 +37,10 @@ properties:
> - qcom,sm8450-dp
> - qcom,sm8550-dp
> - const: qcom,sm8350-dp
> + - items:
> + - enum:
> + - qcom,sm8750-dp
> + - const: qcom,sm8650-dp
>
> reg:
> minItems: 4
>
> --
> 2.43.0
>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 05/16] dt-bindings: display/msm: dp-controller: Add SM8750
2025-02-17 18:58 ` Dmitry Baryshkov
@ 2025-02-19 17:02 ` Krzysztof Kozlowski
2025-02-19 17:08 ` Dmitry Baryshkov
0 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-19 17:02 UTC (permalink / raw)
To: Dmitry Baryshkov
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 17/02/2025 19:58, Dmitry Baryshkov wrote:
> On Mon, Feb 17, 2025 at 05:41:26PM +0100, Krzysztof Kozlowski wrote:
>> Add DisplayPort controller for Qualcomm SM8750 SoC which so far looks
>> fully compatible with earlier SM8650 variant.
>
> As that became a question for QCS8300, does SM8750 also support exactly
> two MST streams?
v1.5 of DP (starting from SA8775p , then SM8650 and SM8750) support 4x
MST for DPTX0 and 2x MST for DPTX1.
The DP in SM8650 and SM8750 are identical, according to datasheet (v1.5.1).
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 05/16] dt-bindings: display/msm: dp-controller: Add SM8750
2025-02-19 17:02 ` Krzysztof Kozlowski
@ 2025-02-19 17:08 ` Dmitry Baryshkov
2025-02-24 18:59 ` Abhinav Kumar
0 siblings, 1 reply; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-19 17:08 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Wed, Feb 19, 2025 at 06:02:20PM +0100, Krzysztof Kozlowski wrote:
> On 17/02/2025 19:58, Dmitry Baryshkov wrote:
> > On Mon, Feb 17, 2025 at 05:41:26PM +0100, Krzysztof Kozlowski wrote:
> >> Add DisplayPort controller for Qualcomm SM8750 SoC which so far looks
> >> fully compatible with earlier SM8650 variant.
> >
> > As that became a question for QCS8300, does SM8750 also support exactly
> > two MST streams?
>
> v1.5 of DP (starting from SA8775p , then SM8650 and SM8750) support 4x
> MST for DPTX0 and 2x MST for DPTX1.
>
> The DP in SM8650 and SM8750 are identical, according to datasheet (v1.5.1).
Hmm. This also means that QCS8300 is compatible with SM8650. I'll let
Abhinav comment here.
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 05/16] dt-bindings: display/msm: dp-controller: Add SM8750
2025-02-19 17:08 ` Dmitry Baryshkov
@ 2025-02-24 18:59 ` Abhinav Kumar
2025-02-25 3:14 ` Dmitry Baryshkov
0 siblings, 1 reply; 54+ messages in thread
From: Abhinav Kumar @ 2025-02-24 18:59 UTC (permalink / raw)
To: Dmitry Baryshkov, Krzysztof Kozlowski
Cc: Rob Clark, Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong, linux-arm-msm,
dri-devel, freedreno, devicetree, linux-kernel, Srini Kandagatla
On 2/19/2025 9:08 AM, Dmitry Baryshkov wrote:
> On Wed, Feb 19, 2025 at 06:02:20PM +0100, Krzysztof Kozlowski wrote:
>> On 17/02/2025 19:58, Dmitry Baryshkov wrote:
>>> On Mon, Feb 17, 2025 at 05:41:26PM +0100, Krzysztof Kozlowski wrote:
>>>> Add DisplayPort controller for Qualcomm SM8750 SoC which so far looks
>>>> fully compatible with earlier SM8650 variant.
>>>
>>> As that became a question for QCS8300, does SM8750 also support exactly
>>> two MST streams?
>>
>> v1.5 of DP (starting from SA8775p , then SM8650 and SM8750) support 4x
>> MST for DPTX0 and 2x MST for DPTX1.
>>
>> The DP in SM8650 and SM8750 are identical, according to datasheet (v1.5.1).
>
> Hmm. This also means that QCS8300 is compatible with SM8650. I'll let
> Abhinav comment here.
>
DP version by itself is not a good measure of whether the controller can
support 4 streams or not.
Firstly, sm8650/sm8750 do not have a DPTX1 so we are only discussing
about DP TX0.
Coming to the QCS8300 Vs sm8650/sm8750, even though the DP controller
version is the same, there is no HW support for more than 2 streams on
sm8650/sm8750 because there are no INTF blocks to drive 4 streams.
On sm8650/sm8750, only INTF_0 and INTF_3 can be used for DP. Hence 2
streams.
Whereas on Monaco, we have INTF_0, INTF_3, INTF_6 and INTF_7 capable of
driving DP. Hence 4 streams.
Let me know if there are more questions.
Thanks
Abhinav
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 05/16] dt-bindings: display/msm: dp-controller: Add SM8750
2025-02-24 18:59 ` Abhinav Kumar
@ 2025-02-25 3:14 ` Dmitry Baryshkov
2025-03-03 21:23 ` Abhinav Kumar
0 siblings, 1 reply; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-25 3:14 UTC (permalink / raw)
To: Abhinav Kumar
Cc: Krzysztof Kozlowski, Rob Clark, Sean Paul, Marijn Suijten,
David Airlie, Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Mon, 24 Feb 2025 at 20:59, Abhinav Kumar <quic_abhinavk@quicinc.com> wrote:
>
>
>
> On 2/19/2025 9:08 AM, Dmitry Baryshkov wrote:
> > On Wed, Feb 19, 2025 at 06:02:20PM +0100, Krzysztof Kozlowski wrote:
> >> On 17/02/2025 19:58, Dmitry Baryshkov wrote:
> >>> On Mon, Feb 17, 2025 at 05:41:26PM +0100, Krzysztof Kozlowski wrote:
> >>>> Add DisplayPort controller for Qualcomm SM8750 SoC which so far looks
> >>>> fully compatible with earlier SM8650 variant.
> >>>
> >>> As that became a question for QCS8300, does SM8750 also support exactly
> >>> two MST streams?
> >>
> >> v1.5 of DP (starting from SA8775p , then SM8650 and SM8750) support 4x
> >> MST for DPTX0 and 2x MST for DPTX1.
> >>
> >> The DP in SM8650 and SM8750 are identical, according to datasheet (v1.5.1).
> >
> > Hmm. This also means that QCS8300 is compatible with SM8650. I'll let
> > Abhinav comment here.
> >
>
> DP version by itself is not a good measure of whether the controller can
> support 4 streams or not.
>
> Firstly, sm8650/sm8750 do not have a DPTX1 so we are only discussing
> about DP TX0.
>
> Coming to the QCS8300 Vs sm8650/sm8750, even though the DP controller
> version is the same, there is no HW support for more than 2 streams on
> sm8650/sm8750 because there are no INTF blocks to drive 4 streams.
>
> On sm8650/sm8750, only INTF_0 and INTF_3 can be used for DP. Hence 2
> streams.
>
> Whereas on Monaco, we have INTF_0, INTF_3, INTF_6 and INTF_7 capable of
No idea what Monaco is, most likely it is some platform. Please use
SoC names in public.
> driving DP. Hence 4 streams.
>
> Let me know if there are more questions.
How many stream clocks are present on those platforms? I'm asking
because there is a small, but not non-existing difference between 'DPs
are not completely compatible / the same' and 'DPs are fully
compatible but different DPU blocks impose different restrictions on
the number of MST streams'.
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 05/16] dt-bindings: display/msm: dp-controller: Add SM8750
2025-02-25 3:14 ` Dmitry Baryshkov
@ 2025-03-03 21:23 ` Abhinav Kumar
2025-03-04 0:06 ` Dmitry Baryshkov
0 siblings, 1 reply; 54+ messages in thread
From: Abhinav Kumar @ 2025-03-03 21:23 UTC (permalink / raw)
To: Dmitry Baryshkov
Cc: Krzysztof Kozlowski, Rob Clark, Sean Paul, Marijn Suijten,
David Airlie, Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 2/24/2025 7:14 PM, Dmitry Baryshkov wrote:
> On Mon, 24 Feb 2025 at 20:59, Abhinav Kumar <quic_abhinavk@quicinc.com> wrote:
>>
>>
>>
>> On 2/19/2025 9:08 AM, Dmitry Baryshkov wrote:
>>> On Wed, Feb 19, 2025 at 06:02:20PM +0100, Krzysztof Kozlowski wrote:
>>>> On 17/02/2025 19:58, Dmitry Baryshkov wrote:
>>>>> On Mon, Feb 17, 2025 at 05:41:26PM +0100, Krzysztof Kozlowski wrote:
>>>>>> Add DisplayPort controller for Qualcomm SM8750 SoC which so far looks
>>>>>> fully compatible with earlier SM8650 variant.
>>>>>
>>>>> As that became a question for QCS8300, does SM8750 also support exactly
>>>>> two MST streams?
>>>>
>>>> v1.5 of DP (starting from SA8775p , then SM8650 and SM8750) support 4x
>>>> MST for DPTX0 and 2x MST for DPTX1.
>>>>
>>>> The DP in SM8650 and SM8750 are identical, according to datasheet (v1.5.1).
>>>
>>> Hmm. This also means that QCS8300 is compatible with SM8650. I'll let
>>> Abhinav comment here.
>>>
>>
>> DP version by itself is not a good measure of whether the controller can
>> support 4 streams or not.
>>
>> Firstly, sm8650/sm8750 do not have a DPTX1 so we are only discussing
>> about DP TX0.
>>
>> Coming to the QCS8300 Vs sm8650/sm8750, even though the DP controller
>> version is the same, there is no HW support for more than 2 streams on
>> sm8650/sm8750 because there are no INTF blocks to drive 4 streams.
>>
>> On sm8650/sm8750, only INTF_0 and INTF_3 can be used for DP. Hence 2
>> streams.
>>
>> Whereas on Monaco, we have INTF_0, INTF_3, INTF_6 and INTF_7 capable of
>
> No idea what Monaco is, most likely it is some platform. Please use
> SoC names in public.
>
Monaco is indeed QCS8300. I usually do use SoC names, in this instance
just intuitively ended up using the internal one as I use it often.
>> driving DP. Hence 4 streams.
>>
>> Let me know if there are more questions.
>
> How many stream clocks are present on those platforms? I'm asking
> because there is a small, but not non-existing difference between 'DPs
> are not completely compatible / the same' and 'DPs are fully
> compatible but different DPU blocks impose different restrictions on
> the number of MST streams'.
>
I have confirmed this internally. sm8650/sm8750 have only 2 stream
clocks and not 4.
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 05/16] dt-bindings: display/msm: dp-controller: Add SM8750
2025-03-03 21:23 ` Abhinav Kumar
@ 2025-03-04 0:06 ` Dmitry Baryshkov
0 siblings, 0 replies; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-03-04 0:06 UTC (permalink / raw)
To: Abhinav Kumar
Cc: Krzysztof Kozlowski, Rob Clark, Sean Paul, Marijn Suijten,
David Airlie, Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Mon, Mar 03, 2025 at 01:23:11PM -0800, Abhinav Kumar wrote:
>
>
> On 2/24/2025 7:14 PM, Dmitry Baryshkov wrote:
> > On Mon, 24 Feb 2025 at 20:59, Abhinav Kumar <quic_abhinavk@quicinc.com> wrote:
> > >
> > >
> > >
> > > On 2/19/2025 9:08 AM, Dmitry Baryshkov wrote:
> > > > On Wed, Feb 19, 2025 at 06:02:20PM +0100, Krzysztof Kozlowski wrote:
> > > > > On 17/02/2025 19:58, Dmitry Baryshkov wrote:
> > > > > > On Mon, Feb 17, 2025 at 05:41:26PM +0100, Krzysztof Kozlowski wrote:
> > > > > > > Add DisplayPort controller for Qualcomm SM8750 SoC which so far looks
> > > > > > > fully compatible with earlier SM8650 variant.
> > > > > >
> > > > > > As that became a question for QCS8300, does SM8750 also support exactly
> > > > > > two MST streams?
> > > > >
> > > > > v1.5 of DP (starting from SA8775p , then SM8650 and SM8750) support 4x
> > > > > MST for DPTX0 and 2x MST for DPTX1.
> > > > >
> > > > > The DP in SM8650 and SM8750 are identical, according to datasheet (v1.5.1).
> > > >
> > > > Hmm. This also means that QCS8300 is compatible with SM8650. I'll let
> > > > Abhinav comment here.
> > > >
> > >
> > > DP version by itself is not a good measure of whether the controller can
> > > support 4 streams or not.
> > >
> > > Firstly, sm8650/sm8750 do not have a DPTX1 so we are only discussing
> > > about DP TX0.
> > >
> > > Coming to the QCS8300 Vs sm8650/sm8750, even though the DP controller
> > > version is the same, there is no HW support for more than 2 streams on
> > > sm8650/sm8750 because there are no INTF blocks to drive 4 streams.
> > >
> > > On sm8650/sm8750, only INTF_0 and INTF_3 can be used for DP. Hence 2
> > > streams.
> > >
> > > Whereas on Monaco, we have INTF_0, INTF_3, INTF_6 and INTF_7 capable of
> >
> > No idea what Monaco is, most likely it is some platform. Please use
> > SoC names in public.
> >
>
> Monaco is indeed QCS8300. I usually do use SoC names, in this instance just
> intuitively ended up using the internal one as I use it often.
>
> > > driving DP. Hence 4 streams.
> > >
> > > Let me know if there are more questions.
> >
> > How many stream clocks are present on those platforms? I'm asking
> > because there is a small, but not non-existing difference between 'DPs
> > are not completely compatible / the same' and 'DPs are fully
> > compatible but different DPU blocks impose different restrictions on
> > the number of MST streams'.
> >
>
> I have confirmed this internally. sm8650/sm8750 have only 2 stream clocks
> and not 4.
Ack, thanks.
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 06/16] dt-bindings: display/msm: qcom,sm8650-dpu: Add SM8750
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (4 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 05/16] dt-bindings: display/msm: dp-controller: " Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-19 23:23 ` Rob Herring (Arm)
2025-02-17 16:41 ` [PATCH v2 07/16] dt-bindings: display/msm: qcom,sm8750-mdss: " Krzysztof Kozlowski
` (10 subsequent siblings)
16 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Add DPU for Qualcomm SM8750 SoC which has several differences, new
blocks and changes in registers, making it incompatible with SM8650.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
Documentation/devicetree/bindings/display/msm/qcom,sm8650-dpu.yaml | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/devicetree/bindings/display/msm/qcom,sm8650-dpu.yaml b/Documentation/devicetree/bindings/display/msm/qcom,sm8650-dpu.yaml
index 01cf79bd754b491349c52c5aef49ba06e835d0bf..0a46120dd8680371ed031f7773859716f49c3aa1 100644
--- a/Documentation/devicetree/bindings/display/msm/qcom,sm8650-dpu.yaml
+++ b/Documentation/devicetree/bindings/display/msm/qcom,sm8650-dpu.yaml
@@ -16,6 +16,7 @@ properties:
enum:
- qcom,sa8775p-dpu
- qcom,sm8650-dpu
+ - qcom,sm8750-dpu
- qcom,x1e80100-dpu
reg:
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 06/16] dt-bindings: display/msm: qcom,sm8650-dpu: Add SM8750
2025-02-17 16:41 ` [PATCH v2 06/16] dt-bindings: display/msm: qcom,sm8650-dpu: " Krzysztof Kozlowski
@ 2025-02-19 23:23 ` Rob Herring (Arm)
0 siblings, 0 replies; 54+ messages in thread
From: Rob Herring (Arm) @ 2025-02-19 23:23 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Simona Vetter, Sean Paul, linux-kernel, Conor Dooley,
Abhinav Kumar, Neil Armstrong, Thomas Zimmermann, Kuogee Hsieh,
linux-arm-msm, dri-devel, Marijn Suijten, freedreno, David Airlie,
Dmitry Baryshkov, Maxime Ripard, Jonathan Marek,
Krishna Manikandan, devicetree, Krzysztof Kozlowski, Rob Clark,
Maarten Lankhorst, Srini Kandagatla
On Mon, 17 Feb 2025 17:41:27 +0100, Krzysztof Kozlowski wrote:
> Add DPU for Qualcomm SM8750 SoC which has several differences, new
> blocks and changes in registers, making it incompatible with SM8650.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> Documentation/devicetree/bindings/display/msm/qcom,sm8650-dpu.yaml | 1 +
> 1 file changed, 1 insertion(+)
>
Acked-by: Rob Herring (Arm) <robh@kernel.org>
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 07/16] dt-bindings: display/msm: qcom,sm8750-mdss: Add SM8750
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (5 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 06/16] dt-bindings: display/msm: qcom,sm8650-dpu: " Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-19 23:27 ` Rob Herring
2025-02-17 16:41 ` [PATCH v2 08/16] drm/msm/dpu: Drop useless comments Krzysztof Kozlowski
` (9 subsequent siblings)
16 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Add MDSS/MDP display subsystem for Qualcomm SM8750 SoC, next generation
with two revisions up of the IP block comparing to SM8650.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
.../bindings/display/msm/qcom,sm8750-mdss.yaml | 460 +++++++++++++++++++++
1 file changed, 460 insertions(+)
diff --git a/Documentation/devicetree/bindings/display/msm/qcom,sm8750-mdss.yaml b/Documentation/devicetree/bindings/display/msm/qcom,sm8750-mdss.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..cfa21b0d081338f1b94779594798f86284ba0677
--- /dev/null
+++ b/Documentation/devicetree/bindings/display/msm/qcom,sm8750-mdss.yaml
@@ -0,0 +1,460 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/display/msm/qcom,sm8750-mdss.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Qualcomm SM8750 Display MDSS
+
+maintainers:
+ - Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
+
+description:
+ SM8650 MSM Mobile Display Subsystem(MDSS), which encapsulates sub-blocks like
+ DPU display controller, DSI and DP interfaces etc.
+
+$ref: /schemas/display/msm/mdss-common.yaml#
+
+properties:
+ compatible:
+ const: qcom,sm8750-mdss
+
+ clocks:
+ items:
+ - description: Display AHB
+ - description: Display hf AXI
+ - description: Display core
+
+ iommus:
+ maxItems: 1
+
+ interconnects:
+ maxItems: 2
+
+ interconnect-names:
+ maxItems: 2
+
+patternProperties:
+ "^display-controller@[0-9a-f]+$":
+ type: object
+ additionalProperties: true
+ properties:
+ compatible:
+ const: qcom,sm8750-dpu
+
+ "^displayport-controller@[0-9a-f]+$":
+ type: object
+ additionalProperties: true
+ properties:
+ compatible:
+ items:
+ - const: qcom,sm8750-dp
+ - const: qcom,sm8650-dp
+
+ "^dsi@[0-9a-f]+$":
+ type: object
+ additionalProperties: true
+ properties:
+ compatible:
+ items:
+ - const: qcom,sm8750-dsi-ctrl
+ - const: qcom,mdss-dsi-ctrl
+
+ "^phy@[0-9a-f]+$":
+ type: object
+ additionalProperties: true
+ properties:
+ compatible:
+ const: qcom,sm8750-dsi-phy-3nm
+
+required:
+ - compatible
+
+unevaluatedProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/clock/qcom,rpmh.h>
+ #include <dt-bindings/interconnect/qcom,icc.h>
+ #include <dt-bindings/interrupt-controller/arm-gic.h>
+ #include <dt-bindings/phy/phy-qcom-qmp.h>
+ #include <dt-bindings/power/qcom,rpmhpd.h>
+
+ display-subsystem@ae00000 {
+ compatible = "qcom,sm8750-mdss";
+ reg = <0x0ae00000 0x1000>;
+ reg-names = "mdss";
+
+ interrupts = <GIC_SPI 83 IRQ_TYPE_LEVEL_HIGH>;
+
+ clocks = <&disp_cc_mdss_ahb_clk>,
+ <&gcc_disp_hf_axi_clk>,
+ <&disp_cc_mdss_mdp_clk>;
+
+ resets = <&disp_cc_mdss_core_bcr>;
+
+ power-domains = <&mdss_gdsc>;
+
+ iommus = <&apps_smmu 0x800 0x2>;
+
+ interrupt-controller;
+ #interrupt-cells = <1>;
+
+ #address-cells = <1>;
+ #size-cells = <1>;
+ ranges;
+
+ display-controller@ae01000 {
+ compatible = "qcom,sm8750-dpu";
+ reg = <0x0ae01000 0x93000>,
+ <0x0aeb0000 0x2008>;
+ reg-names = "mdp",
+ "vbif";
+
+ interrupts-extended = <&mdss 0>;
+
+ clocks = <&gcc_disp_hf_axi_clk>,
+ <&disp_cc_mdss_ahb_clk>,
+ <&disp_cc_mdss_mdp_lut_clk>,
+ <&disp_cc_mdss_mdp_clk>,
+ <&disp_cc_mdss_vsync_clk>;
+ clock-names = "nrt_bus",
+ "iface",
+ "lut",
+ "core",
+ "vsync";
+
+ assigned-clocks = <&disp_cc_mdss_vsync_clk>;
+ assigned-clock-rates = <19200000>;
+
+ operating-points-v2 = <&mdp_opp_table>;
+
+ power-domains = <&rpmhpd RPMHPD_MMCX>;
+
+ ports {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ port@0 {
+ reg = <0>;
+
+ dpu_intf1_out: endpoint {
+ remote-endpoint = <&mdss_dsi0_in>;
+ };
+ };
+
+ port@1 {
+ reg = <1>;
+
+ dpu_intf2_out: endpoint {
+ remote-endpoint = <&mdss_dsi1_in>;
+ };
+ };
+
+ port@2 {
+ reg = <2>;
+
+ dpu_intf0_out: endpoint {
+ remote-endpoint = <&mdss_dp0_in>;
+ };
+ };
+ };
+
+ mdp_opp_table: opp-table {
+ compatible = "operating-points-v2";
+
+ opp-207000000 {
+ opp-hz = /bits/ 64 <207000000>;
+ required-opps = <&rpmhpd_opp_low_svs>;
+ };
+
+ opp-337000000 {
+ opp-hz = /bits/ 64 <337000000>;
+ required-opps = <&rpmhpd_opp_svs>;
+ };
+
+ opp-417000000 {
+ opp-hz = /bits/ 64 <417000000>;
+ required-opps = <&rpmhpd_opp_svs_l1>;
+ };
+
+ opp-532000000 {
+ opp-hz = /bits/ 64 <532000000>;
+ required-opps = <&rpmhpd_opp_nom>;
+ };
+
+ opp-575000000 {
+ opp-hz = /bits/ 64 <575000000>;
+ required-opps = <&rpmhpd_opp_nom_l1>;
+ };
+ };
+ };
+
+ dsi@ae94000 {
+ compatible = "qcom,sm8750-dsi-ctrl", "qcom,mdss-dsi-ctrl";
+ reg = <0x0ae94000 0x400>;
+ reg-names = "dsi_ctrl";
+
+ interrupts-extended = <&mdss 4>;
+
+ clocks = <&disp_cc_mdss_byte0_clk>,
+ <&disp_cc_mdss_byte0_intf_clk>,
+ <&disp_cc_mdss_pclk0_clk>,
+ <&disp_cc_mdss_esc0_clk>,
+ <&disp_cc_mdss_ahb_clk>,
+ <&gcc_disp_hf_axi_clk>,
+ <&mdss_dsi0_phy 1>,
+ <&mdss_dsi0_phy 0>,
+ <&disp_cc_esync0_clk>,
+ <&disp_cc_osc_clk>,
+ <&disp_cc_mdss_byte0_clk_src>,
+ <&disp_cc_mdss_pclk0_clk_src>;
+ clock-names = "byte",
+ "byte_intf",
+ "pixel",
+ "core",
+ "iface",
+ "bus",
+ "dsi_pll_pixel",
+ "dsi_pll_byte",
+ "esync",
+ "osc",
+ "byte_src",
+ "pixel_src";
+
+ operating-points-v2 = <&mdss_dsi_opp_table>;
+
+ power-domains = <&rpmhpd RPMHPD_MMCX>;
+
+ phys = <&mdss_dsi0_phy>;
+ phy-names = "dsi";
+
+ vdda-supply = <&vreg_l3g_1p2>;
+
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ ports {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ port@0 {
+ reg = <0>;
+
+ mdss_dsi0_in: endpoint {
+ remote-endpoint = <&dpu_intf1_out>;
+ };
+ };
+
+ port@1 {
+ reg = <1>;
+
+ mdss_dsi0_out: endpoint {
+ remote-endpoint = <&panel0_in>;
+ data-lanes = <0 1 2 3>;
+ };
+ };
+ };
+
+ mdss_dsi_opp_table: opp-table {
+ compatible = "operating-points-v2";
+
+ opp-187500000 {
+ opp-hz = /bits/ 64 <187500000>;
+ required-opps = <&rpmhpd_opp_low_svs>;
+ };
+
+ opp-300000000 {
+ opp-hz = /bits/ 64 <300000000>;
+ required-opps = <&rpmhpd_opp_svs>;
+ };
+
+ opp-358000000 {
+ opp-hz = /bits/ 64 <358000000>;
+ required-opps = <&rpmhpd_opp_svs_l1>;
+ };
+ };
+ };
+
+ mdss_dsi0_phy: phy@ae95000 {
+ compatible = "qcom,sm8750-dsi-phy-3nm";
+ reg = <0x0ae95000 0x200>,
+ <0x0ae95200 0x280>,
+ <0x0ae95500 0x400>;
+ reg-names = "dsi_phy",
+ "dsi_phy_lane",
+ "dsi_pll";
+
+ clocks = <&disp_cc_mdss_ahb_clk>,
+ <&rpmhcc RPMH_CXO_CLK>;
+ clock-names = "iface",
+ "ref";
+
+ vdds-supply = <&vreg_l3i_0p88>;
+
+ #clock-cells = <1>;
+ #phy-cells = <0>;
+ };
+
+ dsi@ae96000 {
+ compatible = "qcom,sm8750-dsi-ctrl", "qcom,mdss-dsi-ctrl";
+ reg = <0x0ae96000 0x400>;
+ reg-names = "dsi_ctrl";
+
+ interrupts-extended = <&mdss 5>;
+
+ clocks = <&disp_cc_mdss_byte1_clk>,
+ <&disp_cc_mdss_byte1_intf_clk>,
+ <&disp_cc_mdss_pclk1_clk>,
+ <&disp_cc_mdss_esc1_clk>,
+ <&disp_cc_mdss_ahb_clk>,
+ <&gcc_disp_hf_axi_clk>,
+ <&mdss_dsi1_phy 1>,
+ <&mdss_dsi1_phy 0>,
+ <&disp_cc_esync1_clk>,
+ <&disp_cc_osc_clk>,
+ <&disp_cc_mdss_byte1_clk_src>,
+ <&disp_cc_mdss_pclk1_clk_src>;
+ clock-names = "byte",
+ "byte_intf",
+ "pixel",
+ "core",
+ "iface",
+ "bus",
+ "dsi_pll_pixel",
+ "dsi_pll_byte",
+ "esync",
+ "osc",
+ "byte_src",
+ "pixel_src";
+
+ operating-points-v2 = <&mdss_dsi_opp_table>;
+
+ power-domains = <&rpmhpd RPMHPD_MMCX>;
+
+ phys = <&mdss_dsi1_phy>;
+ phy-names = "dsi";
+
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ ports {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ port@0 {
+ reg = <0>;
+
+ mdss_dsi1_in: endpoint {
+ remote-endpoint = <&dpu_intf2_out>;
+ };
+ };
+
+ port@1 {
+ reg = <1>;
+
+ mdss_dsi1_out: endpoint {
+ };
+ };
+ };
+ };
+
+ mdss_dsi1_phy: phy@ae97000 {
+ compatible = "qcom,sm8750-dsi-phy-3nm";
+ reg = <0x0ae97000 0x200>,
+ <0x0ae97200 0x280>,
+ <0x0ae97500 0x400>;
+ reg-names = "dsi_phy",
+ "dsi_phy_lane",
+ "dsi_pll";
+
+ clocks = <&disp_cc_mdss_ahb_clk>,
+ <&rpmhcc RPMH_CXO_CLK>;
+ clock-names = "iface",
+ "ref";
+
+ #clock-cells = <1>;
+ #phy-cells = <0>;
+ };
+
+ displayport-controller@af54000 {
+ compatible = "qcom,sm8750-dp", "qcom,sm8650-dp";
+ reg = <0xaf54000 0x104>,
+ <0xaf54200 0xc0>,
+ <0xaf55000 0x770>,
+ <0xaf56000 0x9c>,
+ <0xaf57000 0x9c>;
+
+ interrupts-extended = <&mdss 12>;
+
+ clocks = <&disp_cc_mdss_ahb_clk>,
+ <&disp_cc_mdss_dptx0_aux_clk>,
+ <&disp_cc_mdss_dptx0_link_clk>,
+ <&disp_cc_mdss_dptx0_link_intf_clk>,
+ <&disp_cc_mdss_dptx0_pixel0_clk>;
+ clock-names = "core_iface",
+ "core_aux",
+ "ctrl_link",
+ "ctrl_link_iface",
+ "stream_pixel";
+
+ assigned-clocks = <&disp_cc_mdss_dptx0_link_clk_src>,
+ <&disp_cc_mdss_dptx0_pixel0_clk_src>;
+ assigned-clock-parents = <&usb_dp_qmpphy QMP_USB43DP_DP_LINK_CLK>,
+ <&usb_dp_qmpphy QMP_USB43DP_DP_VCO_DIV_CLK>;
+
+ operating-points-v2 = <&dp_opp_table>;
+
+ power-domains = <&rpmhpd RPMHPD_MMCX>;
+
+ phys = <&usb_dp_qmpphy QMP_USB43DP_DP_PHY>;
+ phy-names = "dp";
+
+ #sound-dai-cells = <0>;
+
+ dp_opp_table: opp-table {
+ compatible = "operating-points-v2";
+
+ opp-192000000 {
+ opp-hz = /bits/ 64 <192000000>;
+ required-opps = <&rpmhpd_opp_low_svs_d1>;
+ };
+
+ opp-270000000 {
+ opp-hz = /bits/ 64 <270000000>;
+ required-opps = <&rpmhpd_opp_low_svs>;
+ };
+
+ opp-540000000 {
+ opp-hz = /bits/ 64 <540000000>;
+ required-opps = <&rpmhpd_opp_svs_l1>;
+ };
+
+ opp-810000000 {
+ opp-hz = /bits/ 64 <810000000>;
+ required-opps = <&rpmhpd_opp_nom>;
+ };
+ };
+
+ ports {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ port@0 {
+ reg = <0>;
+
+ mdss_dp0_in: endpoint {
+ remote-endpoint = <&dpu_intf0_out>;
+ };
+ };
+
+ port@1 {
+ reg = <1>;
+
+ mdss_dp0_out: endpoint {
+ remote-endpoint = <&usb_dp_qmpphy_dp_in>;
+ };
+ };
+ };
+ };
+ };
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 07/16] dt-bindings: display/msm: qcom,sm8750-mdss: Add SM8750
2025-02-17 16:41 ` [PATCH v2 07/16] dt-bindings: display/msm: qcom,sm8750-mdss: " Krzysztof Kozlowski
@ 2025-02-19 23:27 ` Rob Herring
0 siblings, 0 replies; 54+ messages in thread
From: Rob Herring @ 2025-02-19 23:27 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Krzysztof Kozlowski,
Conor Dooley, Krishna Manikandan, Jonathan Marek, Kuogee Hsieh,
Neil Armstrong, linux-arm-msm, dri-devel, freedreno, devicetree,
linux-kernel, Srini Kandagatla
On Mon, Feb 17, 2025 at 05:41:28PM +0100, Krzysztof Kozlowski wrote:
> Add MDSS/MDP display subsystem for Qualcomm SM8750 SoC, next generation
> with two revisions up of the IP block comparing to SM8650.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> .../bindings/display/msm/qcom,sm8750-mdss.yaml | 460 +++++++++++++++++++++
> 1 file changed, 460 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/display/msm/qcom,sm8750-mdss.yaml b/Documentation/devicetree/bindings/display/msm/qcom,sm8750-mdss.yaml
> new file mode 100644
> index 0000000000000000000000000000000000000000..cfa21b0d081338f1b94779594798f86284ba0677
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/display/msm/qcom,sm8750-mdss.yaml
> @@ -0,0 +1,460 @@
> +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/display/msm/qcom,sm8750-mdss.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Qualcomm SM8750 Display MDSS
> +
> +maintainers:
> + - Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> +
> +description:
> + SM8650 MSM Mobile Display Subsystem(MDSS), which encapsulates sub-blocks like
> + DPU display controller, DSI and DP interfaces etc.
> +
> +$ref: /schemas/display/msm/mdss-common.yaml#
> +
> +properties:
> + compatible:
> + const: qcom,sm8750-mdss
> +
> + clocks:
> + items:
> + - description: Display AHB
> + - description: Display hf AXI
> + - description: Display core
> +
> + iommus:
> + maxItems: 1
> +
> + interconnects:
> + maxItems: 2
> +
> + interconnect-names:
> + maxItems: 2
> +
> +patternProperties:
> + "^display-controller@[0-9a-f]+$":
> + type: object
> + additionalProperties: true
> + properties:
> + compatible:
> + const: qcom,sm8750-dpu
> +
> + "^displayport-controller@[0-9a-f]+$":
> + type: object
> + additionalProperties: true
> + properties:
> + compatible:
> + items:
> + - const: qcom,sm8750-dp
> + - const: qcom,sm8650-dp
Just use 'contains' here with the 8750 compatible. We'll check the order
when the DP schema is applied.
Up to you what to do on the ones with a single compatible.
Rob
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 08/16] drm/msm/dpu: Drop useless comments
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (6 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 07/16] dt-bindings: display/msm: qcom,sm8750-mdss: " Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-17 19:22 ` Dmitry Baryshkov
2025-02-19 21:19 ` Jessica Zhang
2025-02-17 16:41 ` [PATCH v2 09/16] drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5 Krzysztof Kozlowski
` (8 subsequent siblings)
16 siblings, 2 replies; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Drop comments about SoC before each 'struct dpu_lm_sub_blks' for given
SoC because it's duplicating the actual name of structure.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 8 --------
1 file changed, 8 deletions(-)
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
index 7ea424d7c1b75e06312692225f4e888e81621283..4ff29be965c39b29cf7e3b9761634b7f39ca97b0 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
@@ -362,8 +362,6 @@ static const struct dpu_sspp_sub_blks dpu_dma_sblk = _DMA_SBLK();
* MIXER sub blocks config
*************************************************************/
-/* MSM8998 */
-
static const struct dpu_lm_sub_blks msm8998_lm_sblk = {
.maxwidth = DEFAULT_DPU_OUTPUT_LINE_WIDTH,
.maxblendstages = 7, /* excluding base layer */
@@ -373,8 +371,6 @@ static const struct dpu_lm_sub_blks msm8998_lm_sblk = {
},
};
-/* SDM845 */
-
static const struct dpu_lm_sub_blks sdm845_lm_sblk = {
.maxwidth = DEFAULT_DPU_OUTPUT_LINE_WIDTH,
.maxblendstages = 11, /* excluding base layer */
@@ -384,8 +380,6 @@ static const struct dpu_lm_sub_blks sdm845_lm_sblk = {
},
};
-/* SC7180 */
-
static const struct dpu_lm_sub_blks sc7180_lm_sblk = {
.maxwidth = DEFAULT_DPU_OUTPUT_LINE_WIDTH,
.maxblendstages = 7, /* excluding base layer */
@@ -394,8 +388,6 @@ static const struct dpu_lm_sub_blks sc7180_lm_sblk = {
},
};
-/* QCM2290 */
-
static const struct dpu_lm_sub_blks qcm2290_lm_sblk = {
.maxwidth = DEFAULT_DPU_LINE_WIDTH,
.maxblendstages = 4, /* excluding base layer */
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 08/16] drm/msm/dpu: Drop useless comments
2025-02-17 16:41 ` [PATCH v2 08/16] drm/msm/dpu: Drop useless comments Krzysztof Kozlowski
@ 2025-02-17 19:22 ` Dmitry Baryshkov
2025-02-19 21:19 ` Jessica Zhang
1 sibling, 0 replies; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-17 19:22 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Mon, Feb 17, 2025 at 05:41:29PM +0100, Krzysztof Kozlowski wrote:
> Drop comments about SoC before each 'struct dpu_lm_sub_blks' for given
> SoC because it's duplicating the actual name of structure.
Historically there were more SoC-specific data, now we are really
limited to the LM sblk. Maybe that points out that we should rename
those to drop the SoC name. Anyway,
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 8 --------
> 1 file changed, 8 deletions(-)
>
> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
> index 7ea424d7c1b75e06312692225f4e888e81621283..4ff29be965c39b29cf7e3b9761634b7f39ca97b0 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
> @@ -362,8 +362,6 @@ static const struct dpu_sspp_sub_blks dpu_dma_sblk = _DMA_SBLK();
> * MIXER sub blocks config
> *************************************************************/
>
> -/* MSM8998 */
> -
> static const struct dpu_lm_sub_blks msm8998_lm_sblk = {
> .maxwidth = DEFAULT_DPU_OUTPUT_LINE_WIDTH,
> .maxblendstages = 7, /* excluding base layer */
> @@ -373,8 +371,6 @@ static const struct dpu_lm_sub_blks msm8998_lm_sblk = {
> },
> };
>
> -/* SDM845 */
> -
> static const struct dpu_lm_sub_blks sdm845_lm_sblk = {
> .maxwidth = DEFAULT_DPU_OUTPUT_LINE_WIDTH,
> .maxblendstages = 11, /* excluding base layer */
> @@ -384,8 +380,6 @@ static const struct dpu_lm_sub_blks sdm845_lm_sblk = {
> },
> };
>
> -/* SC7180 */
> -
> static const struct dpu_lm_sub_blks sc7180_lm_sblk = {
> .maxwidth = DEFAULT_DPU_OUTPUT_LINE_WIDTH,
> .maxblendstages = 7, /* excluding base layer */
> @@ -394,8 +388,6 @@ static const struct dpu_lm_sub_blks sc7180_lm_sblk = {
> },
> };
>
> -/* QCM2290 */
> -
> static const struct dpu_lm_sub_blks qcm2290_lm_sblk = {
> .maxwidth = DEFAULT_DPU_LINE_WIDTH,
> .maxblendstages = 4, /* excluding base layer */
>
> --
> 2.43.0
>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread* Re: [PATCH v2 08/16] drm/msm/dpu: Drop useless comments
2025-02-17 16:41 ` [PATCH v2 08/16] drm/msm/dpu: Drop useless comments Krzysztof Kozlowski
2025-02-17 19:22 ` Dmitry Baryshkov
@ 2025-02-19 21:19 ` Jessica Zhang
1 sibling, 0 replies; 54+ messages in thread
From: Jessica Zhang @ 2025-02-19 21:19 UTC (permalink / raw)
To: Krzysztof Kozlowski, Rob Clark, Abhinav Kumar, Dmitry Baryshkov,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 2/17/2025 8:41 AM, Krzysztof Kozlowski wrote:
> Drop comments about SoC before each 'struct dpu_lm_sub_blks' for given
> SoC because it's duplicating the actual name of structure.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Reviewed-by: Jessica Zhang <quic_jesszhan@quicinc.com>
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 8 --------
> 1 file changed, 8 deletions(-)
>
> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
> index 7ea424d7c1b75e06312692225f4e888e81621283..4ff29be965c39b29cf7e3b9761634b7f39ca97b0 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
> @@ -362,8 +362,6 @@ static const struct dpu_sspp_sub_blks dpu_dma_sblk = _DMA_SBLK();
> * MIXER sub blocks config
> *************************************************************/
>
> -/* MSM8998 */
> -
> static const struct dpu_lm_sub_blks msm8998_lm_sblk = {
> .maxwidth = DEFAULT_DPU_OUTPUT_LINE_WIDTH,
> .maxblendstages = 7, /* excluding base layer */
> @@ -373,8 +371,6 @@ static const struct dpu_lm_sub_blks msm8998_lm_sblk = {
> },
> };
>
> -/* SDM845 */
> -
> static const struct dpu_lm_sub_blks sdm845_lm_sblk = {
> .maxwidth = DEFAULT_DPU_OUTPUT_LINE_WIDTH,
> .maxblendstages = 11, /* excluding base layer */
> @@ -384,8 +380,6 @@ static const struct dpu_lm_sub_blks sdm845_lm_sblk = {
> },
> };
>
> -/* SC7180 */
> -
> static const struct dpu_lm_sub_blks sc7180_lm_sblk = {
> .maxwidth = DEFAULT_DPU_OUTPUT_LINE_WIDTH,
> .maxblendstages = 7, /* excluding base layer */
> @@ -394,8 +388,6 @@ static const struct dpu_lm_sub_blks sc7180_lm_sblk = {
> },
> };
>
> -/* QCM2290 */
> -
> static const struct dpu_lm_sub_blks qcm2290_lm_sblk = {
> .maxwidth = DEFAULT_DPU_LINE_WIDTH,
> .maxblendstages = 4, /* excluding base layer */
>
> --
> 2.43.0
>
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 09/16] drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (7 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 08/16] drm/msm/dpu: Drop useless comments Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-17 19:00 ` Dmitry Baryshkov
` (2 more replies)
2025-02-17 16:41 ` [PATCH v2 10/16] drm/msm/dpu: Add handling of LM_6 and LM_7 bits in pending flush mask Krzysztof Kozlowski
` (7 subsequent siblings)
16 siblings, 3 replies; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Add IDs for new blocks present in MDSS/MDP v12 for LM, DSC, PINGPONG and
MERGE_3D blocks.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h
index ba7bb05efe9b8cac01a908e53121117e130f91ec..440a327c64eb83a944289c6ce9ef9a5bfacc25f3 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h
@@ -123,6 +123,7 @@ enum dpu_lm {
LM_4,
LM_5,
LM_6,
+ LM_7,
LM_MAX
};
@@ -167,6 +168,8 @@ enum dpu_dsc {
DSC_3,
DSC_4,
DSC_5,
+ DSC_6,
+ DSC_7,
DSC_MAX
};
@@ -183,6 +186,8 @@ enum dpu_pingpong {
PINGPONG_3,
PINGPONG_4,
PINGPONG_5,
+ PINGPONG_6,
+ PINGPONG_7,
PINGPONG_CWB_0,
PINGPONG_CWB_1,
PINGPONG_CWB_2,
@@ -197,6 +202,7 @@ enum dpu_merge_3d {
MERGE_3D_2,
MERGE_3D_3,
MERGE_3D_4,
+ MERGE_3D_5,
MERGE_3D_MAX
};
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 09/16] drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5
2025-02-17 16:41 ` [PATCH v2 09/16] drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5 Krzysztof Kozlowski
@ 2025-02-17 19:00 ` Dmitry Baryshkov
2025-02-19 21:22 ` Jessica Zhang
2025-02-19 21:24 ` Jessica Zhang
2 siblings, 0 replies; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-17 19:00 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Mon, Feb 17, 2025 at 05:41:30PM +0100, Krzysztof Kozlowski wrote:
> Add IDs for new blocks present in MDSS/MDP v12 for LM, DSC, PINGPONG and
> MERGE_3D blocks.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h | 6 ++++++
> 1 file changed, 6 insertions(+)
>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 09/16] drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5
2025-02-17 16:41 ` [PATCH v2 09/16] drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5 Krzysztof Kozlowski
2025-02-17 19:00 ` Dmitry Baryshkov
@ 2025-02-19 21:22 ` Jessica Zhang
2025-02-19 21:24 ` Jessica Zhang
2 siblings, 0 replies; 54+ messages in thread
From: Jessica Zhang @ 2025-02-19 21:22 UTC (permalink / raw)
To: Krzysztof Kozlowski, Rob Clark, Abhinav Kumar, Dmitry Baryshkov,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 2/17/2025 8:41 AM, Krzysztof Kozlowski wrote:
> Add IDs for new blocks present in MDSS/MDP v12 for LM, DSC, PINGPONG and
> MERGE_3D blocks.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Reviewed-by: Jessica Zhang <quic_jesszhan@quicinc.com>
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h
> index ba7bb05efe9b8cac01a908e53121117e130f91ec..440a327c64eb83a944289c6ce9ef9a5bfacc25f3 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h
> @@ -123,6 +123,7 @@ enum dpu_lm {
> LM_4,
> LM_5,
> LM_6,
> + LM_7,
> LM_MAX
> };
>
> @@ -167,6 +168,8 @@ enum dpu_dsc {
> DSC_3,
> DSC_4,
> DSC_5,
> + DSC_6,
> + DSC_7,
> DSC_MAX
> };
>
> @@ -183,6 +186,8 @@ enum dpu_pingpong {
> PINGPONG_3,
> PINGPONG_4,
> PINGPONG_5,
> + PINGPONG_6,
> + PINGPONG_7,
> PINGPONG_CWB_0,
> PINGPONG_CWB_1,
> PINGPONG_CWB_2,
> @@ -197,6 +202,7 @@ enum dpu_merge_3d {
> MERGE_3D_2,
> MERGE_3D_3,
> MERGE_3D_4,
> + MERGE_3D_5,
> MERGE_3D_MAX
> };
>
>
> --
> 2.43.0
>
^ permalink raw reply [flat|nested] 54+ messages in thread* Re: [PATCH v2 09/16] drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5
2025-02-17 16:41 ` [PATCH v2 09/16] drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5 Krzysztof Kozlowski
2025-02-17 19:00 ` Dmitry Baryshkov
2025-02-19 21:22 ` Jessica Zhang
@ 2025-02-19 21:24 ` Jessica Zhang
2 siblings, 0 replies; 54+ messages in thread
From: Jessica Zhang @ 2025-02-19 21:24 UTC (permalink / raw)
To: Krzysztof Kozlowski, Rob Clark, Abhinav Kumar, Dmitry Baryshkov,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 2/17/2025 8:41 AM, Krzysztof Kozlowski wrote:
> Add IDs for new blocks present in MDSS/MDP v12 for LM, DSC, PINGPONG and
> MERGE_3D blocks.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Reviewed-by: Jessica Zhang <quic_jesszhan@quicinc.com>
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h
> index ba7bb05efe9b8cac01a908e53121117e130f91ec..440a327c64eb83a944289c6ce9ef9a5bfacc25f3 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h
> @@ -123,6 +123,7 @@ enum dpu_lm {
> LM_4,
> LM_5,
> LM_6,
> + LM_7,
> LM_MAX
> };
>
> @@ -167,6 +168,8 @@ enum dpu_dsc {
> DSC_3,
> DSC_4,
> DSC_5,
> + DSC_6,
> + DSC_7,
> DSC_MAX
> };
>
> @@ -183,6 +186,8 @@ enum dpu_pingpong {
> PINGPONG_3,
> PINGPONG_4,
> PINGPONG_5,
> + PINGPONG_6,
> + PINGPONG_7,
> PINGPONG_CWB_0,
> PINGPONG_CWB_1,
> PINGPONG_CWB_2,
> @@ -197,6 +202,7 @@ enum dpu_merge_3d {
> MERGE_3D_2,
> MERGE_3D_3,
> MERGE_3D_4,
> + MERGE_3D_5,
> MERGE_3D_MAX
> };
>
>
> --
> 2.43.0
>
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 10/16] drm/msm/dpu: Add handling of LM_6 and LM_7 bits in pending flush mask
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (8 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 09/16] drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5 Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-17 19:01 ` Dmitry Baryshkov
2025-02-19 21:28 ` Jessica Zhang
2025-02-17 16:41 ` [PATCH v2 11/16] drm/msm/dsi/phy: Add support for SM8750 Krzysztof Kozlowski
` (6 subsequent siblings)
16 siblings, 2 replies; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
MDSS/MDP v12 comes with new bits in flush registers (e.g.
MDP_CTL_0_FLUSH) for Layer Mixer 6 and 7.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
index 0021df38f8662683771abb2cef7794c3209e9413..9d4866509e97c262006e15cf3e02a2f1ca851784 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
@@ -254,6 +254,12 @@ static void dpu_hw_ctl_update_pending_flush_mixer(struct dpu_hw_ctl *ctx,
case LM_5:
ctx->pending_flush_mask |= BIT(20);
break;
+ case LM_6:
+ ctx->pending_flush_mask |= BIT(21);
+ break;
+ case LM_7:
+ ctx->pending_flush_mask |= BIT(27);
+ break;
default:
break;
}
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 10/16] drm/msm/dpu: Add handling of LM_6 and LM_7 bits in pending flush mask
2025-02-17 16:41 ` [PATCH v2 10/16] drm/msm/dpu: Add handling of LM_6 and LM_7 bits in pending flush mask Krzysztof Kozlowski
@ 2025-02-17 19:01 ` Dmitry Baryshkov
2025-02-19 21:28 ` Jessica Zhang
1 sibling, 0 replies; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-17 19:01 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Mon, Feb 17, 2025 at 05:41:31PM +0100, Krzysztof Kozlowski wrote:
> MDSS/MDP v12 comes with new bits in flush registers (e.g.
> MDP_CTL_0_FLUSH) for Layer Mixer 6 and 7.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 10/16] drm/msm/dpu: Add handling of LM_6 and LM_7 bits in pending flush mask
2025-02-17 16:41 ` [PATCH v2 10/16] drm/msm/dpu: Add handling of LM_6 and LM_7 bits in pending flush mask Krzysztof Kozlowski
2025-02-17 19:01 ` Dmitry Baryshkov
@ 2025-02-19 21:28 ` Jessica Zhang
1 sibling, 0 replies; 54+ messages in thread
From: Jessica Zhang @ 2025-02-19 21:28 UTC (permalink / raw)
To: Krzysztof Kozlowski, Rob Clark, Abhinav Kumar, Dmitry Baryshkov,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 2/17/2025 8:41 AM, Krzysztof Kozlowski wrote:
> MDSS/MDP v12 comes with new bits in flush registers (e.g.
> MDP_CTL_0_FLUSH) for Layer Mixer 6 and 7.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Reviewed-by: Jessica Zhang <quic_jesszhan@quicinc.com>
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
> index 0021df38f8662683771abb2cef7794c3209e9413..9d4866509e97c262006e15cf3e02a2f1ca851784 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
> @@ -254,6 +254,12 @@ static void dpu_hw_ctl_update_pending_flush_mixer(struct dpu_hw_ctl *ctx,
> case LM_5:
> ctx->pending_flush_mask |= BIT(20);
> break;
> + case LM_6:
> + ctx->pending_flush_mask |= BIT(21);
> + break;
> + case LM_7:
> + ctx->pending_flush_mask |= BIT(27);
> + break;
> default:
> break;
> }
>
> --
> 2.43.0
>
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 11/16] drm/msm/dsi/phy: Add support for SM8750
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (9 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 10/16] drm/msm/dpu: Add handling of LM_6 and LM_7 bits in pending flush mask Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-17 19:03 ` Dmitry Baryshkov
2025-02-20 0:50 ` Jessica Zhang
2025-02-17 16:41 ` [PATCH v2 12/16] drm/msm/dsi: " Krzysztof Kozlowski
` (5 subsequent siblings)
16 siblings, 2 replies; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Add support for DSI PHY v7.0 on Qualcomm SM8750 SoC which comes with an
incompatible hardware interface change:
ICODE_ACCUM_STATUS_LOW and ALOG_OBSV_BUS_STATUS_1 registers - their
offsets were just switched. Currently these registers are not used in
the driver, so the easiest is to document both but keep them commented
out to avoid conflict.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
Changes in v2:
1.
---
drivers/gpu/drm/msm/dsi/phy/dsi_phy.c | 2 +
drivers/gpu/drm/msm/dsi/phy/dsi_phy.h | 1 +
drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c | 79 ++++++++++++++++++++--
.../gpu/drm/msm/registers/display/dsi_phy_7nm.xml | 14 ++++
4 files changed, 90 insertions(+), 6 deletions(-)
diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c
index c0bcc68289633fd7506ce4f1f963655d862e8f08..60571237efc4d332959ac76ff1d6d6245f688469 100644
--- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c
+++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c
@@ -593,6 +593,8 @@ static const struct of_device_id dsi_phy_dt_match[] = {
.data = &dsi_phy_4nm_8550_cfgs },
{ .compatible = "qcom,sm8650-dsi-phy-4nm",
.data = &dsi_phy_4nm_8650_cfgs },
+ { .compatible = "qcom,sm8750-dsi-phy-3nm",
+ .data = &dsi_phy_3nm_8750_cfgs },
#endif
{}
};
diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h
index 8985818bb2e0934e9084a420c90e2269c2e1c414..fdb6c648e16f25812a2948053f31186d4c0d4413 100644
--- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h
+++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h
@@ -60,6 +60,7 @@ extern const struct msm_dsi_phy_cfg dsi_phy_5nm_8350_cfgs;
extern const struct msm_dsi_phy_cfg dsi_phy_5nm_8450_cfgs;
extern const struct msm_dsi_phy_cfg dsi_phy_4nm_8550_cfgs;
extern const struct msm_dsi_phy_cfg dsi_phy_4nm_8650_cfgs;
+extern const struct msm_dsi_phy_cfg dsi_phy_3nm_8750_cfgs;
struct msm_dsi_dphy_timing {
u32 clk_zero;
diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c
index 6d287cfb0148bdb0b1c64675dfe7fa69d3faba2d..b626989cb3d505f1c53f212dba130e3d685fe59c 100644
--- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c
+++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c
@@ -50,6 +50,8 @@
#define DSI_PHY_7NM_QUIRK_V4_3 BIT(3)
/* Hardware is V5.2 */
#define DSI_PHY_7NM_QUIRK_V5_2 BIT(4)
+/* Hardware is V7.0 */
+#define DSI_PHY_7NM_QUIRK_V7_0 BIT(5)
struct dsi_pll_config {
bool enable_ssc;
@@ -128,9 +130,30 @@ static void dsi_pll_calc_dec_frac(struct dsi_pll_7nm *pll, struct dsi_pll_config
dec_multiple = div_u64(pll_freq * multiplier, divider);
dec = div_u64_rem(dec_multiple, multiplier, &frac);
- if (pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_PRE_V4_1)
+ if (pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_PRE_V4_1) {
config->pll_clock_inverters = 0x28;
- else if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
+ } else if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
+ if (pll_freq < 163000000ULL)
+ config->pll_clock_inverters = 0xa0;
+ else if (pll_freq < 175000000ULL)
+ config->pll_clock_inverters = 0x20;
+ else if (pll_freq < 325000000ULL)
+ config->pll_clock_inverters = 0xa0;
+ else if (pll_freq < 350000000ULL)
+ config->pll_clock_inverters = 0x20;
+ else if (pll_freq < 650000000ULL)
+ config->pll_clock_inverters = 0xa0;
+ else if (pll_freq < 700000000ULL)
+ config->pll_clock_inverters = 0x20;
+ else if (pll_freq < 1300000000ULL)
+ config->pll_clock_inverters = 0xa0;
+ else if (pll_freq < 2500000000ULL)
+ config->pll_clock_inverters = 0x20;
+ else if (pll_freq < 4000000000ULL)
+ config->pll_clock_inverters = 0x00;
+ else
+ config->pll_clock_inverters = 0x40;
+ } else if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
if (pll_freq <= 1300000000ULL)
config->pll_clock_inverters = 0xa0;
else if (pll_freq <= 2500000000ULL)
@@ -249,7 +272,8 @@ static void dsi_pll_config_hzindep_reg(struct dsi_pll_7nm *pll)
vco_config_1 = 0x01;
}
- if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
+ if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2) ||
+ (pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
if (pll->vco_current_rate < 1557000000ULL)
vco_config_1 = 0x08;
else
@@ -624,6 +648,7 @@ static int dsi_7nm_pll_restore_state(struct msm_dsi_phy *phy)
static int dsi_7nm_set_usecase(struct msm_dsi_phy *phy)
{
struct dsi_pll_7nm *pll_7nm = to_pll_7nm(phy->vco_hw);
+ void __iomem *base = phy->base;
u32 data = 0x0; /* internal PLL */
DBG("DSI PLL%d", pll_7nm->phy->id);
@@ -633,6 +658,9 @@ static int dsi_7nm_set_usecase(struct msm_dsi_phy *phy)
break;
case MSM_DSI_PHY_MASTER:
pll_7nm->slave = pll_7nm_list[(pll_7nm->phy->id + 1) % DSI_MAX];
+ /* v7.0: Enable ATB_EN0 and alternate clock output to external phy */
+ if (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)
+ writel(0x07, base + REG_DSI_7nm_PHY_CMN_CTRL_5);
break;
case MSM_DSI_PHY_SLAVE:
data = 0x1; /* external PLL */
@@ -914,7 +942,8 @@ static int dsi_7nm_phy_enable(struct msm_dsi_phy *phy,
/* Request for REFGEN READY */
if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V4_3) ||
- (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
+ (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2) ||
+ (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
writel(0x1, phy->base + REG_DSI_7nm_PHY_CMN_GLBL_DIGTOP_SPARE10);
udelay(500);
}
@@ -948,7 +977,20 @@ static int dsi_7nm_phy_enable(struct msm_dsi_phy *phy,
lane_ctrl0 = 0x1f;
}
- if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
+ if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
+ if (phy->cphy_mode) {
+ /* TODO: different for second phy */
+ vreg_ctrl_0 = 0x57;
+ vreg_ctrl_1 = 0x41;
+ glbl_rescode_top_ctrl = 0x3d;
+ glbl_rescode_bot_ctrl = 0x38;
+ } else {
+ vreg_ctrl_0 = 0x56;
+ vreg_ctrl_1 = 0x19;
+ glbl_rescode_top_ctrl = less_than_1500_mhz ? 0x3c : 0x03;
+ glbl_rescode_bot_ctrl = less_than_1500_mhz ? 0x38 : 0x3c;
+ }
+ } else if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
if (phy->cphy_mode) {
vreg_ctrl_0 = 0x45;
vreg_ctrl_1 = 0x41;
@@ -1010,6 +1052,7 @@ static int dsi_7nm_phy_enable(struct msm_dsi_phy *phy,
/* program CMN_CTRL_4 for minor_ver 2 chipsets*/
if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2) ||
+ (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0) ||
(readl(base + REG_DSI_7nm_PHY_CMN_REVISION_ID0) & (0xf0)) == 0x20)
writel(0x04, base + REG_DSI_7nm_PHY_CMN_CTRL_4);
@@ -1124,7 +1167,8 @@ static void dsi_7nm_phy_disable(struct msm_dsi_phy *phy)
/* Turn off REFGEN Vote */
if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V4_3) ||
- (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
+ (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2) ||
+ (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
writel(0x0, base + REG_DSI_7nm_PHY_CMN_GLBL_DIGTOP_SPARE10);
wmb();
/* Delay to ensure HW removes vote before PHY shut down */
@@ -1341,3 +1385,26 @@ const struct msm_dsi_phy_cfg dsi_phy_4nm_8650_cfgs = {
.num_dsi_phy = 2,
.quirks = DSI_PHY_7NM_QUIRK_V5_2,
};
+
+const struct msm_dsi_phy_cfg dsi_phy_3nm_8750_cfgs = {
+ .has_phy_lane = true,
+ .regulator_data = dsi_phy_7nm_98000uA_regulators,
+ .num_regulators = ARRAY_SIZE(dsi_phy_7nm_98000uA_regulators),
+ .ops = {
+ .enable = dsi_7nm_phy_enable,
+ .disable = dsi_7nm_phy_disable,
+ .pll_init = dsi_pll_7nm_init,
+ .save_pll_state = dsi_7nm_pll_save_state,
+ .restore_pll_state = dsi_7nm_pll_restore_state,
+ .set_continuous_clock = dsi_7nm_set_continuous_clock,
+ },
+ .min_pll_rate = 600000000UL,
+#ifdef CONFIG_64BIT
+ .max_pll_rate = 5000000000UL,
+#else
+ .max_pll_rate = ULONG_MAX,
+#endif
+ .io_start = { 0xae95000, 0xae97000 },
+ .num_dsi_phy = 2,
+ .quirks = DSI_PHY_7NM_QUIRK_V7_0,
+};
diff --git a/drivers/gpu/drm/msm/registers/display/dsi_phy_7nm.xml b/drivers/gpu/drm/msm/registers/display/dsi_phy_7nm.xml
index d2c8c46bb04159da6e539bfe80a4b5dc9ffdf367..d62411961f5673e0a7a37b90cfc99962de83659e 100644
--- a/drivers/gpu/drm/msm/registers/display/dsi_phy_7nm.xml
+++ b/drivers/gpu/drm/msm/registers/display/dsi_phy_7nm.xml
@@ -26,6 +26,7 @@ xsi:schemaLocation="https://gitlab.freedesktop.org/freedreno/ rules-fd.xsd">
<reg32 offset="0x00028" name="CTRL_1"/>
<reg32 offset="0x0002c" name="CTRL_2"/>
<reg32 offset="0x00030" name="CTRL_3"/>
+ <reg32 offset="0x001b0" name="CTRL_5"/>
<reg32 offset="0x00034" name="LANE_CFG0"/>
<reg32 offset="0x00038" name="LANE_CFG1"/>
<reg32 offset="0x0003c" name="PLL_CNTRL"/>
@@ -191,11 +192,24 @@ xsi:schemaLocation="https://gitlab.freedesktop.org/freedreno/ rules-fd.xsd">
<reg32 offset="0x01b0" name="COMMON_STATUS_ONE"/>
<reg32 offset="0x01b4" name="COMMON_STATUS_TWO"/>
<reg32 offset="0x01b8" name="BAND_SEL_CAL"/>
+ <!--
+ Starting from SM8750, offset moved from 0x01bc to 0x01cc, however
+ we keep only one register map. That's not a problem, so far,
+ because this register is not used. The register map should be split
+ once it is going to be used. Comment out the code to prevent
+ any misuse due to the change in the offset.
<reg32 offset="0x01bc" name="ICODE_ACCUM_STATUS_LOW"/>
+ <reg32 offset="0x01cc" name="ICODE_ACCUM_STATUS_LOW"/>
+ -->
<reg32 offset="0x01c0" name="ICODE_ACCUM_STATUS_HIGH"/>
<reg32 offset="0x01c4" name="FD_OUT_LOW"/>
<reg32 offset="0x01c8" name="FD_OUT_HIGH"/>
+ <!--
+ Starting from SM8750, offset moved from 0x01cc to 0x01bc, however
+ we keep only one register map. See above comment.
<reg32 offset="0x01cc" name="ALOG_OBSV_BUS_STATUS_1"/>
+ <reg32 offset="0x01bc" name="ALOG_OBSV_BUS_STATUS_1"/>
+ -->
<reg32 offset="0x01d0" name="PLL_MISC_CONFIG"/>
<reg32 offset="0x01d4" name="FLL_CONFIG"/>
<reg32 offset="0x01d8" name="FLL_FREQ_ACQ_TIME"/>
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 11/16] drm/msm/dsi/phy: Add support for SM8750
2025-02-17 16:41 ` [PATCH v2 11/16] drm/msm/dsi/phy: Add support for SM8750 Krzysztof Kozlowski
@ 2025-02-17 19:03 ` Dmitry Baryshkov
2025-02-20 0:50 ` Jessica Zhang
1 sibling, 0 replies; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-17 19:03 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Mon, Feb 17, 2025 at 05:41:32PM +0100, Krzysztof Kozlowski wrote:
> Add support for DSI PHY v7.0 on Qualcomm SM8750 SoC which comes with an
> incompatible hardware interface change:
>
> ICODE_ACCUM_STATUS_LOW and ALOG_OBSV_BUS_STATUS_1 registers - their
> offsets were just switched. Currently these registers are not used in
> the driver, so the easiest is to document both but keep them commented
> out to avoid conflict.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>
> ---
>
> Changes in v2:
> 1.
:-)
> ---
> drivers/gpu/drm/msm/dsi/phy/dsi_phy.c | 2 +
> drivers/gpu/drm/msm/dsi/phy/dsi_phy.h | 1 +
> drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c | 79 ++++++++++++++++++++--
> .../gpu/drm/msm/registers/display/dsi_phy_7nm.xml | 14 ++++
> 4 files changed, 90 insertions(+), 6 deletions(-)
>
> @@ -191,11 +192,24 @@ xsi:schemaLocation="https://gitlab.freedesktop.org/freedreno/ rules-fd.xsd">
> <reg32 offset="0x01b0" name="COMMON_STATUS_ONE"/>
> <reg32 offset="0x01b4" name="COMMON_STATUS_TWO"/>
> <reg32 offset="0x01b8" name="BAND_SEL_CAL"/>
> + <!--
> + Starting from SM8750, offset moved from 0x01bc to 0x01cc, however
> + we keep only one register map. That's not a problem, so far,
> + because this register is not used. The register map should be split
> + once it is going to be used. Comment out the code to prevent
> + any misuse due to the change in the offset.
Mumbles a lot about the hardware design.
> <reg32 offset="0x01bc" name="ICODE_ACCUM_STATUS_LOW"/>
> + <reg32 offset="0x01cc" name="ICODE_ACCUM_STATUS_LOW"/>
> + -->
> <reg32 offset="0x01c0" name="ICODE_ACCUM_STATUS_HIGH"/>
> <reg32 offset="0x01c4" name="FD_OUT_LOW"/>
> <reg32 offset="0x01c8" name="FD_OUT_HIGH"/>
> + <!--
> + Starting from SM8750, offset moved from 0x01cc to 0x01bc, however
> + we keep only one register map. See above comment.
> <reg32 offset="0x01cc" name="ALOG_OBSV_BUS_STATUS_1"/>
> + <reg32 offset="0x01bc" name="ALOG_OBSV_BUS_STATUS_1"/>
> + -->
> <reg32 offset="0x01d0" name="PLL_MISC_CONFIG"/>
> <reg32 offset="0x01d4" name="FLL_CONFIG"/>
> <reg32 offset="0x01d8" name="FLL_FREQ_ACQ_TIME"/>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 11/16] drm/msm/dsi/phy: Add support for SM8750
2025-02-17 16:41 ` [PATCH v2 11/16] drm/msm/dsi/phy: Add support for SM8750 Krzysztof Kozlowski
2025-02-17 19:03 ` Dmitry Baryshkov
@ 2025-02-20 0:50 ` Jessica Zhang
2025-02-21 10:41 ` Krzysztof Kozlowski
1 sibling, 1 reply; 54+ messages in thread
From: Jessica Zhang @ 2025-02-20 0:50 UTC (permalink / raw)
To: Krzysztof Kozlowski, Rob Clark, Abhinav Kumar, Dmitry Baryshkov,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 2/17/2025 8:41 AM, Krzysztof Kozlowski wrote:
> Add support for DSI PHY v7.0 on Qualcomm SM8750 SoC which comes with an
> incompatible hardware interface change:
>
> ICODE_ACCUM_STATUS_LOW and ALOG_OBSV_BUS_STATUS_1 registers - their
> offsets were just switched. Currently these registers are not used in
> the driver, so the easiest is to document both but keep them commented
> out to avoid conflict.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>
> ---
>
> Changes in v2:
> 1.
> ---
> drivers/gpu/drm/msm/dsi/phy/dsi_phy.c | 2 +
> drivers/gpu/drm/msm/dsi/phy/dsi_phy.h | 1 +
> drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c | 79 ++++++++++++++++++++--
> .../gpu/drm/msm/registers/display/dsi_phy_7nm.xml | 14 ++++
> 4 files changed, 90 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c
> index c0bcc68289633fd7506ce4f1f963655d862e8f08..60571237efc4d332959ac76ff1d6d6245f688469 100644
> --- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c
> +++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c
> @@ -593,6 +593,8 @@ static const struct of_device_id dsi_phy_dt_match[] = {
> .data = &dsi_phy_4nm_8550_cfgs },
> { .compatible = "qcom,sm8650-dsi-phy-4nm",
> .data = &dsi_phy_4nm_8650_cfgs },
> + { .compatible = "qcom,sm8750-dsi-phy-3nm",
> + .data = &dsi_phy_3nm_8750_cfgs },
> #endif
> {}
> };
> diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h
> index 8985818bb2e0934e9084a420c90e2269c2e1c414..fdb6c648e16f25812a2948053f31186d4c0d4413 100644
> --- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h
> +++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h
> @@ -60,6 +60,7 @@ extern const struct msm_dsi_phy_cfg dsi_phy_5nm_8350_cfgs;
> extern const struct msm_dsi_phy_cfg dsi_phy_5nm_8450_cfgs;
> extern const struct msm_dsi_phy_cfg dsi_phy_4nm_8550_cfgs;
> extern const struct msm_dsi_phy_cfg dsi_phy_4nm_8650_cfgs;
> +extern const struct msm_dsi_phy_cfg dsi_phy_3nm_8750_cfgs;
>
> struct msm_dsi_dphy_timing {
> u32 clk_zero;
> diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c
> index 6d287cfb0148bdb0b1c64675dfe7fa69d3faba2d..b626989cb3d505f1c53f212dba130e3d685fe59c 100644
> --- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c
> +++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c
> @@ -50,6 +50,8 @@
> #define DSI_PHY_7NM_QUIRK_V4_3 BIT(3)
> /* Hardware is V5.2 */
> #define DSI_PHY_7NM_QUIRK_V5_2 BIT(4)
> +/* Hardware is V7.0 */
> +#define DSI_PHY_7NM_QUIRK_V7_0 BIT(5)
>
> struct dsi_pll_config {
> bool enable_ssc;
> @@ -128,9 +130,30 @@ static void dsi_pll_calc_dec_frac(struct dsi_pll_7nm *pll, struct dsi_pll_config
> dec_multiple = div_u64(pll_freq * multiplier, divider);
> dec = div_u64_rem(dec_multiple, multiplier, &frac);
>
> - if (pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_PRE_V4_1)
> + if (pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_PRE_V4_1) {
> config->pll_clock_inverters = 0x28;
> - else if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
> + } else if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
> + if (pll_freq < 163000000ULL)
> + config->pll_clock_inverters = 0xa0;
> + else if (pll_freq < 175000000ULL)
> + config->pll_clock_inverters = 0x20;
> + else if (pll_freq < 325000000ULL)
> + config->pll_clock_inverters = 0xa0;
> + else if (pll_freq < 350000000ULL)
> + config->pll_clock_inverters = 0x20;
> + else if (pll_freq < 650000000ULL)
> + config->pll_clock_inverters = 0xa0;
> + else if (pll_freq < 700000000ULL)
> + config->pll_clock_inverters = 0x20;
> + else if (pll_freq < 1300000000ULL)
> + config->pll_clock_inverters = 0xa0;
> + else if (pll_freq < 2500000000ULL)
> + config->pll_clock_inverters = 0x20;
> + else if (pll_freq < 4000000000ULL)
> + config->pll_clock_inverters = 0x00;
> + else
> + config->pll_clock_inverters = 0x40;
> + } else if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
> if (pll_freq <= 1300000000ULL)
> config->pll_clock_inverters = 0xa0;
> else if (pll_freq <= 2500000000ULL)
> @@ -249,7 +272,8 @@ static void dsi_pll_config_hzindep_reg(struct dsi_pll_7nm *pll)
> vco_config_1 = 0x01;
> }
>
> - if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
> + if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2) ||
> + (pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
> if (pll->vco_current_rate < 1557000000ULL)
> vco_config_1 = 0x08;
> else
> @@ -624,6 +648,7 @@ static int dsi_7nm_pll_restore_state(struct msm_dsi_phy *phy)
> static int dsi_7nm_set_usecase(struct msm_dsi_phy *phy)
> {
> struct dsi_pll_7nm *pll_7nm = to_pll_7nm(phy->vco_hw);
> + void __iomem *base = phy->base;
Hi Krzysztof,
I see that this line was only previously removed in a patch that was in
an older revision of your PHY_CMN_CLK_CFG[01] improvements series
("drm/msm/dsi/phy: Do not overwite PHY_CMN_CLK_CFG1 when choosing bitclk
source").
Did you mean for this patch/series to be dependent on that patch? If so,
can you make a note of that in the cover letter?
Thanks,
Jessica Zhang
> u32 data = 0x0; /* internal PLL */
>
> DBG("DSI PLL%d", pll_7nm->phy->id);
> @@ -633,6 +658,9 @@ static int dsi_7nm_set_usecase(struct msm_dsi_phy *phy)
> break;
> case MSM_DSI_PHY_MASTER:
> pll_7nm->slave = pll_7nm_list[(pll_7nm->phy->id + 1) % DSI_MAX];
> + /* v7.0: Enable ATB_EN0 and alternate clock output to external phy */
> + if (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)
> + writel(0x07, base + REG_DSI_7nm_PHY_CMN_CTRL_5);
> break;
> case MSM_DSI_PHY_SLAVE:
> data = 0x1; /* external PLL */
> @@ -914,7 +942,8 @@ static int dsi_7nm_phy_enable(struct msm_dsi_phy *phy,
>
> /* Request for REFGEN READY */
> if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V4_3) ||
> - (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
> + (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2) ||
> + (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
> writel(0x1, phy->base + REG_DSI_7nm_PHY_CMN_GLBL_DIGTOP_SPARE10);
> udelay(500);
> }
> @@ -948,7 +977,20 @@ static int dsi_7nm_phy_enable(struct msm_dsi_phy *phy,
> lane_ctrl0 = 0x1f;
> }
>
> - if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
> + if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
> + if (phy->cphy_mode) {
> + /* TODO: different for second phy */
> + vreg_ctrl_0 = 0x57;
> + vreg_ctrl_1 = 0x41;
> + glbl_rescode_top_ctrl = 0x3d;
> + glbl_rescode_bot_ctrl = 0x38;
> + } else {
> + vreg_ctrl_0 = 0x56;
> + vreg_ctrl_1 = 0x19;
> + glbl_rescode_top_ctrl = less_than_1500_mhz ? 0x3c : 0x03;
> + glbl_rescode_bot_ctrl = less_than_1500_mhz ? 0x38 : 0x3c;
> + }
> + } else if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
> if (phy->cphy_mode) {
> vreg_ctrl_0 = 0x45;
> vreg_ctrl_1 = 0x41;
> @@ -1010,6 +1052,7 @@ static int dsi_7nm_phy_enable(struct msm_dsi_phy *phy,
>
> /* program CMN_CTRL_4 for minor_ver 2 chipsets*/
> if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2) ||
> + (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0) ||
> (readl(base + REG_DSI_7nm_PHY_CMN_REVISION_ID0) & (0xf0)) == 0x20)
> writel(0x04, base + REG_DSI_7nm_PHY_CMN_CTRL_4);
>
> @@ -1124,7 +1167,8 @@ static void dsi_7nm_phy_disable(struct msm_dsi_phy *phy)
>
> /* Turn off REFGEN Vote */
> if ((phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V4_3) ||
> - (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
> + (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2) ||
> + (phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
> writel(0x0, base + REG_DSI_7nm_PHY_CMN_GLBL_DIGTOP_SPARE10);
> wmb();
> /* Delay to ensure HW removes vote before PHY shut down */
> @@ -1341,3 +1385,26 @@ const struct msm_dsi_phy_cfg dsi_phy_4nm_8650_cfgs = {
> .num_dsi_phy = 2,
> .quirks = DSI_PHY_7NM_QUIRK_V5_2,
> };
> +
> +const struct msm_dsi_phy_cfg dsi_phy_3nm_8750_cfgs = {
> + .has_phy_lane = true,
> + .regulator_data = dsi_phy_7nm_98000uA_regulators,
> + .num_regulators = ARRAY_SIZE(dsi_phy_7nm_98000uA_regulators),
> + .ops = {
> + .enable = dsi_7nm_phy_enable,
> + .disable = dsi_7nm_phy_disable,
> + .pll_init = dsi_pll_7nm_init,
> + .save_pll_state = dsi_7nm_pll_save_state,
> + .restore_pll_state = dsi_7nm_pll_restore_state,
> + .set_continuous_clock = dsi_7nm_set_continuous_clock,
> + },
> + .min_pll_rate = 600000000UL,
> +#ifdef CONFIG_64BIT
> + .max_pll_rate = 5000000000UL,
> +#else
> + .max_pll_rate = ULONG_MAX,
> +#endif
> + .io_start = { 0xae95000, 0xae97000 },
> + .num_dsi_phy = 2,
> + .quirks = DSI_PHY_7NM_QUIRK_V7_0,
> +};
> diff --git a/drivers/gpu/drm/msm/registers/display/dsi_phy_7nm.xml b/drivers/gpu/drm/msm/registers/display/dsi_phy_7nm.xml
> index d2c8c46bb04159da6e539bfe80a4b5dc9ffdf367..d62411961f5673e0a7a37b90cfc99962de83659e 100644
> --- a/drivers/gpu/drm/msm/registers/display/dsi_phy_7nm.xml
> +++ b/drivers/gpu/drm/msm/registers/display/dsi_phy_7nm.xml
> @@ -26,6 +26,7 @@ xsi:schemaLocation="https://gitlab.freedesktop.org/freedreno/ rules-fd.xsd">
> <reg32 offset="0x00028" name="CTRL_1"/>
> <reg32 offset="0x0002c" name="CTRL_2"/>
> <reg32 offset="0x00030" name="CTRL_3"/>
> + <reg32 offset="0x001b0" name="CTRL_5"/>
> <reg32 offset="0x00034" name="LANE_CFG0"/>
> <reg32 offset="0x00038" name="LANE_CFG1"/>
> <reg32 offset="0x0003c" name="PLL_CNTRL"/>
> @@ -191,11 +192,24 @@ xsi:schemaLocation="https://gitlab.freedesktop.org/freedreno/ rules-fd.xsd">
> <reg32 offset="0x01b0" name="COMMON_STATUS_ONE"/>
> <reg32 offset="0x01b4" name="COMMON_STATUS_TWO"/>
> <reg32 offset="0x01b8" name="BAND_SEL_CAL"/>
> + <!--
> + Starting from SM8750, offset moved from 0x01bc to 0x01cc, however
> + we keep only one register map. That's not a problem, so far,
> + because this register is not used. The register map should be split
> + once it is going to be used. Comment out the code to prevent
> + any misuse due to the change in the offset.
> <reg32 offset="0x01bc" name="ICODE_ACCUM_STATUS_LOW"/>
> + <reg32 offset="0x01cc" name="ICODE_ACCUM_STATUS_LOW"/>
> + -->
> <reg32 offset="0x01c0" name="ICODE_ACCUM_STATUS_HIGH"/>
> <reg32 offset="0x01c4" name="FD_OUT_LOW"/>
> <reg32 offset="0x01c8" name="FD_OUT_HIGH"/>
> + <!--
> + Starting from SM8750, offset moved from 0x01cc to 0x01bc, however
> + we keep only one register map. See above comment.
> <reg32 offset="0x01cc" name="ALOG_OBSV_BUS_STATUS_1"/>
> + <reg32 offset="0x01bc" name="ALOG_OBSV_BUS_STATUS_1"/>
> + -->
> <reg32 offset="0x01d0" name="PLL_MISC_CONFIG"/>
> <reg32 offset="0x01d4" name="FLL_CONFIG"/>
> <reg32 offset="0x01d8" name="FLL_FREQ_ACQ_TIME"/>
>
> --
> 2.43.0
>
^ permalink raw reply [flat|nested] 54+ messages in thread* Re: [PATCH v2 11/16] drm/msm/dsi/phy: Add support for SM8750
2025-02-20 0:50 ` Jessica Zhang
@ 2025-02-21 10:41 ` Krzysztof Kozlowski
2025-02-21 10:43 ` Krzysztof Kozlowski
0 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-21 10:41 UTC (permalink / raw)
To: Jessica Zhang, Rob Clark, Abhinav Kumar, Dmitry Baryshkov,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 20/02/2025 01:50, Jessica Zhang wrote:
>>
>> - if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
>> + if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2) ||
>> + (pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
>> if (pll->vco_current_rate < 1557000000ULL)
>> vco_config_1 = 0x08;
>> else
>> @@ -624,6 +648,7 @@ static int dsi_7nm_pll_restore_state(struct msm_dsi_phy *phy)
>> static int dsi_7nm_set_usecase(struct msm_dsi_phy *phy)
>> {
>> struct dsi_pll_7nm *pll_7nm = to_pll_7nm(phy->vco_hw);
>> + void __iomem *base = phy->base;
>
> Hi Krzysztof,
>
> I see that this line was only previously removed in a patch that was in
> an older revision of your PHY_CMN_CLK_CFG[01] improvements series
> ("drm/msm/dsi/phy: Do not overwite PHY_CMN_CLK_CFG1 when choosing bitclk
> source").
>
> Did you mean for this patch/series to be dependent on that patch? If so,
> can you make a note of that in the cover letter?
I indeed rebased on top of my previous set, assuming it will get merged
faster. I will mention this in cover letter.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 54+ messages in thread* Re: [PATCH v2 11/16] drm/msm/dsi/phy: Add support for SM8750
2025-02-21 10:41 ` Krzysztof Kozlowski
@ 2025-02-21 10:43 ` Krzysztof Kozlowski
0 siblings, 0 replies; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-21 10:43 UTC (permalink / raw)
To: Jessica Zhang, Rob Clark, Abhinav Kumar, Dmitry Baryshkov,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 21/02/2025 11:41, Krzysztof Kozlowski wrote:
> On 20/02/2025 01:50, Jessica Zhang wrote:
>>>
>>> - if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2)) {
>>> + if ((pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V5_2) ||
>>> + (pll->phy->cfg->quirks & DSI_PHY_7NM_QUIRK_V7_0)) {
>>> if (pll->vco_current_rate < 1557000000ULL)
>>> vco_config_1 = 0x08;
>>> else
>>> @@ -624,6 +648,7 @@ static int dsi_7nm_pll_restore_state(struct msm_dsi_phy *phy)
>>> static int dsi_7nm_set_usecase(struct msm_dsi_phy *phy)
>>> {
>>> struct dsi_pll_7nm *pll_7nm = to_pll_7nm(phy->vco_hw);
>>> + void __iomem *base = phy->base;
>>
>> Hi Krzysztof,
>>
>> I see that this line was only previously removed in a patch that was in
>> an older revision of your PHY_CMN_CLK_CFG[01] improvements series
>> ("drm/msm/dsi/phy: Do not overwite PHY_CMN_CLK_CFG1 when choosing bitclk
>> source").
>>
>> Did you mean for this patch/series to be dependent on that patch? If so,
>> can you make a note of that in the cover letter?
>
> I indeed rebased on top of my previous set, assuming it will get merged
> faster. I will mention this in cover letter.
Ha, not anymore, that "PHY_CMN_CLK_CFG[01]" pieces were already merged
to drm/msm.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 12/16] drm/msm/dsi: Add support for SM8750
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (10 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 11/16] drm/msm/dsi/phy: Add support for SM8750 Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-17 19:05 ` Dmitry Baryshkov
2025-02-17 16:41 ` [PATCH v2 13/16] drm/msm/dpu: " Krzysztof Kozlowski
` (4 subsequent siblings)
16 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Add support for DSI on Qualcomm SM8750 SoC with notable difference:
DSI PHY PLLs, the parents of pixel and byte clocks, cannot be used as
parents before DSI PHY is configured and the PLLs are prepared with
initial rate is set. Therefore assigned-clock-parents are not working
here and driver is responsible for reparenting clocks with proper
procedure: see dsi_clk_init_6g_v2_9().
Part of the change is exactly the same as CLK_OPS_PARENT_ENABLE, however
CLK_OPS_PARENT_ENABLE won't work here because assigned-clock-parents are
executed way too early - before DSI PHY is configured.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
SM8750 DSI PHY also needs Dmitry's patch:
https://patchwork.freedesktop.org/patch/542000/?series=119177&rev=1
(or some other way of correct early setting of the DSI PHY PLL rate)
---
drivers/gpu/drm/msm/dsi/dsi.h | 2 +
drivers/gpu/drm/msm/dsi/dsi_cfg.c | 25 ++++++++++++
drivers/gpu/drm/msm/dsi/dsi_cfg.h | 1 +
drivers/gpu/drm/msm/dsi/dsi_host.c | 80 ++++++++++++++++++++++++++++++++++++++
4 files changed, 108 insertions(+)
diff --git a/drivers/gpu/drm/msm/dsi/dsi.h b/drivers/gpu/drm/msm/dsi/dsi.h
index 87496db203d6c7582eadcb74e94eb56a219df292..93c028a122f3a59b1632da76472e0a3e781c6ae8 100644
--- a/drivers/gpu/drm/msm/dsi/dsi.h
+++ b/drivers/gpu/drm/msm/dsi/dsi.h
@@ -98,6 +98,7 @@ int msm_dsi_host_init(struct msm_dsi *msm_dsi);
int msm_dsi_runtime_suspend(struct device *dev);
int msm_dsi_runtime_resume(struct device *dev);
int dsi_link_clk_set_rate_6g(struct msm_dsi_host *msm_host);
+int dsi_link_clk_set_rate_6g_v2_9(struct msm_dsi_host *msm_host);
int dsi_link_clk_set_rate_v2(struct msm_dsi_host *msm_host);
int dsi_link_clk_enable_6g(struct msm_dsi_host *msm_host);
int dsi_link_clk_enable_v2(struct msm_dsi_host *msm_host);
@@ -115,6 +116,7 @@ int dsi_dma_base_get_6g(struct msm_dsi_host *msm_host, uint64_t *iova);
int dsi_dma_base_get_v2(struct msm_dsi_host *msm_host, uint64_t *iova);
int dsi_clk_init_v2(struct msm_dsi_host *msm_host);
int dsi_clk_init_6g_v2(struct msm_dsi_host *msm_host);
+int dsi_clk_init_6g_v2_9(struct msm_dsi_host *msm_host);
int dsi_calc_clk_rate_v2(struct msm_dsi_host *msm_host, bool is_bonded_dsi);
int dsi_calc_clk_rate_6g(struct msm_dsi_host *msm_host, bool is_bonded_dsi);
void msm_dsi_host_snapshot(struct msm_disp_state *disp_state, struct mipi_dsi_host *host);
diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.c b/drivers/gpu/drm/msm/dsi/dsi_cfg.c
index 7754dcec33d06e3d6eb8a9d55e53f24af073adb9..e2a8d6fcc45b6c207a3018ea7c8744fcf34dabd2 100644
--- a/drivers/gpu/drm/msm/dsi/dsi_cfg.c
+++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.c
@@ -205,6 +205,17 @@ static const struct msm_dsi_config sm8650_dsi_cfg = {
},
};
+static const struct msm_dsi_config sm8750_dsi_cfg = {
+ .io_offset = DSI_6G_REG_SHIFT,
+ .regulator_data = sm8650_dsi_regulators,
+ .num_regulators = ARRAY_SIZE(sm8650_dsi_regulators),
+ .bus_clk_names = dsi_v2_4_clk_names,
+ .num_bus_clks = ARRAY_SIZE(dsi_v2_4_clk_names),
+ .io_start = {
+ { 0xae94000, 0xae96000 },
+ },
+};
+
static const struct regulator_bulk_data sc7280_dsi_regulators[] = {
{ .supply = "vdda", .init_load_uA = 8350 }, /* 1.2 V */
{ .supply = "refgen" },
@@ -257,6 +268,18 @@ static const struct msm_dsi_host_cfg_ops msm_dsi_6g_v2_host_ops = {
.calc_clk_rate = dsi_calc_clk_rate_6g,
};
+static const struct msm_dsi_host_cfg_ops msm_dsi_6g_v2_9_host_ops = {
+ .link_clk_set_rate = dsi_link_clk_set_rate_6g_v2_9,
+ .link_clk_enable = dsi_link_clk_enable_6g,
+ .link_clk_disable = dsi_link_clk_disable_6g,
+ .clk_init_ver = dsi_clk_init_6g_v2_9,
+ .tx_buf_alloc = dsi_tx_buf_alloc_6g,
+ .tx_buf_get = dsi_tx_buf_get_6g,
+ .tx_buf_put = dsi_tx_buf_put_6g,
+ .dma_base_get = dsi_dma_base_get_6g,
+ .calc_clk_rate = dsi_calc_clk_rate_6g,
+};
+
static const struct msm_dsi_cfg_handler dsi_cfg_handlers[] = {
{MSM_DSI_VER_MAJOR_V2, MSM_DSI_V2_VER_MINOR_8064,
&apq8064_dsi_cfg, &msm_dsi_v2_host_ops},
@@ -300,6 +323,8 @@ static const struct msm_dsi_cfg_handler dsi_cfg_handlers[] = {
&sm8550_dsi_cfg, &msm_dsi_6g_v2_host_ops},
{MSM_DSI_VER_MAJOR_6G, MSM_DSI_6G_VER_MINOR_V2_8_0,
&sm8650_dsi_cfg, &msm_dsi_6g_v2_host_ops},
+ {MSM_DSI_VER_MAJOR_6G, MSM_DSI_6G_VER_MINOR_V2_9_0,
+ &sm8750_dsi_cfg, &msm_dsi_6g_v2_9_host_ops},
};
const struct msm_dsi_cfg_handler *msm_dsi_cfg_get(u32 major, u32 minor)
diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.h b/drivers/gpu/drm/msm/dsi/dsi_cfg.h
index 120cb65164c1ba1deb9acb513e5f073bd560c496..859c279afbb0377d16f8406f3e6b083640aff5a1 100644
--- a/drivers/gpu/drm/msm/dsi/dsi_cfg.h
+++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.h
@@ -30,6 +30,7 @@
#define MSM_DSI_6G_VER_MINOR_V2_6_0 0x20060000
#define MSM_DSI_6G_VER_MINOR_V2_7_0 0x20070000
#define MSM_DSI_6G_VER_MINOR_V2_8_0 0x20080000
+#define MSM_DSI_6G_VER_MINOR_V2_9_0 0x20090000
#define MSM_DSI_V2_VER_MINOR_8064 0x0
diff --git a/drivers/gpu/drm/msm/dsi/dsi_host.c b/drivers/gpu/drm/msm/dsi/dsi_host.c
index 2218d4f0c5130a0b13f428e89aa30ba2921da572..ced28ee61eedc0a82da9f1d0792f17ee2a5538c4 100644
--- a/drivers/gpu/drm/msm/dsi/dsi_host.c
+++ b/drivers/gpu/drm/msm/dsi/dsi_host.c
@@ -119,6 +119,15 @@ struct msm_dsi_host {
struct clk *pixel_clk;
struct clk *byte_intf_clk;
+ /*
+ * Clocks which needs to be properly parented between DISPCC and DSI PHY
+ * PLL:
+ */
+ struct clk *byte_src_clk;
+ struct clk *pixel_src_clk;
+ struct clk *dsi_pll_byte_clk;
+ struct clk *dsi_pll_pixel_clk;
+
unsigned long byte_clk_rate;
unsigned long byte_intf_clk_rate;
unsigned long pixel_clk_rate;
@@ -269,6 +278,38 @@ int dsi_clk_init_6g_v2(struct msm_dsi_host *msm_host)
return ret;
}
+int dsi_clk_init_6g_v2_9(struct msm_dsi_host *msm_host)
+{
+ struct device *dev = &msm_host->pdev->dev;
+ int ret;
+
+ ret = dsi_clk_init_6g_v2(msm_host);
+ if (ret)
+ return ret;
+
+ msm_host->byte_src_clk = devm_clk_get(dev, "byte_src");
+ if (IS_ERR(msm_host->byte_src_clk))
+ return dev_err_probe(dev, PTR_ERR(msm_host->byte_src_clk),
+ "can't get byte_src clock\n");
+
+ msm_host->dsi_pll_byte_clk = devm_clk_get(dev, "dsi_pll_byte");
+ if (IS_ERR(msm_host->dsi_pll_byte_clk))
+ return dev_err_probe(dev, PTR_ERR(msm_host->dsi_pll_byte_clk),
+ "can't get dsi_pll_byte clock\n");
+
+ msm_host->pixel_src_clk = devm_clk_get(dev, "pixel_src");
+ if (IS_ERR(msm_host->pixel_src_clk))
+ return dev_err_probe(dev, PTR_ERR(msm_host->pixel_src_clk),
+ "can't get pixel_src clock\n");
+
+ msm_host->dsi_pll_pixel_clk = devm_clk_get(dev, "dsi_pll_pixel");
+ if (IS_ERR(msm_host->dsi_pll_pixel_clk))
+ return dev_err_probe(dev, PTR_ERR(msm_host->dsi_pll_pixel_clk),
+ "can't get dsi_pll_pixel clock\n");
+
+ return 0;
+}
+
static int dsi_clk_init(struct msm_dsi_host *msm_host)
{
struct platform_device *pdev = msm_host->pdev;
@@ -370,6 +411,45 @@ int dsi_link_clk_set_rate_6g(struct msm_dsi_host *msm_host)
return 0;
}
+int dsi_link_clk_set_rate_6g_v2_9(struct msm_dsi_host *msm_host)
+{
+ struct device *dev = &msm_host->pdev->dev;
+ int ret;
+
+ /*
+ * DSI PHY PLLs have to be enabled to allow reparenting to them and
+ * setting the rates of pixel/byte clocks.
+ */
+ ret = clk_prepare_enable(msm_host->dsi_pll_byte_clk);
+ if (ret) {
+ dev_err(dev, "Failed to enable dsi_pll_byte: %d\n", ret);
+ return ret;
+ }
+
+ ret = clk_prepare_enable(msm_host->dsi_pll_pixel_clk);
+ if (ret) {
+ dev_err(dev, "Failed to enable dsi_pll_byte: %d\n", ret);
+ goto out_disable_byte_clk;
+ }
+
+ ret = clk_set_parent(msm_host->byte_src_clk, msm_host->dsi_pll_byte_clk);
+ if (ret)
+ dev_err(dev, "Failed to parent byte_src -> dsi_pll_byte: %d\n", ret);
+
+ ret = clk_set_parent(msm_host->pixel_src_clk, msm_host->dsi_pll_pixel_clk);
+ if (ret)
+ dev_err(dev, "Failed to parent pixel_src -> dsi_pll_pixel: %d\n", ret);
+
+ ret = dsi_link_clk_set_rate_6g(msm_host);
+
+ clk_disable_unprepare(msm_host->dsi_pll_pixel_clk);
+
+out_disable_byte_clk:
+ clk_disable_unprepare(msm_host->dsi_pll_byte_clk);
+
+ return ret;
+}
+
int dsi_link_clk_enable_6g(struct msm_dsi_host *msm_host)
{
int ret;
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 12/16] drm/msm/dsi: Add support for SM8750
2025-02-17 16:41 ` [PATCH v2 12/16] drm/msm/dsi: " Krzysztof Kozlowski
@ 2025-02-17 19:05 ` Dmitry Baryshkov
2025-02-21 11:14 ` Krzysztof Kozlowski
2025-02-21 11:14 ` Krzysztof Kozlowski
0 siblings, 2 replies; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-17 19:05 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Mon, Feb 17, 2025 at 05:41:33PM +0100, Krzysztof Kozlowski wrote:
> Add support for DSI on Qualcomm SM8750 SoC with notable difference:
>
> DSI PHY PLLs, the parents of pixel and byte clocks, cannot be used as
> parents before DSI PHY is configured and the PLLs are prepared with
> initial rate is set. Therefore assigned-clock-parents are not working
> here and driver is responsible for reparenting clocks with proper
> procedure: see dsi_clk_init_6g_v2_9().
>
> Part of the change is exactly the same as CLK_OPS_PARENT_ENABLE, however
> CLK_OPS_PARENT_ENABLE won't work here because assigned-clock-parents are
> executed way too early - before DSI PHY is configured.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>
> ---
>
> SM8750 DSI PHY also needs Dmitry's patch:
> https://patchwork.freedesktop.org/patch/542000/?series=119177&rev=1
> (or some other way of correct early setting of the DSI PHY PLL rate)
> ---
> drivers/gpu/drm/msm/dsi/dsi.h | 2 +
> drivers/gpu/drm/msm/dsi/dsi_cfg.c | 25 ++++++++++++
> drivers/gpu/drm/msm/dsi/dsi_cfg.h | 1 +
> drivers/gpu/drm/msm/dsi/dsi_host.c | 80 ++++++++++++++++++++++++++++++++++++++
> 4 files changed, 108 insertions(+)
>
> diff --git a/drivers/gpu/drm/msm/dsi/dsi.h b/drivers/gpu/drm/msm/dsi/dsi.h
> index 87496db203d6c7582eadcb74e94eb56a219df292..93c028a122f3a59b1632da76472e0a3e781c6ae8 100644
> --- a/drivers/gpu/drm/msm/dsi/dsi.h
> +++ b/drivers/gpu/drm/msm/dsi/dsi.h
> @@ -98,6 +98,7 @@ int msm_dsi_host_init(struct msm_dsi *msm_dsi);
> int msm_dsi_runtime_suspend(struct device *dev);
> int msm_dsi_runtime_resume(struct device *dev);
> int dsi_link_clk_set_rate_6g(struct msm_dsi_host *msm_host);
> +int dsi_link_clk_set_rate_6g_v2_9(struct msm_dsi_host *msm_host);
> int dsi_link_clk_set_rate_v2(struct msm_dsi_host *msm_host);
> int dsi_link_clk_enable_6g(struct msm_dsi_host *msm_host);
> int dsi_link_clk_enable_v2(struct msm_dsi_host *msm_host);
> @@ -115,6 +116,7 @@ int dsi_dma_base_get_6g(struct msm_dsi_host *msm_host, uint64_t *iova);
> int dsi_dma_base_get_v2(struct msm_dsi_host *msm_host, uint64_t *iova);
> int dsi_clk_init_v2(struct msm_dsi_host *msm_host);
> int dsi_clk_init_6g_v2(struct msm_dsi_host *msm_host);
> +int dsi_clk_init_6g_v2_9(struct msm_dsi_host *msm_host);
> int dsi_calc_clk_rate_v2(struct msm_dsi_host *msm_host, bool is_bonded_dsi);
> int dsi_calc_clk_rate_6g(struct msm_dsi_host *msm_host, bool is_bonded_dsi);
> void msm_dsi_host_snapshot(struct msm_disp_state *disp_state, struct mipi_dsi_host *host);
> diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.c b/drivers/gpu/drm/msm/dsi/dsi_cfg.c
> index 7754dcec33d06e3d6eb8a9d55e53f24af073adb9..e2a8d6fcc45b6c207a3018ea7c8744fcf34dabd2 100644
> --- a/drivers/gpu/drm/msm/dsi/dsi_cfg.c
> +++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.c
> @@ -205,6 +205,17 @@ static const struct msm_dsi_config sm8650_dsi_cfg = {
> },
> };
>
> +static const struct msm_dsi_config sm8750_dsi_cfg = {
Can we use sm8650_dsi_cfg instead? What is the difference?
> + .io_offset = DSI_6G_REG_SHIFT,
> + .regulator_data = sm8650_dsi_regulators,
> + .num_regulators = ARRAY_SIZE(sm8650_dsi_regulators),
> + .bus_clk_names = dsi_v2_4_clk_names,
> + .num_bus_clks = ARRAY_SIZE(dsi_v2_4_clk_names),
> + .io_start = {
> + { 0xae94000, 0xae96000 },
> + },
> +};
> +
The rest LGTM. I'm not very happy regarding the clock handling, but it
seems we jave to live with it.
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread* Re: [PATCH v2 12/16] drm/msm/dsi: Add support for SM8750
2025-02-17 19:05 ` Dmitry Baryshkov
@ 2025-02-21 11:14 ` Krzysztof Kozlowski
2025-02-21 11:14 ` Krzysztof Kozlowski
1 sibling, 0 replies; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-21 11:14 UTC (permalink / raw)
To: Dmitry Baryshkov
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 17/02/2025 20:05, Dmitry Baryshkov wrote:
> On Mon, Feb 17, 2025 at 05:41:33PM +0100, Krzysztof Kozlowski wrote:
>> Add support for DSI on Qualcomm SM8750 SoC with notable difference:
>>
>> DSI PHY PLLs, the parents of pixel and byte clocks, cannot be used as
>> parents before DSI PHY is configured and the PLLs are prepared with
>> initial rate is set. Therefore assigned-clock-parents are not working
>> here and driver is responsible for reparenting clocks with proper
>> procedure: see dsi_clk_init_6g_v2_9().
>>
>> Part of the change is exactly the same as CLK_OPS_PARENT_ENABLE, however
>> CLK_OPS_PARENT_ENABLE won't work here because assigned-clock-parents are
>> executed way too early - before DSI PHY is configured.
>>
>> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>>
>> ---
>>
>> SM8750 DSI PHY also needs Dmitry's patch:
>> https://patchwork.freedesktop.org/patch/542000/?series=119177&rev=1
>> (or some other way of correct early setting of the DSI PHY PLL rate)
>> ---
>> drivers/gpu/drm/msm/dsi/dsi.h | 2 +
>> drivers/gpu/drm/msm/dsi/dsi_cfg.c | 25 ++++++++++++
>> drivers/gpu/drm/msm/dsi/dsi_cfg.h | 1 +
>> drivers/gpu/drm/msm/dsi/dsi_host.c | 80 ++++++++++++++++++++++++++++++++++++++
>> 4 files changed, 108 insertions(+)
>>
>> diff --git a/drivers/gpu/drm/msm/dsi/dsi.h b/drivers/gpu/drm/msm/dsi/dsi.h
>> index 87496db203d6c7582eadcb74e94eb56a219df292..93c028a122f3a59b1632da76472e0a3e781c6ae8 100644
>> --- a/drivers/gpu/drm/msm/dsi/dsi.h
>> +++ b/drivers/gpu/drm/msm/dsi/dsi.h
>> @@ -98,6 +98,7 @@ int msm_dsi_host_init(struct msm_dsi *msm_dsi);
>> int msm_dsi_runtime_suspend(struct device *dev);
>> int msm_dsi_runtime_resume(struct device *dev);
>> int dsi_link_clk_set_rate_6g(struct msm_dsi_host *msm_host);
>> +int dsi_link_clk_set_rate_6g_v2_9(struct msm_dsi_host *msm_host);
>> int dsi_link_clk_set_rate_v2(struct msm_dsi_host *msm_host);
>> int dsi_link_clk_enable_6g(struct msm_dsi_host *msm_host);
>> int dsi_link_clk_enable_v2(struct msm_dsi_host *msm_host);
>> @@ -115,6 +116,7 @@ int dsi_dma_base_get_6g(struct msm_dsi_host *msm_host, uint64_t *iova);
>> int dsi_dma_base_get_v2(struct msm_dsi_host *msm_host, uint64_t *iova);
>> int dsi_clk_init_v2(struct msm_dsi_host *msm_host);
>> int dsi_clk_init_6g_v2(struct msm_dsi_host *msm_host);
>> +int dsi_clk_init_6g_v2_9(struct msm_dsi_host *msm_host);
>> int dsi_calc_clk_rate_v2(struct msm_dsi_host *msm_host, bool is_bonded_dsi);
>> int dsi_calc_clk_rate_6g(struct msm_dsi_host *msm_host, bool is_bonded_dsi);
>> void msm_dsi_host_snapshot(struct msm_disp_state *disp_state, struct mipi_dsi_host *host);
>> diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.c b/drivers/gpu/drm/msm/dsi/dsi_cfg.c
>> index 7754dcec33d06e3d6eb8a9d55e53f24af073adb9..e2a8d6fcc45b6c207a3018ea7c8744fcf34dabd2 100644
>> --- a/drivers/gpu/drm/msm/dsi/dsi_cfg.c
>> +++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.c
>> @@ -205,6 +205,17 @@ static const struct msm_dsi_config sm8650_dsi_cfg = {
>> },
>> };
>>
>> +static const struct msm_dsi_config sm8750_dsi_cfg = {
>
> Can we use sm8650_dsi_cfg instead? What is the difference?
Yeah, I'll changeit. I think I was looking at this even and could not
find differences.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 54+ messages in thread* Re: [PATCH v2 12/16] drm/msm/dsi: Add support for SM8750
2025-02-17 19:05 ` Dmitry Baryshkov
2025-02-21 11:14 ` Krzysztof Kozlowski
@ 2025-02-21 11:14 ` Krzysztof Kozlowski
1 sibling, 0 replies; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-21 11:14 UTC (permalink / raw)
To: Dmitry Baryshkov
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 17/02/2025 20:05, Dmitry Baryshkov wrote:
> On Mon, Feb 17, 2025 at 05:41:33PM +0100, Krzysztof Kozlowski wrote:
>> Add support for DSI on Qualcomm SM8750 SoC with notable difference:
>>
>> DSI PHY PLLs, the parents of pixel and byte clocks, cannot be used as
>> parents before DSI PHY is configured and the PLLs are prepared with
>> initial rate is set. Therefore assigned-clock-parents are not working
>> here and driver is responsible for reparenting clocks with proper
>> procedure: see dsi_clk_init_6g_v2_9().
>>
>> Part of the change is exactly the same as CLK_OPS_PARENT_ENABLE, however
>> CLK_OPS_PARENT_ENABLE won't work here because assigned-clock-parents are
>> executed way too early - before DSI PHY is configured.
>>
>> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>>
>> ---
>>
>> SM8750 DSI PHY also needs Dmitry's patch:
>> https://patchwork.freedesktop.org/patch/542000/?series=119177&rev=1
>> (or some other way of correct early setting of the DSI PHY PLL rate)
>> ---
>> drivers/gpu/drm/msm/dsi/dsi.h | 2 +
>> drivers/gpu/drm/msm/dsi/dsi_cfg.c | 25 ++++++++++++
>> drivers/gpu/drm/msm/dsi/dsi_cfg.h | 1 +
>> drivers/gpu/drm/msm/dsi/dsi_host.c | 80 ++++++++++++++++++++++++++++++++++++++
>> 4 files changed, 108 insertions(+)
>>
>> diff --git a/drivers/gpu/drm/msm/dsi/dsi.h b/drivers/gpu/drm/msm/dsi/dsi.h
>> index 87496db203d6c7582eadcb74e94eb56a219df292..93c028a122f3a59b1632da76472e0a3e781c6ae8 100644
>> --- a/drivers/gpu/drm/msm/dsi/dsi.h
>> +++ b/drivers/gpu/drm/msm/dsi/dsi.h
>> @@ -98,6 +98,7 @@ int msm_dsi_host_init(struct msm_dsi *msm_dsi);
>> int msm_dsi_runtime_suspend(struct device *dev);
>> int msm_dsi_runtime_resume(struct device *dev);
>> int dsi_link_clk_set_rate_6g(struct msm_dsi_host *msm_host);
>> +int dsi_link_clk_set_rate_6g_v2_9(struct msm_dsi_host *msm_host);
>> int dsi_link_clk_set_rate_v2(struct msm_dsi_host *msm_host);
>> int dsi_link_clk_enable_6g(struct msm_dsi_host *msm_host);
>> int dsi_link_clk_enable_v2(struct msm_dsi_host *msm_host);
>> @@ -115,6 +116,7 @@ int dsi_dma_base_get_6g(struct msm_dsi_host *msm_host, uint64_t *iova);
>> int dsi_dma_base_get_v2(struct msm_dsi_host *msm_host, uint64_t *iova);
>> int dsi_clk_init_v2(struct msm_dsi_host *msm_host);
>> int dsi_clk_init_6g_v2(struct msm_dsi_host *msm_host);
>> +int dsi_clk_init_6g_v2_9(struct msm_dsi_host *msm_host);
>> int dsi_calc_clk_rate_v2(struct msm_dsi_host *msm_host, bool is_bonded_dsi);
>> int dsi_calc_clk_rate_6g(struct msm_dsi_host *msm_host, bool is_bonded_dsi);
>> void msm_dsi_host_snapshot(struct msm_disp_state *disp_state, struct mipi_dsi_host *host);
>> diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.c b/drivers/gpu/drm/msm/dsi/dsi_cfg.c
>> index 7754dcec33d06e3d6eb8a9d55e53f24af073adb9..e2a8d6fcc45b6c207a3018ea7c8744fcf34dabd2 100644
>> --- a/drivers/gpu/drm/msm/dsi/dsi_cfg.c
>> +++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.c
>> @@ -205,6 +205,17 @@ static const struct msm_dsi_config sm8650_dsi_cfg = {
>> },
>> };
>>
>> +static const struct msm_dsi_config sm8750_dsi_cfg = {
>
> Can we use sm8650_dsi_cfg instead? What is the difference?
Yeah, I'll changeit. I think I was looking at this even and could not
find differences.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 13/16] drm/msm/dpu: Add support for SM8750
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (11 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 12/16] drm/msm/dsi: " Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-17 19:07 ` Dmitry Baryshkov
2025-02-17 16:41 ` [PATCH v2 14/16] drm/msm/dpu: Add missing "fetch" name to set_active_pipes() Krzysztof Kozlowski
` (3 subsequent siblings)
16 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Add DPU version v12.0 support for the Qualcomm SM8750 platform.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
Changes in v2:
1. Add CDM
---
.../drm/msm/disp/dpu1/catalog/dpu_12_0_sm8750.h | 496 +++++++++++++++++++++
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 29 ++
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h | 1 +
drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 1 +
4 files changed, 527 insertions(+)
diff --git a/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_12_0_sm8750.h b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_12_0_sm8750.h
new file mode 100644
index 0000000000000000000000000000000000000000..aa0f861d6661a65854e1978afcfcdcd342f2ce1c
--- /dev/null
+++ b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_12_0_sm8750.h
@@ -0,0 +1,496 @@
+/* SPDX-License-Identifier: GPL-2.0-only */
+/*
+ * Copyright (c) 2025 Linaro Limited
+ * Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
+ * Copyright (c) 2015-2018, 2020 The Linux Foundation. All rights reserved.
+ */
+
+#ifndef _DPU_12_0_SM8750_H
+#define _DPU_12_0_SM8750_H
+
+static const struct dpu_caps sm8750_dpu_caps = {
+ .max_mixer_width = DEFAULT_DPU_OUTPUT_LINE_WIDTH,
+ .max_mixer_blendstages = 0xb,
+ .has_src_split = true,
+ .has_dim_layer = true,
+ .has_idle_pc = true,
+ .has_3d_merge = true,
+ .max_linewidth = 8192,
+ .pixel_ram_size = DEFAULT_PIXEL_RAM_SIZE,
+};
+
+static const struct dpu_mdp_cfg sm8750_mdp = {
+ .name = "top_0",
+ .base = 0, .len = 0x494,
+ .clk_ctrls = {
+ [DPU_CLK_CTRL_REG_DMA] = { .reg_off = 0x2bc, .bit_off = 20 },
+ },
+};
+
+static const struct dpu_ctl_cfg sm8750_ctl[] = {
+ {
+ .name = "ctl_0", .id = CTL_0,
+ .base = 0x15000, .len = 0x1000,
+ .has_split_display = 1,
+ .intr_start = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 9),
+ }, {
+ .name = "ctl_1", .id = CTL_1,
+ .base = 0x16000, .len = 0x1000,
+ .has_split_display = 1,
+ .intr_start = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 10),
+ }, {
+ .name = "ctl_2", .id = CTL_2,
+ .base = 0x17000, .len = 0x1000,
+ .intr_start = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 11),
+ }, {
+ .name = "ctl_3", .id = CTL_3,
+ .base = 0x18000, .len = 0x1000,
+ .intr_start = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 12),
+ }, {
+ .name = "ctl_4", .id = CTL_4,
+ .base = 0x19000, .len = 0x1000,
+ .intr_start = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 13),
+ }, {
+ .name = "ctl_5", .id = CTL_5,
+ .base = 0x1a000, .len = 0x1000,
+ .intr_start = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 23),
+ },
+};
+
+static const struct dpu_sspp_cfg sm8750_sspp[] = {
+ {
+ .name = "sspp_0", .id = SSPP_VIG0,
+ .base = 0x4000, .len = 0x344,
+ .features = VIG_SDM845_MASK_SDMA,
+ .sblk = &dpu_vig_sblk_qseed3_3_4,
+ .xin_id = 0,
+ .type = SSPP_TYPE_VIG,
+ }, {
+ .name = "sspp_1", .id = SSPP_VIG1,
+ .base = 0x6000, .len = 0x344,
+ .features = VIG_SDM845_MASK_SDMA,
+ .sblk = &dpu_vig_sblk_qseed3_3_4,
+ .xin_id = 4,
+ .type = SSPP_TYPE_VIG,
+ }, {
+ .name = "sspp_2", .id = SSPP_VIG2,
+ .base = 0x8000, .len = 0x344,
+ .features = VIG_SDM845_MASK_SDMA,
+ .sblk = &dpu_vig_sblk_qseed3_3_4,
+ .xin_id = 8,
+ .type = SSPP_TYPE_VIG,
+ }, {
+ .name = "sspp_3", .id = SSPP_VIG3,
+ .base = 0xa000, .len = 0x344,
+ .features = VIG_SDM845_MASK_SDMA,
+ .sblk = &dpu_vig_sblk_qseed3_3_4,
+ .xin_id = 12,
+ .type = SSPP_TYPE_VIG,
+ }, {
+ .name = "sspp_8", .id = SSPP_DMA0,
+ .base = 0x24000, .len = 0x344,
+ .features = DMA_SDM845_MASK_SDMA,
+ .sblk = &dpu_dma_sblk,
+ .xin_id = 1,
+ .type = SSPP_TYPE_DMA,
+ }, {
+ .name = "sspp_9", .id = SSPP_DMA1,
+ .base = 0x26000, .len = 0x344,
+ .features = DMA_SDM845_MASK_SDMA,
+ .sblk = &dpu_dma_sblk,
+ .xin_id = 5,
+ .type = SSPP_TYPE_DMA,
+ }, {
+ .name = "sspp_10", .id = SSPP_DMA2,
+ .base = 0x28000, .len = 0x344,
+ .features = DMA_SDM845_MASK_SDMA,
+ .sblk = &dpu_dma_sblk,
+ .xin_id = 9,
+ .type = SSPP_TYPE_DMA,
+ }, {
+ .name = "sspp_11", .id = SSPP_DMA3,
+ .base = 0x2a000, .len = 0x344,
+ .features = DMA_SDM845_MASK_SDMA,
+ .sblk = &dpu_dma_sblk,
+ .xin_id = 13,
+ .type = SSPP_TYPE_DMA,
+ }, {
+ .name = "sspp_12", .id = SSPP_DMA4,
+ .base = 0x2c000, .len = 0x344,
+ .features = DMA_CURSOR_SDM845_MASK_SDMA,
+ .sblk = &dpu_dma_sblk,
+ .xin_id = 14,
+ .type = SSPP_TYPE_DMA,
+ }, {
+ .name = "sspp_13", .id = SSPP_DMA5,
+ .base = 0x2e000, .len = 0x344,
+ .features = DMA_CURSOR_SDM845_MASK_SDMA,
+ .sblk = &dpu_dma_sblk,
+ .xin_id = 15,
+ .type = SSPP_TYPE_DMA,
+ },
+};
+
+static const struct dpu_lm_cfg sm8750_lm[] = {
+ {
+ .name = "lm_0", .id = LM_0,
+ .base = 0x44000, .len = 0x400,
+ .sourcesplit = 1,
+ .sblk = &sm8750_lm_sblk,
+ .lm_pair = LM_1,
+ .pingpong = PINGPONG_0,
+ .dspp = DSPP_0,
+ }, {
+ .name = "lm_1", .id = LM_1,
+ .base = 0x45000, .len = 0x400,
+ .sourcesplit = 1,
+ .sblk = &sm8750_lm_sblk,
+ .lm_pair = LM_0,
+ .pingpong = PINGPONG_1,
+ .dspp = DSPP_1,
+ }, {
+ .name = "lm_2", .id = LM_2,
+ .base = 0x46000, .len = 0x400,
+ .sourcesplit = 1,
+ .sblk = &sm8750_lm_sblk,
+ .lm_pair = LM_3,
+ .pingpong = PINGPONG_2,
+ .dspp = DSPP_2,
+ }, {
+ .name = "lm_3", .id = LM_3,
+ .base = 0x47000, .len = 0x400,
+ .sourcesplit = 1,
+ .sblk = &sm8750_lm_sblk,
+ .lm_pair = LM_2,
+ .pingpong = PINGPONG_3,
+ .dspp = DSPP_3,
+ }, {
+ .name = "lm_4", .id = LM_4,
+ .base = 0x48000, .len = 0x400,
+ .sourcesplit = 1,
+ .sblk = &sm8750_lm_sblk,
+ .lm_pair = LM_5,
+ .pingpong = PINGPONG_4,
+ }, {
+ .name = "lm_5", .id = LM_5,
+ .base = 0x49000, .len = 0x400,
+ .sourcesplit = 1,
+ .sblk = &sm8750_lm_sblk,
+ .lm_pair = LM_4,
+ .pingpong = PINGPONG_5,
+ }, {
+ .name = "lm_6", .id = LM_6,
+ .base = 0x4a000, .len = 0x400,
+ .sourcesplit = 1,
+ .sblk = &sm8750_lm_sblk,
+ .lm_pair = LM_7,
+ .pingpong = PINGPONG_6,
+ }, {
+ .name = "lm_7", .id = LM_7,
+ .base = 0x4b000, .len = 0x400,
+ .sourcesplit = 1,
+ .sblk = &sm8750_lm_sblk,
+ .lm_pair = LM_6,
+ .pingpong = PINGPONG_7,
+ },
+};
+
+static const struct dpu_dspp_cfg sm8750_dspp[] = {
+ {
+ .name = "dspp_0", .id = DSPP_0,
+ .base = 0x54000, .len = 0x1800,
+ .sblk = &sm8750_dspp_sblk,
+ }, {
+ .name = "dspp_1", .id = DSPP_1,
+ .base = 0x56000, .len = 0x1800,
+ .sblk = &sm8750_dspp_sblk,
+ }, {
+ .name = "dspp_2", .id = DSPP_2,
+ .base = 0x58000, .len = 0x1800,
+ .sblk = &sm8750_dspp_sblk,
+ }, {
+ .name = "dspp_3", .id = DSPP_3,
+ .base = 0x5a000, .len = 0x1800,
+ .sblk = &sm8750_dspp_sblk,
+ },
+};
+
+static const struct dpu_pingpong_cfg sm8750_pp[] = {
+ {
+ .name = "pingpong_0", .id = PINGPONG_0,
+ .base = 0x69000, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_0,
+ .intr_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 8),
+ }, {
+ .name = "pingpong_1", .id = PINGPONG_1,
+ .base = 0x6a000, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_0,
+ .intr_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 9),
+ }, {
+ .name = "pingpong_2", .id = PINGPONG_2,
+ .base = 0x6b000, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_1,
+ .intr_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 10),
+ }, {
+ .name = "pingpong_3", .id = PINGPONG_3,
+ .base = 0x6c000, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_1,
+ .intr_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 11),
+ }, {
+ .name = "pingpong_4", .id = PINGPONG_4,
+ .base = 0x6d000, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_2,
+ .intr_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 30),
+ }, {
+ .name = "pingpong_5", .id = PINGPONG_5,
+ .base = 0x6e000, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_2,
+ .intr_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 31),
+ }, {
+ .name = "pingpong_6", .id = PINGPONG_6,
+ .base = 0x6f000, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_3,
+ .intr_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 20),
+ }, {
+ .name = "pingpong_7", .id = PINGPONG_7,
+ .base = 0x70000, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_3,
+ .intr_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 21),
+ }, {
+ .name = "pingpong_cwb_0", .id = PINGPONG_CWB_0,
+ .base = 0x66000, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_4,
+ }, {
+ .name = "pingpong_cwb_1", .id = PINGPONG_CWB_1,
+ .base = 0x66400, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_4,
+ }, {
+ .name = "pingpong_cwb_2", .id = PINGPONG_CWB_2,
+ .base = 0x7e000, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_5,
+ }, {
+ .name = "pingpong_cwb_3", .id = PINGPONG_CWB_3,
+ .base = 0x7e400, .len = 0,
+ .sblk = &sc7280_pp_sblk,
+ .merge_3d = MERGE_3D_5,
+ },
+};
+
+static const struct dpu_merge_3d_cfg sm8750_merge_3d[] = {
+ {
+ .name = "merge_3d_0", .id = MERGE_3D_0,
+ .base = 0x4e000, .len = 0x1c,
+ }, {
+ .name = "merge_3d_1", .id = MERGE_3D_1,
+ .base = 0x4f000, .len = 0x1c,
+ }, {
+ .name = "merge_3d_2", .id = MERGE_3D_2,
+ .base = 0x50000, .len = 0x1c,
+ }, {
+ .name = "merge_3d_3", .id = MERGE_3D_3,
+ .base = 0x51000, .len = 0x1c,
+ }, {
+ .name = "merge_3d_4", .id = MERGE_3D_4,
+ .base = 0x66700, .len = 0x1c,
+ }, {
+ .name = "merge_3d_5", .id = MERGE_3D_5,
+ .base = 0x7e700, .len = 0x1c,
+ },
+};
+
+/*
+ * NOTE: Each display compression engine (DCE) contains dual hard
+ * slice DSC encoders so both share same base address but with
+ * its own different sub block address.
+ */
+static const struct dpu_dsc_cfg sm8750_dsc[] = {
+ {
+ .name = "dce_0_0", .id = DSC_0,
+ .base = 0x80000, .len = 0x8,
+ .have_native_42x = 1,
+ .sblk = &sm8750_dsc_sblk_0,
+ }, {
+ .name = "dce_0_1", .id = DSC_1,
+ .base = 0x80000, .len = 0x8,
+ .have_native_42x = 1,
+ .sblk = &sm8750_dsc_sblk_1,
+ }, {
+ .name = "dce_1_0", .id = DSC_2,
+ .base = 0x81000, .len = 0x8,
+ .have_native_42x = 1,
+ .sblk = &sm8750_dsc_sblk_0,
+ }, {
+ .name = "dce_1_1", .id = DSC_3,
+ .base = 0x81000, .len = 0x8,
+ .have_native_42x = 1,
+ .sblk = &sm8750_dsc_sblk_1,
+ }, {
+ .name = "dce_2_0", .id = DSC_4,
+ .base = 0x82000, .len = 0x8,
+ .have_native_42x = 1,
+ .sblk = &sm8750_dsc_sblk_0,
+ }, {
+ .name = "dce_2_1", .id = DSC_5,
+ .base = 0x82000, .len = 0x8,
+ .have_native_42x = 1,
+ .sblk = &sm8750_dsc_sblk_1,
+ }, {
+ .name = "dce_3_0", .id = DSC_6,
+ .base = 0x83000, .len = 0x8,
+ .have_native_42x = 1,
+ .sblk = &sm8750_dsc_sblk_0,
+ }, {
+ .name = "dce_3_1", .id = DSC_7,
+ .base = 0x83000, .len = 0x8,
+ .have_native_42x = 1,
+ .sblk = &sm8750_dsc_sblk_1,
+ },
+};
+
+static const struct dpu_wb_cfg sm8750_wb[] = {
+ {
+ .name = "wb_2", .id = WB_2,
+ .base = 0x65000, .len = 0x2c8,
+ .features = WB_SDM845_MASK,
+ .format_list = wb2_formats_rgb,
+ .num_formats = ARRAY_SIZE(wb2_formats_rgb),
+ .xin_id = 6,
+ .vbif_idx = VBIF_RT,
+ .maxlinewidth = 4096,
+ .intr_wb_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 4),
+ },
+};
+
+static const struct dpu_cwb_cfg sm8750_cwb[] = {
+ {
+ .name = "cwb_0", .id = CWB_0,
+ .base = 0x66200, .len = 0x20,
+ },
+ {
+ .name = "cwb_1", .id = CWB_1,
+ .base = 0x66600, .len = 0x20,
+ },
+ {
+ .name = "cwb_2", .id = CWB_2,
+ .base = 0x7e200, .len = 0x20,
+ },
+ {
+ .name = "cwb_3", .id = CWB_3,
+ .base = 0x7e600, .len = 0x20,
+ },
+};
+
+static const struct dpu_intf_cfg sm8750_intf[] = {
+ {
+ .name = "intf_0", .id = INTF_0,
+ .base = 0x34000, .len = 0x4bc,
+ .type = INTF_DP,
+ .controller_id = MSM_DP_CONTROLLER_0,
+ .prog_fetch_lines_worst_case = 24,
+ .intr_underrun = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 24),
+ .intr_vsync = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 25),
+ }, {
+ .name = "intf_1", .id = INTF_1,
+ .base = 0x35000, .len = 0x4bc,
+ .type = INTF_DSI,
+ .controller_id = MSM_DSI_CONTROLLER_0,
+ .prog_fetch_lines_worst_case = 24,
+ .intr_underrun = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 26),
+ .intr_vsync = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 27),
+ .intr_tear_rd_ptr = DPU_IRQ_IDX(MDP_INTF1_TEAR_INTR, 2),
+ }, {
+ .name = "intf_2", .id = INTF_2,
+ .base = 0x36000, .len = 0x4bc,
+ .type = INTF_DSI,
+ .controller_id = MSM_DSI_CONTROLLER_1,
+ .prog_fetch_lines_worst_case = 24,
+ .intr_underrun = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 28),
+ .intr_vsync = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 29),
+ .intr_tear_rd_ptr = DPU_IRQ_IDX(MDP_INTF2_TEAR_INTR, 2),
+ }, {
+ .name = "intf_3", .id = INTF_3,
+ .base = 0x37000, .len = 0x4bc,
+ .type = INTF_DP,
+ .controller_id = MSM_DP_CONTROLLER_1,
+ .prog_fetch_lines_worst_case = 24,
+ .intr_underrun = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 30),
+ .intr_vsync = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 31),
+ },
+};
+
+static const struct dpu_perf_cfg sm8750_perf_data = {
+ .max_bw_low = 18900000,
+ .max_bw_high = 28500000,
+ .min_core_ib = 2500000,
+ .min_llcc_ib = 0,
+ .min_dram_ib = 800000,
+ .min_prefill_lines = 35,
+ .danger_lut_tbl = {0x3ffff, 0x3ffff, 0x0},
+ .safe_lut_tbl = {0xfe00, 0xfe00, 0xffff},
+ .qos_lut_tbl = {
+ {.nentry = ARRAY_SIZE(sc7180_qos_linear),
+ .entries = sc7180_qos_linear
+ },
+ {.nentry = ARRAY_SIZE(sc7180_qos_macrotile),
+ .entries = sc7180_qos_macrotile
+ },
+ {.nentry = ARRAY_SIZE(sc7180_qos_nrt),
+ .entries = sc7180_qos_nrt
+ },
+ /* TODO: macrotile-qseed is different from macrotile */
+ },
+ .cdp_cfg = {
+ {.rd_enable = 1, .wr_enable = 1},
+ {.rd_enable = 1, .wr_enable = 0}
+ },
+ .clk_inefficiency_factor = 105,
+ .bw_inefficiency_factor = 120,
+};
+
+static const struct dpu_mdss_version sm8750_mdss_ver = {
+ .core_major_ver = 12,
+ .core_minor_ver = 0,
+};
+
+const struct dpu_mdss_cfg dpu_sm8750_cfg = {
+ .mdss_ver = &sm8750_mdss_ver,
+ .caps = &sm8750_dpu_caps,
+ .mdp = &sm8750_mdp,
+ .cdm = &sc7280_cdm,
+ .ctl_count = ARRAY_SIZE(sm8750_ctl),
+ .ctl = sm8750_ctl,
+ .sspp_count = ARRAY_SIZE(sm8750_sspp),
+ .sspp = sm8750_sspp,
+ .mixer_count = ARRAY_SIZE(sm8750_lm),
+ .mixer = sm8750_lm,
+ .dspp_count = ARRAY_SIZE(sm8750_dspp),
+ .dspp = sm8750_dspp,
+ .pingpong_count = ARRAY_SIZE(sm8750_pp),
+ .pingpong = sm8750_pp,
+ .dsc_count = ARRAY_SIZE(sm8750_dsc),
+ .dsc = sm8750_dsc,
+ .merge_3d_count = ARRAY_SIZE(sm8750_merge_3d),
+ .merge_3d = sm8750_merge_3d,
+ .wb_count = ARRAY_SIZE(sm8750_wb),
+ .wb = sm8750_wb,
+ .cwb_count = ARRAY_SIZE(sm8750_cwb),
+ .cwb = sm8650_cwb,
+ .intf_count = ARRAY_SIZE(sm8750_intf),
+ .intf = sm8750_intf,
+ .vbif_count = ARRAY_SIZE(sm8650_vbif),
+ .vbif = sm8650_vbif,
+ .perf = &sm8750_perf_data,
+};
+
+#endif
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
index 4ff29be965c39b29cf7e3b9761634b7f39ca97b0..a0559f63d602e6081b53c209ccd74ccdf1a4b38d 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
@@ -354,6 +354,9 @@ static const struct dpu_sspp_sub_blks dpu_vig_sblk_qseed3_3_2 =
static const struct dpu_sspp_sub_blks dpu_vig_sblk_qseed3_3_3 =
_VIG_SBLK(SSPP_SCALER_VER(3, 3));
+static const struct dpu_sspp_sub_blks dpu_vig_sblk_qseed3_3_4 =
+ _VIG_SBLK(SSPP_SCALER_VER(3, 4));
+
static const struct dpu_sspp_sub_blks dpu_rgb_sblk = _RGB_SBLK();
static const struct dpu_sspp_sub_blks dpu_dma_sblk = _DMA_SBLK();
@@ -388,6 +391,16 @@ static const struct dpu_lm_sub_blks sc7180_lm_sblk = {
},
};
+static const struct dpu_lm_sub_blks sm8750_lm_sblk = {
+ .maxwidth = DEFAULT_DPU_OUTPUT_LINE_WIDTH,
+ .maxblendstages = 11, /* excluding base layer */
+ .blendstage_base = { /* offsets relative to mixer base */
+ /* 0x40 + n*0x30 */
+ 0x40, 0x70, 0xa0, 0xd0, 0x100, 0x130, 0x160, 0x190, 0x1c0,
+ 0x1f0, 0x220
+ },
+};
+
static const struct dpu_lm_sub_blks qcm2290_lm_sblk = {
.maxwidth = DEFAULT_DPU_LINE_WIDTH,
.maxblendstages = 4, /* excluding base layer */
@@ -409,6 +422,11 @@ static const struct dpu_dspp_sub_blks sdm845_dspp_sblk = {
.len = 0x90, .version = 0x40000},
};
+static const struct dpu_dspp_sub_blks sm8750_dspp_sblk = {
+ .pcc = {.name = "pcc", .base = 0x1700,
+ .len = 0x90, .version = 0x60000},
+};
+
/*************************************************************
* PINGPONG sub blocks config
*************************************************************/
@@ -451,6 +469,16 @@ static const struct dpu_dsc_sub_blks dsc_sblk_1 = {
.ctl = {.name = "ctl", .base = 0xF80, .len = 0x10},
};
+static const struct dpu_dsc_sub_blks sm8750_dsc_sblk_0 = {
+ .enc = {.name = "enc", .base = 0x100, .len = 0x100},
+ .ctl = {.name = "ctl", .base = 0xF00, .len = 0x24},
+};
+
+static const struct dpu_dsc_sub_blks sm8750_dsc_sblk_1 = {
+ .enc = {.name = "enc", .base = 0x200, .len = 0x100},
+ .ctl = {.name = "ctl", .base = 0xF80, .len = 0x24},
+};
+
/*************************************************************
* CDM block config
*************************************************************/
@@ -734,3 +762,4 @@ static const struct dpu_qos_lut_entry sc7180_qos_nrt[] = {
#include "catalog/dpu_9_2_x1e80100.h"
#include "catalog/dpu_10_0_sm8650.h"
+#include "catalog/dpu_12_0_sm8750.h"
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h
index f5ce35cd966459f0edf2dbdd2dbc2693779fac73..de124b722340e98dc78999af1e0ff50bd65a53c2 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h
@@ -749,6 +749,7 @@ extern const struct dpu_mdss_cfg dpu_sm8450_cfg;
extern const struct dpu_mdss_cfg dpu_sa8775p_cfg;
extern const struct dpu_mdss_cfg dpu_sm8550_cfg;
extern const struct dpu_mdss_cfg dpu_sm8650_cfg;
+extern const struct dpu_mdss_cfg dpu_sm8750_cfg;
extern const struct dpu_mdss_cfg dpu_x1e80100_cfg;
#endif /* _DPU_HW_CATALOG_H */
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c
index 1112f69dde87c95c34c3b76c78452954e7a20612..013e1eca74c8f0d6328d3064e3a9275b1a2aacb9 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c
@@ -1515,6 +1515,7 @@ static const struct of_device_id dpu_dt_match[] = {
{ .compatible = "qcom,sm8450-dpu", .data = &dpu_sm8450_cfg, },
{ .compatible = "qcom,sm8550-dpu", .data = &dpu_sm8550_cfg, },
{ .compatible = "qcom,sm8650-dpu", .data = &dpu_sm8650_cfg, },
+ { .compatible = "qcom,sm8750-dpu", .data = &dpu_sm8750_cfg, },
{ .compatible = "qcom,x1e80100-dpu", .data = &dpu_x1e80100_cfg, },
{}
};
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 13/16] drm/msm/dpu: Add support for SM8750
2025-02-17 16:41 ` [PATCH v2 13/16] drm/msm/dpu: " Krzysztof Kozlowski
@ 2025-02-17 19:07 ` Dmitry Baryshkov
0 siblings, 0 replies; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-17 19:07 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Mon, Feb 17, 2025 at 05:41:34PM +0100, Krzysztof Kozlowski wrote:
> Add DPU version v12.0 support for the Qualcomm SM8750 platform.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>
> ---
>
> Changes in v2:
> 1. Add CDM
> ---
> .../drm/msm/disp/dpu1/catalog/dpu_12_0_sm8750.h | 496 +++++++++++++++++++++
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 29 ++
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h | 1 +
> drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 1 +
> 4 files changed, 527 insertions(+)
>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 14/16] drm/msm/dpu: Add missing "fetch" name to set_active_pipes()
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (12 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 13/16] drm/msm/dpu: " Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-17 19:08 ` Dmitry Baryshkov
2025-02-20 22:52 ` Jessica Zhang
2025-02-17 16:41 ` [PATCH v2 15/16] drm/msm/dpu: Implement new v12.0 DPU differences Krzysztof Kozlowski
` (2 subsequent siblings)
16 siblings, 2 replies; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
The set_active_pipes() callback configures CTL_FETCH_PIPE_ACTIVE and
newer DPU v12.0 comes with CTL_PIPE_ACTIVE, thus rename it to
set_active_fetch_pipes() to better match the purpose.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
Changes in v2:
1. New patch
---
drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 12 ++++++------
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c | 6 +++---
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h | 2 +-
3 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c
index 7191b1a6d41b3a96f956d199398f12b2923e8c82..7de79696a21e58a4c640f00265610ccce8b5d253 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c
@@ -445,9 +445,9 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
uint32_t lm_idx;
bool bg_alpha_enable = false;
- DECLARE_BITMAP(fetch_active, SSPP_MAX);
+ DECLARE_BITMAP(active_fetch, SSPP_MAX);
- memset(fetch_active, 0, sizeof(fetch_active));
+ memset(active_fetch, 0, sizeof(active_fetch));
drm_atomic_crtc_for_each_plane(plane, crtc) {
state = plane->state;
if (!state)
@@ -464,7 +464,7 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
if (pstate->stage == DPU_STAGE_BASE && format->alpha_enable)
bg_alpha_enable = true;
- set_bit(pstate->pipe.sspp->idx, fetch_active);
+ set_bit(pstate->pipe.sspp->idx, active_fetch);
_dpu_crtc_blend_setup_pipe(crtc, plane,
mixer, cstate->num_mixers,
pstate->stage,
@@ -472,7 +472,7 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
&pstate->pipe, 0, stage_cfg);
if (pstate->r_pipe.sspp) {
- set_bit(pstate->r_pipe.sspp->idx, fetch_active);
+ set_bit(pstate->r_pipe.sspp->idx, active_fetch);
_dpu_crtc_blend_setup_pipe(crtc, plane,
mixer, cstate->num_mixers,
pstate->stage,
@@ -492,8 +492,8 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
}
}
- if (ctl->ops.set_active_pipes)
- ctl->ops.set_active_pipes(ctl, fetch_active);
+ if (ctl->ops.set_active_fetch_pipes)
+ ctl->ops.set_active_fetch_pipes(ctl, active_fetch);
_dpu_crtc_program_lm_output_roi(crtc);
}
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
index 9d4866509e97c262006e15cf3e02a2f1ca851784..2e1e22589f730d1a60c3cbf6ad6b6aeaea38c6fb 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
@@ -675,8 +675,8 @@ static void dpu_hw_ctl_reset_intf_cfg_v1(struct dpu_hw_ctl *ctx,
}
}
-static void dpu_hw_ctl_set_fetch_pipe_active(struct dpu_hw_ctl *ctx,
- unsigned long *fetch_active)
+static void dpu_hw_ctl_set_active_fetch_pipes(struct dpu_hw_ctl *ctx,
+ unsigned long *fetch_active)
{
int i;
u32 val = 0;
@@ -764,7 +764,7 @@ struct dpu_hw_ctl *dpu_hw_ctl_init(struct drm_device *dev,
c->ops.update_pending_flush_dspp = dpu_hw_ctl_update_pending_flush_dspp;
if (mdss_ver->core_major_ver >= 7)
- c->ops.set_active_pipes = dpu_hw_ctl_set_fetch_pipe_active;
+ c->ops.set_active_fetch_pipes = dpu_hw_ctl_set_active_fetch_pipes;
c->idx = cfg->id;
c->mixer_count = mixer_count;
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h
index f04ae0b1d986fa8f73e5bf96babfca3b4f3a0bf5..b8bd5b22c5f8dadd01c16c352efef4063f2614a6 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h
@@ -243,7 +243,7 @@ struct dpu_hw_ctl_ops {
void (*setup_blendstage)(struct dpu_hw_ctl *ctx,
enum dpu_lm lm, struct dpu_hw_stage_cfg *cfg);
- void (*set_active_pipes)(struct dpu_hw_ctl *ctx,
+ void (*set_active_fetch_pipes)(struct dpu_hw_ctl *ctx,
unsigned long *fetch_active);
};
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 14/16] drm/msm/dpu: Add missing "fetch" name to set_active_pipes()
2025-02-17 16:41 ` [PATCH v2 14/16] drm/msm/dpu: Add missing "fetch" name to set_active_pipes() Krzysztof Kozlowski
@ 2025-02-17 19:08 ` Dmitry Baryshkov
2025-02-20 22:52 ` Jessica Zhang
1 sibling, 0 replies; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-17 19:08 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Mon, Feb 17, 2025 at 05:41:35PM +0100, Krzysztof Kozlowski wrote:
> The set_active_pipes() callback configures CTL_FETCH_PIPE_ACTIVE and
> newer DPU v12.0 comes with CTL_PIPE_ACTIVE, thus rename it to
> set_active_fetch_pipes() to better match the purpose.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>
> ---
>
> Changes in v2:
> 1. New patch
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 12 ++++++------
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c | 6 +++---
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h | 2 +-
> 3 files changed, 10 insertions(+), 10 deletions(-)
>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 14/16] drm/msm/dpu: Add missing "fetch" name to set_active_pipes()
2025-02-17 16:41 ` [PATCH v2 14/16] drm/msm/dpu: Add missing "fetch" name to set_active_pipes() Krzysztof Kozlowski
2025-02-17 19:08 ` Dmitry Baryshkov
@ 2025-02-20 22:52 ` Jessica Zhang
1 sibling, 0 replies; 54+ messages in thread
From: Jessica Zhang @ 2025-02-20 22:52 UTC (permalink / raw)
To: Krzysztof Kozlowski, Rob Clark, Abhinav Kumar, Dmitry Baryshkov,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 2/17/2025 8:41 AM, Krzysztof Kozlowski wrote:
> The set_active_pipes() callback configures CTL_FETCH_PIPE_ACTIVE and
> newer DPU v12.0 comes with CTL_PIPE_ACTIVE, thus rename it to
> set_active_fetch_pipes() to better match the purpose.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Reviewed-by: Jessica Zhang <quic_jesszhan@quicinc.com>
>
> ---
>
> Changes in v2:
> 1. New patch
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 12 ++++++------
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c | 6 +++---
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h | 2 +-
> 3 files changed, 10 insertions(+), 10 deletions(-)
>
> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c
> index 7191b1a6d41b3a96f956d199398f12b2923e8c82..7de79696a21e58a4c640f00265610ccce8b5d253 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c
> @@ -445,9 +445,9 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
>
> uint32_t lm_idx;
> bool bg_alpha_enable = false;
> - DECLARE_BITMAP(fetch_active, SSPP_MAX);
> + DECLARE_BITMAP(active_fetch, SSPP_MAX);
>
> - memset(fetch_active, 0, sizeof(fetch_active));
> + memset(active_fetch, 0, sizeof(active_fetch));
> drm_atomic_crtc_for_each_plane(plane, crtc) {
> state = plane->state;
> if (!state)
> @@ -464,7 +464,7 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
> if (pstate->stage == DPU_STAGE_BASE && format->alpha_enable)
> bg_alpha_enable = true;
>
> - set_bit(pstate->pipe.sspp->idx, fetch_active);
> + set_bit(pstate->pipe.sspp->idx, active_fetch);
> _dpu_crtc_blend_setup_pipe(crtc, plane,
> mixer, cstate->num_mixers,
> pstate->stage,
> @@ -472,7 +472,7 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
> &pstate->pipe, 0, stage_cfg);
>
> if (pstate->r_pipe.sspp) {
> - set_bit(pstate->r_pipe.sspp->idx, fetch_active);
> + set_bit(pstate->r_pipe.sspp->idx, active_fetch);
> _dpu_crtc_blend_setup_pipe(crtc, plane,
> mixer, cstate->num_mixers,
> pstate->stage,
> @@ -492,8 +492,8 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
> }
> }
>
> - if (ctl->ops.set_active_pipes)
> - ctl->ops.set_active_pipes(ctl, fetch_active);
> + if (ctl->ops.set_active_fetch_pipes)
> + ctl->ops.set_active_fetch_pipes(ctl, active_fetch);
>
> _dpu_crtc_program_lm_output_roi(crtc);
> }
> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
> index 9d4866509e97c262006e15cf3e02a2f1ca851784..2e1e22589f730d1a60c3cbf6ad6b6aeaea38c6fb 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
> @@ -675,8 +675,8 @@ static void dpu_hw_ctl_reset_intf_cfg_v1(struct dpu_hw_ctl *ctx,
> }
> }
>
> -static void dpu_hw_ctl_set_fetch_pipe_active(struct dpu_hw_ctl *ctx,
> - unsigned long *fetch_active)
> +static void dpu_hw_ctl_set_active_fetch_pipes(struct dpu_hw_ctl *ctx,
> + unsigned long *fetch_active)
> {
> int i;
> u32 val = 0;
> @@ -764,7 +764,7 @@ struct dpu_hw_ctl *dpu_hw_ctl_init(struct drm_device *dev,
> c->ops.update_pending_flush_dspp = dpu_hw_ctl_update_pending_flush_dspp;
>
> if (mdss_ver->core_major_ver >= 7)
> - c->ops.set_active_pipes = dpu_hw_ctl_set_fetch_pipe_active;
> + c->ops.set_active_fetch_pipes = dpu_hw_ctl_set_active_fetch_pipes;
>
> c->idx = cfg->id;
> c->mixer_count = mixer_count;
> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h
> index f04ae0b1d986fa8f73e5bf96babfca3b4f3a0bf5..b8bd5b22c5f8dadd01c16c352efef4063f2614a6 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h
> @@ -243,7 +243,7 @@ struct dpu_hw_ctl_ops {
> void (*setup_blendstage)(struct dpu_hw_ctl *ctx,
> enum dpu_lm lm, struct dpu_hw_stage_cfg *cfg);
>
> - void (*set_active_pipes)(struct dpu_hw_ctl *ctx,
> + void (*set_active_fetch_pipes)(struct dpu_hw_ctl *ctx,
> unsigned long *fetch_active);
> };
>
>
> --
> 2.43.0
>
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 15/16] drm/msm/dpu: Implement new v12.0 DPU differences
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (13 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 14/16] drm/msm/dpu: Add missing "fetch" name to set_active_pipes() Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-17 19:18 ` Dmitry Baryshkov
2025-02-17 16:41 ` [PATCH v2 16/16] drm/msm/mdss: Add support for SM8750 Krzysztof Kozlowski
2025-02-19 21:17 ` [PATCH v2 00/16] drm/msm: " Jessica Zhang
16 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Implement new features and differences coming in v12.0 of DPU present on
Qualcomm SM8750 SoC:
1. 10-bit color alpha.
2. New CTL_PIPE_ACTIVE and CTL_LAYER_ACTIVE registers for pipes and
layer mixers.
2. Several differences in LM registers (also changed offsets) for LM
crossbar hardware changes.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
Changes in v2:
1. New patch
---
drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 49 +++++--
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 12 ++
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c | 59 +++++++-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h | 17 +++
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c | 210 +++++++++++++++++++++++++++-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.h | 18 +++
6 files changed, 350 insertions(+), 15 deletions(-)
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c
index 7de79696a21e58a4c640f00265610ccce8b5d253..ecb52a0eec8d5a5e91ab6305046dd1adddd77cf0 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c
@@ -319,15 +319,21 @@ static bool dpu_crtc_get_scanout_position(struct drm_crtc *crtc,
return true;
}
-static void _dpu_crtc_setup_blend_cfg(struct dpu_crtc_mixer *mixer,
- struct dpu_plane_state *pstate, const struct msm_format *format)
+static void _dpu_crtc_setup_blend_cfg(const struct dpu_hw_ctl *ctl,
+ struct dpu_crtc_mixer *mixer,
+ struct dpu_plane_state *pstate,
+ const struct msm_format *format)
{
struct dpu_hw_mixer *lm = mixer->hw_lm;
uint32_t blend_op;
- uint32_t fg_alpha, bg_alpha;
+ uint32_t fg_alpha, bg_alpha, max_alpha;
fg_alpha = pstate->base.alpha >> 8;
- bg_alpha = 0xff - fg_alpha;
+ if (ctl->mdss_ver->core_major_ver < 12)
+ max_alpha = 0xff;
+ else
+ max_alpha = 0x3ff;
+ bg_alpha = max_alpha - fg_alpha;
/* default to opaque blending */
if (pstate->base.pixel_blend_mode == DRM_MODE_BLEND_PIXEL_NONE ||
@@ -337,7 +343,7 @@ static void _dpu_crtc_setup_blend_cfg(struct dpu_crtc_mixer *mixer,
} else if (pstate->base.pixel_blend_mode == DRM_MODE_BLEND_PREMULTI) {
blend_op = DPU_BLEND_FG_ALPHA_FG_CONST |
DPU_BLEND_BG_ALPHA_FG_PIXEL;
- if (fg_alpha != 0xff) {
+ if (fg_alpha != max_alpha) {
bg_alpha = fg_alpha;
blend_op |= DPU_BLEND_BG_MOD_ALPHA |
DPU_BLEND_BG_INV_MOD_ALPHA;
@@ -348,7 +354,7 @@ static void _dpu_crtc_setup_blend_cfg(struct dpu_crtc_mixer *mixer,
/* coverage blending */
blend_op = DPU_BLEND_FG_ALPHA_FG_PIXEL |
DPU_BLEND_BG_ALPHA_FG_PIXEL;
- if (fg_alpha != 0xff) {
+ if (fg_alpha != max_alpha) {
bg_alpha = fg_alpha;
blend_op |= DPU_BLEND_FG_MOD_ALPHA |
DPU_BLEND_FG_INV_MOD_ALPHA |
@@ -446,8 +452,10 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
uint32_t lm_idx;
bool bg_alpha_enable = false;
DECLARE_BITMAP(active_fetch, SSPP_MAX);
+ DECLARE_BITMAP(active_pipes, SSPP_MAX);
memset(active_fetch, 0, sizeof(active_fetch));
+ memset(active_pipes, 0, sizeof(active_pipes));
drm_atomic_crtc_for_each_plane(plane, crtc) {
state = plane->state;
if (!state)
@@ -465,6 +473,7 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
bg_alpha_enable = true;
set_bit(pstate->pipe.sspp->idx, active_fetch);
+ set_bit(pstate->pipe.sspp->idx, active_pipes);
_dpu_crtc_blend_setup_pipe(crtc, plane,
mixer, cstate->num_mixers,
pstate->stage,
@@ -473,6 +482,7 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
if (pstate->r_pipe.sspp) {
set_bit(pstate->r_pipe.sspp->idx, active_fetch);
+ set_bit(pstate->r_pipe.sspp->idx, active_pipes);
_dpu_crtc_blend_setup_pipe(crtc, plane,
mixer, cstate->num_mixers,
pstate->stage,
@@ -482,7 +492,7 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
/* blend config update */
for (lm_idx = 0; lm_idx < cstate->num_mixers; lm_idx++) {
- _dpu_crtc_setup_blend_cfg(mixer + lm_idx, pstate, format);
+ _dpu_crtc_setup_blend_cfg(ctl, mixer + lm_idx, pstate, format);
if (bg_alpha_enable && !format->alpha_enable)
mixer[lm_idx].mixer_op_mode = 0;
@@ -495,6 +505,9 @@ static void _dpu_crtc_blend_setup_mixer(struct drm_crtc *crtc,
if (ctl->ops.set_active_fetch_pipes)
ctl->ops.set_active_fetch_pipes(ctl, active_fetch);
+ if (ctl->ops.set_active_pipes)
+ ctl->ops.set_active_pipes(ctl, active_pipes);
+
_dpu_crtc_program_lm_output_roi(crtc);
}
@@ -510,6 +523,7 @@ static void _dpu_crtc_blend_setup(struct drm_crtc *crtc)
struct dpu_hw_ctl *ctl;
struct dpu_hw_mixer *lm;
struct dpu_hw_stage_cfg stage_cfg;
+ DECLARE_BITMAP(active_lms, LM_MAX);
int i;
DRM_DEBUG_ATOMIC("%s\n", dpu_crtc->name);
@@ -519,10 +533,18 @@ static void _dpu_crtc_blend_setup(struct drm_crtc *crtc)
if (mixer[i].lm_ctl->ops.clear_all_blendstages)
mixer[i].lm_ctl->ops.clear_all_blendstages(
mixer[i].lm_ctl);
+ if (mixer[i].lm_ctl->ops.set_active_fetch_pipes)
+ mixer[i].lm_ctl->ops.set_active_fetch_pipes(mixer[i].lm_ctl, NULL);
+ if (mixer[i].lm_ctl->ops.set_active_pipes)
+ mixer[i].lm_ctl->ops.set_active_pipes(mixer[i].lm_ctl, NULL);
+
+ if (mixer[i].hw_lm->ops.clear_all_blendstages)
+ mixer[i].hw_lm->ops.clear_all_blendstages(mixer[i].hw_lm);
}
/* initialize stage cfg */
memset(&stage_cfg, 0, sizeof(struct dpu_hw_stage_cfg));
+ memset(active_lms, 0, sizeof(active_lms));
_dpu_crtc_blend_setup_mixer(crtc, dpu_crtc, mixer, &stage_cfg);
@@ -536,13 +558,22 @@ static void _dpu_crtc_blend_setup(struct drm_crtc *crtc)
ctl->ops.update_pending_flush_mixer(ctl,
mixer[i].hw_lm->idx);
+ set_bit(lm->idx, active_lms);
+ if (ctl->ops.set_active_lms)
+ ctl->ops.set_active_lms(ctl, active_lms);
+
DRM_DEBUG_ATOMIC("lm %d, op_mode 0x%X, ctl %d\n",
mixer[i].hw_lm->idx - LM_0,
mixer[i].mixer_op_mode,
ctl->idx - CTL_0);
- ctl->ops.setup_blendstage(ctl, mixer[i].hw_lm->idx,
- &stage_cfg);
+ if (ctl->ops.setup_blendstage)
+ ctl->ops.setup_blendstage(ctl, mixer[i].hw_lm->idx,
+ &stage_cfg);
+
+ if (lm->ops.setup_blendstage)
+ lm->ops.setup_blendstage(lm, mixer[i].hw_lm->idx,
+ &stage_cfg);
}
}
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c
index 5172ab4dea995a154cd88d05c3842d7425fc34ce..56b858011d02cb20c25053fa90932b1478286501 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c
@@ -2199,6 +2199,18 @@ static void dpu_encoder_helper_reset_mixers(struct dpu_encoder_phys *phys_enc)
/* clear all blendstages */
if (phys_enc->hw_ctl->ops.setup_blendstage)
phys_enc->hw_ctl->ops.setup_blendstage(ctl, hw_mixer[i]->idx, NULL);
+
+ if (hw_mixer[i]->ops.clear_all_blendstages)
+ hw_mixer[i]->ops.clear_all_blendstages(hw_mixer[i]);
+
+ if (ctl->ops.set_active_lms)
+ ctl->ops.set_active_lms(ctl, NULL);
+
+ if (ctl->ops.set_active_fetch_pipes)
+ ctl->ops.set_active_fetch_pipes(ctl, NULL);
+
+ if (ctl->ops.set_active_pipes)
+ ctl->ops.set_active_pipes(ctl, NULL);
}
}
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
index 2e1e22589f730d1a60c3cbf6ad6b6aeaea38c6fb..8b6b60f5e6206078f1df98b20f77ed91049e6ef0 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c
@@ -40,6 +40,8 @@
#define CTL_INTF_FLUSH 0x110
#define CTL_CDM_FLUSH 0x114
#define CTL_PERIPH_FLUSH 0x128
+#define CTL_PIPE_ACTIVE 0x12C
+#define CTL_LAYER_ACTIVE 0x130
#define CTL_INTF_MASTER 0x134
#define CTL_DSPP_n_FLUSH(n) ((0x13C) + ((n) * 4))
@@ -61,6 +63,8 @@ static const u32 fetch_tbl[SSPP_MAX] = {CTL_INVALID_BIT, 16, 17, 18, 19,
CTL_INVALID_BIT, CTL_INVALID_BIT, CTL_INVALID_BIT, CTL_INVALID_BIT, 0,
1, 2, 3, 4, 5};
+static const u32 lm_tbl[LM_MAX] = {CTL_INVALID_BIT, 0, 1, 2, 3, 4, 5, 6, 7};
+
static int _mixer_stages(const struct dpu_lm_cfg *mixer, int count,
enum dpu_lm lm)
{
@@ -648,7 +652,17 @@ static void dpu_hw_ctl_reset_intf_cfg_v1(struct dpu_hw_ctl *ctx,
merge3d_active);
}
- dpu_hw_ctl_clear_all_blendstages(ctx);
+ if (ctx->ops.clear_all_blendstages)
+ ctx->ops.clear_all_blendstages(ctx);
+
+ if (ctx->ops.set_active_lms)
+ ctx->ops.set_active_lms(ctx, NULL);
+
+ if (ctx->ops.set_active_fetch_pipes)
+ ctx->ops.set_active_fetch_pipes(ctx, NULL);
+
+ if (ctx->ops.set_active_pipes)
+ ctx->ops.set_active_pipes(ctx, NULL);
if (cfg->intf) {
intf_active = DPU_REG_READ(c, CTL_INTF_ACTIVE);
@@ -692,6 +706,40 @@ static void dpu_hw_ctl_set_active_fetch_pipes(struct dpu_hw_ctl *ctx,
DPU_REG_WRITE(&ctx->hw, CTL_FETCH_PIPE_ACTIVE, val);
}
+static void dpu_hw_ctl_set_active_pipes(struct dpu_hw_ctl *ctx,
+ unsigned long *active_pipes)
+{
+ int i;
+ u32 val = 0;
+
+ if (active_pipes) {
+ for (i = 0; i < SSPP_MAX; i++) {
+ if (test_bit(i, active_pipes) &&
+ fetch_tbl[i] != CTL_INVALID_BIT)
+ val |= BIT(fetch_tbl[i]);
+ }
+ }
+
+ DPU_REG_WRITE(&ctx->hw, CTL_PIPE_ACTIVE, val);
+}
+
+static void dpu_hw_ctl_set_active_lms(struct dpu_hw_ctl *ctx,
+ unsigned long *active_lms)
+{
+ int i;
+ u32 val = 0;
+
+ if (active_lms) {
+ for (i = LM_0; i < LM_MAX; i++) {
+ if (test_bit(i, active_lms) &&
+ lm_tbl[i] != CTL_INVALID_BIT)
+ val |= BIT(lm_tbl[i]);
+ }
+ }
+
+ DPU_REG_WRITE(&ctx->hw, CTL_LAYER_ACTIVE, val);
+}
+
/**
* dpu_hw_ctl_init() - Initializes the ctl_path hw driver object.
* Should be called before accessing any ctl_path register.
@@ -754,8 +802,13 @@ struct dpu_hw_ctl *dpu_hw_ctl_init(struct drm_device *dev,
c->ops.trigger_pending = dpu_hw_ctl_trigger_pending;
c->ops.reset = dpu_hw_ctl_reset_control;
c->ops.wait_reset_status = dpu_hw_ctl_wait_reset_status;
- c->ops.clear_all_blendstages = dpu_hw_ctl_clear_all_blendstages;
- c->ops.setup_blendstage = dpu_hw_ctl_setup_blendstage;
+ if (mdss_ver->core_major_ver < 12) {
+ c->ops.clear_all_blendstages = dpu_hw_ctl_clear_all_blendstages;
+ c->ops.setup_blendstage = dpu_hw_ctl_setup_blendstage;
+ } else {
+ c->ops.set_active_pipes = dpu_hw_ctl_set_active_pipes;
+ c->ops.set_active_lms = dpu_hw_ctl_set_active_lms;
+ }
c->ops.update_pending_flush_sspp = dpu_hw_ctl_update_pending_flush_sspp;
c->ops.update_pending_flush_mixer = dpu_hw_ctl_update_pending_flush_mixer;
if (mdss_ver->core_major_ver >= 7)
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h
index b8bd5b22c5f8dadd01c16c352efef4063f2614a6..7175dfecea1057db3fa16fbfd4139182a53d1760 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h
@@ -245,6 +245,23 @@ struct dpu_hw_ctl_ops {
void (*set_active_fetch_pipes)(struct dpu_hw_ctl *ctx,
unsigned long *fetch_active);
+
+ /**
+ * Set active pipes attached to this CTL
+ * @ctx: ctl path ctx pointer
+ * @active_pipes: bitmap of enum dpu_sspp
+ */
+ void (*set_active_pipes)(struct dpu_hw_ctl *ctx,
+ unsigned long *active_pipes);
+
+ /**
+ * Set active layer mixers attached to this CTL
+ * @ctx: ctl path ctx pointer
+ * @active_lms: bitmap of enum dpu_lm
+ */
+ void (*set_active_lms)(struct dpu_hw_ctl *ctx,
+ unsigned long *active_lms);
+
};
/**
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c
index 3bfb61cb83672dca4236bdbbbfb1e442223576d2..c631b4ae8dc13b7b18fab4721a7b2f2d97da717a 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c
@@ -19,12 +19,28 @@
/* These register are offset to mixer base + stage base */
#define LM_BLEND0_OP 0x00
+
+/* <v12 DPU with offset to mixer base + stage base */
#define LM_BLEND0_CONST_ALPHA 0x04
#define LM_FG_COLOR_FILL_COLOR_0 0x08
#define LM_FG_COLOR_FILL_COLOR_1 0x0C
#define LM_FG_COLOR_FILL_SIZE 0x10
#define LM_FG_COLOR_FILL_XY 0x14
+/* >= v12 DPU */
+#define LM_BG_SRC_SEL_V12 0x14
+#define LM_BG_SRC_SEL_V12_RESET_VALUE 0x0000C0C0
+#define LM_BORDER_COLOR_0_V12 0x1C
+#define LM_BORDER_COLOR_1_V12 0x20
+
+/* >= v12 DPU with offset to mixer base + stage base */
+#define LM_BLEND0_FG_SRC_SEL_V12 0x04
+#define LM_BLEND0_CONST_ALPHA_V12 0x08
+#define LM_FG_COLOR_FILL_COLOR_0_V12 0x0C
+#define LM_FG_COLOR_FILL_COLOR_1_V12 0x10
+#define LM_FG_COLOR_FILL_SIZE_V12 0x14
+#define LM_FG_COLOR_FILL_XY_V12 0x18
+
#define LM_BLEND0_FG_ALPHA 0x04
#define LM_BLEND0_BG_ALPHA 0x08
@@ -83,6 +99,22 @@ static void dpu_hw_lm_setup_border_color(struct dpu_hw_mixer *ctx,
}
}
+static void dpu_hw_lm_setup_border_color_v12(struct dpu_hw_mixer *ctx,
+ struct dpu_mdss_color *color,
+ u8 border_en)
+{
+ struct dpu_hw_blk_reg_map *c = &ctx->hw;
+
+ if (border_en) {
+ DPU_REG_WRITE(c, LM_BORDER_COLOR_0_V12,
+ (color->color_0 & 0x3ff) |
+ ((color->color_1 & 0x3ff) << 16));
+ DPU_REG_WRITE(c, LM_BORDER_COLOR_1_V12,
+ (color->color_2 & 0x3ff) |
+ ((color->color_3 & 0x3ff) << 16));
+ }
+}
+
static void dpu_hw_lm_setup_misr(struct dpu_hw_mixer *ctx)
{
dpu_hw_setup_misr(&ctx->hw, LM_MISR_CTRL, 0x0);
@@ -112,6 +144,27 @@ static void dpu_hw_lm_setup_blend_config_combined_alpha(struct dpu_hw_mixer *ctx
DPU_REG_WRITE(c, LM_BLEND0_OP + stage_off, blend_op);
}
+static void
+dpu_hw_lm_setup_blend_config_combined_alpha_v12(struct dpu_hw_mixer *ctx,
+ u32 stage, u32 fg_alpha,
+ u32 bg_alpha, u32 blend_op)
+{
+ struct dpu_hw_blk_reg_map *c = &ctx->hw;
+ int stage_off;
+ u32 const_alpha;
+
+ if (stage == DPU_STAGE_BASE)
+ return;
+
+ stage_off = _stage_offset(ctx, stage);
+ if (WARN_ON(stage_off < 0))
+ return;
+
+ const_alpha = (bg_alpha & 0x3ff) | ((fg_alpha & 0x3ff) << 16);
+ DPU_REG_WRITE(c, LM_BLEND0_CONST_ALPHA_V12 + stage_off, const_alpha);
+ DPU_REG_WRITE(c, LM_BLEND0_OP + stage_off, blend_op);
+}
+
static void dpu_hw_lm_setup_blend_config(struct dpu_hw_mixer *ctx,
u32 stage, u32 fg_alpha, u32 bg_alpha, u32 blend_op)
{
@@ -144,6 +197,148 @@ static void dpu_hw_lm_setup_color3(struct dpu_hw_mixer *ctx,
DPU_REG_WRITE(c, LM_OP_MODE, op_mode);
}
+static void dpu_hw_lm_setup_color3_v12(struct dpu_hw_mixer *ctx,
+ uint32_t mixer_op_mode)
+{
+ struct dpu_hw_blk_reg_map *c = &ctx->hw;
+ int op_mode, stages, stage_off, i;
+
+ stages = ctx->cap->sblk->maxblendstages;
+ if (stages <= 0)
+ return;
+
+ for (i = DPU_STAGE_0; i <= stages; i++) {
+ stage_off = _stage_offset(ctx, i);
+ if (WARN_ON(stage_off < 0))
+ return;
+
+ /* set color_out3 bit in blend0_op when enabled in mixer_op_mode */
+ op_mode = DPU_REG_READ(c, LM_BLEND0_OP + stage_off);
+ if (mixer_op_mode & BIT(i))
+ op_mode |= BIT(30);
+ else
+ op_mode &= ~BIT(30);
+
+ DPU_REG_WRITE(c, LM_BLEND0_OP + stage_off, op_mode);
+ }
+}
+
+static int _set_staged_sspp(u32 stage, struct dpu_hw_stage_cfg *stage_cfg,
+ int pipes_per_stage, u32 *value)
+{
+ int i;
+ u32 pipe_type = 0, pipe_id = 0, rec_id = 0;
+ u32 src_sel[PIPES_PER_STAGE];
+
+ *value = LM_BG_SRC_SEL_V12_RESET_VALUE;
+ if (!stage_cfg || !pipes_per_stage)
+ return 0;
+
+ for (i = 0; i < pipes_per_stage; i++) {
+ enum dpu_sspp pipe = stage_cfg->stage[stage][i];
+ enum dpu_sspp_multirect_index rect_index = stage_cfg->multirect_index[stage][i];
+
+ src_sel[i] = LM_BG_SRC_SEL_V12_RESET_VALUE;
+
+ if (!pipe)
+ continue;
+
+ /* translate pipe data to SWI pipe_type, pipe_id */
+ if (pipe >= SSPP_DMA0 && pipe <= SSPP_DMA5) {
+ pipe_type = 0;
+ pipe_id = pipe - SSPP_DMA0;
+ } else if (pipe >= SSPP_VIG0 && pipe <= SSPP_VIG3) {
+ pipe_type = 1;
+ pipe_id = pipe - SSPP_VIG0;
+ } else {
+ DPU_ERROR("invalid rec-%d pipe:%d\n", i, pipe);
+ return -EINVAL;
+ }
+
+ /* translate rec data to SWI rec_id */
+ if (rect_index == DPU_SSPP_RECT_SOLO || rect_index == DPU_SSPP_RECT_0) {
+ rec_id = 0;
+ } else if (rect_index == DPU_SSPP_RECT_1) {
+ rec_id = 1;
+ } else {
+ DPU_ERROR("invalid rec-%d rect_index:%d\n", i, rect_index);
+ rec_id = 0;
+ }
+
+ /* calculate SWI value for rec-0 and rec-1 and store it temporary buffer */
+ src_sel[i] = (((pipe_type & 0x3) << 6) | ((rec_id & 0x3) << 4) | (pipe_id & 0xf));
+ }
+
+ /* calculate final SWI register value for rec-0 and rec-1 */
+ *value = 0;
+ for (i = 0; i < pipes_per_stage; i++)
+ *value |= src_sel[i] << (i * 8);
+
+ return 0;
+}
+
+static int dpu_hw_lm_setup_blendstage(struct dpu_hw_mixer *ctx, enum dpu_lm lm,
+ struct dpu_hw_stage_cfg *stage_cfg)
+{
+ struct dpu_hw_blk_reg_map *c = &ctx->hw;
+ int i, ret, stages, stage_off, pipes_per_stage;
+ u32 value;
+
+ stages = ctx->cap->sblk->maxblendstages;
+ if (stages <= 0)
+ return -EINVAL;
+
+ if (ctx->cap->sourcesplit)
+ pipes_per_stage = PIPES_PER_STAGE;
+ else
+ pipes_per_stage = 1;
+
+ /*
+ * When stage configuration is empty, we can enable the
+ * border color by setting the corresponding LAYER_ACTIVE bit
+ * and un-staging all the pipes from the layer mixer.
+ */
+ if (!stage_cfg)
+ DPU_REG_WRITE(c, LM_BG_SRC_SEL_V12, LM_BG_SRC_SEL_V12_RESET_VALUE);
+
+ for (i = DPU_STAGE_0; i <= stages; i++) {
+ stage_off = _stage_offset(ctx, i);
+ if (stage_off < 0)
+ return stage_off;
+
+ ret = _set_staged_sspp(i, stage_cfg, pipes_per_stage, &value);
+ if (ret)
+ return ret;
+
+ DPU_REG_WRITE(c, LM_BLEND0_FG_SRC_SEL_V12 + stage_off, value);
+ }
+
+ return 0;
+}
+
+static int dpu_hw_lm_clear_all_blendstages(struct dpu_hw_mixer *ctx)
+{
+ struct dpu_hw_blk_reg_map *c = &ctx->hw;
+ int i, stages, stage_off;
+
+ stages = ctx->cap->sblk->maxblendstages;
+ if (stages <= 0)
+ return -EINVAL;
+
+ DPU_REG_WRITE(c, LM_BG_SRC_SEL_V12, LM_BG_SRC_SEL_V12_RESET_VALUE);
+
+ for (i = DPU_STAGE_0; i <= stages; i++) {
+ stage_off = _stage_offset(ctx, i);
+ if (stage_off < 0)
+ return stage_off;
+
+ DPU_REG_WRITE(c, LM_BLEND0_FG_SRC_SEL_V12 + stage_off,
+ LM_BG_SRC_SEL_V12_RESET_VALUE);
+ }
+
+ return 0;
+}
+
/**
* dpu_hw_lm_init() - Initializes the mixer hw driver object.
* should be called once before accessing every mixer.
@@ -175,12 +370,21 @@ struct dpu_hw_mixer *dpu_hw_lm_init(struct drm_device *dev,
c->idx = cfg->id;
c->cap = cfg;
c->ops.setup_mixer_out = dpu_hw_lm_setup_out;
- if (mdss_ver->core_major_ver >= 4)
+ if (mdss_ver->core_major_ver >= 12)
+ c->ops.setup_blend_config = dpu_hw_lm_setup_blend_config_combined_alpha_v12;
+ else if (mdss_ver->core_major_ver >= 4)
c->ops.setup_blend_config = dpu_hw_lm_setup_blend_config_combined_alpha;
else
c->ops.setup_blend_config = dpu_hw_lm_setup_blend_config;
- c->ops.setup_alpha_out = dpu_hw_lm_setup_color3;
- c->ops.setup_border_color = dpu_hw_lm_setup_border_color;
+ if (mdss_ver->core_major_ver < 12) {
+ c->ops.setup_alpha_out = dpu_hw_lm_setup_color3;
+ c->ops.setup_border_color = dpu_hw_lm_setup_border_color;
+ } else {
+ c->ops.setup_alpha_out = dpu_hw_lm_setup_color3_v12;
+ c->ops.setup_blendstage = dpu_hw_lm_setup_blendstage;
+ c->ops.clear_all_blendstages = dpu_hw_lm_clear_all_blendstages;
+ c->ops.setup_border_color = dpu_hw_lm_setup_border_color_v12;
+ }
c->ops.setup_misr = dpu_hw_lm_setup_misr;
c->ops.collect_misr = dpu_hw_lm_collect_misr;
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.h b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.h
index fff1156add683fec8ce6785e7fe1d769d0de3fe0..1b9ecd082d7fd72b07008787e1caea968ed23376 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.h
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.h
@@ -11,6 +11,7 @@
#include "dpu_hw_util.h"
struct dpu_hw_mixer;
+struct dpu_hw_stage_cfg;
struct dpu_hw_mixer_cfg {
u32 out_width;
@@ -48,6 +49,23 @@ struct dpu_hw_lm_ops {
*/
void (*setup_alpha_out)(struct dpu_hw_mixer *ctx, uint32_t mixer_op);
+ /**
+ * Clear layer mixer to pipe configuration
+ * @ctx : mixer ctx pointer
+ * Returns: 0 on success or -error
+ */
+ int (*clear_all_blendstages)(struct dpu_hw_mixer *ctx);
+
+ /**
+ * Configure layer mixer to pipe configuration
+ * @ctx : mixer ctx pointer
+ * @lm : layer mixer enumeration
+ * @stage_cfg : blend stage configuration
+ * Returns: 0 on success or -error
+ */
+ int (*setup_blendstage)(struct dpu_hw_mixer *ctx, enum dpu_lm lm,
+ struct dpu_hw_stage_cfg *stage_cfg);
+
/**
* setup_border_color : enable/disable border color
*/
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 15/16] drm/msm/dpu: Implement new v12.0 DPU differences
2025-02-17 16:41 ` [PATCH v2 15/16] drm/msm/dpu: Implement new v12.0 DPU differences Krzysztof Kozlowski
@ 2025-02-17 19:18 ` Dmitry Baryshkov
2025-02-19 17:04 ` Krzysztof Kozlowski
0 siblings, 1 reply; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-17 19:18 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Mon, Feb 17, 2025 at 05:41:36PM +0100, Krzysztof Kozlowski wrote:
> Implement new features and differences coming in v12.0 of DPU present on
> Qualcomm SM8750 SoC:
> 1. 10-bit color alpha.
> 2. New CTL_PIPE_ACTIVE and CTL_LAYER_ACTIVE registers for pipes and
> layer mixers.
> 2. Several differences in LM registers (also changed offsets) for LM
> crossbar hardware changes.
I'd really prefer for this patch to be split into a logical chunks
rather than "everything for 12.x"
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>
> ---
>
> Changes in v2:
> 1. New patch
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 49 +++++--
> drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 12 ++
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c | 59 +++++++-
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h | 17 +++
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c | 210 +++++++++++++++++++++++++++-
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.h | 18 +++
> 6 files changed, 350 insertions(+), 15 deletions(-)
>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 15/16] drm/msm/dpu: Implement new v12.0 DPU differences
2025-02-17 19:18 ` Dmitry Baryshkov
@ 2025-02-19 17:04 ` Krzysztof Kozlowski
2025-02-19 17:24 ` Dmitry Baryshkov
0 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-19 17:04 UTC (permalink / raw)
To: Dmitry Baryshkov
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 17/02/2025 20:18, Dmitry Baryshkov wrote:
> On Mon, Feb 17, 2025 at 05:41:36PM +0100, Krzysztof Kozlowski wrote:
>> Implement new features and differences coming in v12.0 of DPU present on
>> Qualcomm SM8750 SoC:
>> 1. 10-bit color alpha.
>> 2. New CTL_PIPE_ACTIVE and CTL_LAYER_ACTIVE registers for pipes and
>> layer mixers.
>> 2. Several differences in LM registers (also changed offsets) for LM
>> crossbar hardware changes.
>
> I'd really prefer for this patch to be split into a logical chunks
> rather than "everything for 12.x"
everything 12.x is still logical chunk. I can split more, but without
guidance what is here logical chunk, will be tricky.
For example 10-bit color alpha looks like separate feature. But
remaining PIPE/LAYER active - not sure.
I can split them but I would not call such split necessarily logical.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 15/16] drm/msm/dpu: Implement new v12.0 DPU differences
2025-02-19 17:04 ` Krzysztof Kozlowski
@ 2025-02-19 17:24 ` Dmitry Baryshkov
2025-02-21 12:36 ` Krzysztof Kozlowski
0 siblings, 1 reply; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-19 17:24 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Wed, 19 Feb 2025 at 19:04, Krzysztof Kozlowski
<krzysztof.kozlowski@linaro.org> wrote:
>
> On 17/02/2025 20:18, Dmitry Baryshkov wrote:
> > On Mon, Feb 17, 2025 at 05:41:36PM +0100, Krzysztof Kozlowski wrote:
> >> Implement new features and differences coming in v12.0 of DPU present on
> >> Qualcomm SM8750 SoC:
> >> 1. 10-bit color alpha.
> >> 2. New CTL_PIPE_ACTIVE and CTL_LAYER_ACTIVE registers for pipes and
> >> layer mixers.
> >> 2. Several differences in LM registers (also changed offsets) for LM
> >> crossbar hardware changes.
> >
> > I'd really prefer for this patch to be split into a logical chunks
> > rather than "everything for 12.x"
> everything 12.x is still logical chunk. I can split more, but without
> guidance what is here logical chunk, will be tricky.
>
> For example 10-bit color alpha looks like separate feature. But
> remaining PIPE/LAYER active - not sure.
>
> I can split them but I would not call such split necessarily logical.
I'd say, the following items are logical chunks:
- ctl->ops.active_fetch_pipes in dpu_encoder_helper_reset_mixers() and
dpu_hw_ctl_reset_intf_cfg_v1() (with a proper Fixes tag?)
- 10-bit alpha, border color,
- active_pipes
- blend stage in LM + set_active_lms
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 15/16] drm/msm/dpu: Implement new v12.0 DPU differences
2025-02-19 17:24 ` Dmitry Baryshkov
@ 2025-02-21 12:36 ` Krzysztof Kozlowski
2025-02-21 13:33 ` Dmitry Baryshkov
0 siblings, 1 reply; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-21 12:36 UTC (permalink / raw)
To: Dmitry Baryshkov
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On 19/02/2025 18:24, Dmitry Baryshkov wrote:
> On Wed, 19 Feb 2025 at 19:04, Krzysztof Kozlowski
> <krzysztof.kozlowski@linaro.org> wrote:
>>
>> On 17/02/2025 20:18, Dmitry Baryshkov wrote:
>>> On Mon, Feb 17, 2025 at 05:41:36PM +0100, Krzysztof Kozlowski wrote:
>>>> Implement new features and differences coming in v12.0 of DPU present on
>>>> Qualcomm SM8750 SoC:
>>>> 1. 10-bit color alpha.
>>>> 2. New CTL_PIPE_ACTIVE and CTL_LAYER_ACTIVE registers for pipes and
>>>> layer mixers.
>>>> 2. Several differences in LM registers (also changed offsets) for LM
>>>> crossbar hardware changes.
>>>
>>> I'd really prefer for this patch to be split into a logical chunks
>>> rather than "everything for 12.x"
>> everything 12.x is still logical chunk. I can split more, but without
>> guidance what is here logical chunk, will be tricky.
>>
>> For example 10-bit color alpha looks like separate feature. But
>> remaining PIPE/LAYER active - not sure.
>>
>> I can split them but I would not call such split necessarily logical.
>
> I'd say, the following items are logical chunks:
> - ctl->ops.active_fetch_pipes in dpu_encoder_helper_reset_mixers() and
> dpu_hw_ctl_reset_intf_cfg_v1() (with a proper Fixes tag?)
Ack
> - 10-bit alpha, border color,
Ack,
> - active_pipes
> - blend stage in LM + set_active_lms
Ack, but you do understand that this is purely from new hardware, so
new registers. Even the 10bit border color is actually for new
registers. It makes no context outside of new hardware. same here.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [PATCH v2 15/16] drm/msm/dpu: Implement new v12.0 DPU differences
2025-02-21 12:36 ` Krzysztof Kozlowski
@ 2025-02-21 13:33 ` Dmitry Baryshkov
0 siblings, 0 replies; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-21 13:33 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Rob Clark, Abhinav Kumar, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Krishna Manikandan, Jonathan Marek, Kuogee Hsieh, Neil Armstrong,
linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Srini Kandagatla
On Fri, Feb 21, 2025 at 01:36:51PM +0100, Krzysztof Kozlowski wrote:
> On 19/02/2025 18:24, Dmitry Baryshkov wrote:
> > On Wed, 19 Feb 2025 at 19:04, Krzysztof Kozlowski
> > <krzysztof.kozlowski@linaro.org> wrote:
> >>
> >> On 17/02/2025 20:18, Dmitry Baryshkov wrote:
> >>> On Mon, Feb 17, 2025 at 05:41:36PM +0100, Krzysztof Kozlowski wrote:
> >>>> Implement new features and differences coming in v12.0 of DPU present on
> >>>> Qualcomm SM8750 SoC:
> >>>> 1. 10-bit color alpha.
> >>>> 2. New CTL_PIPE_ACTIVE and CTL_LAYER_ACTIVE registers for pipes and
> >>>> layer mixers.
> >>>> 2. Several differences in LM registers (also changed offsets) for LM
> >>>> crossbar hardware changes.
> >>>
> >>> I'd really prefer for this patch to be split into a logical chunks
> >>> rather than "everything for 12.x"
> >> everything 12.x is still logical chunk. I can split more, but without
> >> guidance what is here logical chunk, will be tricky.
> >>
> >> For example 10-bit color alpha looks like separate feature. But
> >> remaining PIPE/LAYER active - not sure.
> >>
> >> I can split them but I would not call such split necessarily logical.
> >
> > I'd say, the following items are logical chunks:
> > - ctl->ops.active_fetch_pipes in dpu_encoder_helper_reset_mixers() and
> > dpu_hw_ctl_reset_intf_cfg_v1() (with a proper Fixes tag?)
>
>
> Ack
>
> > - 10-bit alpha, border color,
>
>
> Ack,
>
> > - active_pipes
> > - blend stage in LM + set_active_lms
>
>
> Ack, but you do understand that this is purely from new hardware, so
> new registers. Even the 10bit border color is actually for new
> registers. It makes no context outside of new hardware. same here.
Yes. However those changes are logically separate, they cover different
parts of new HW. So it makes it easier for anybody reviewing those
changes (now or later).
>
> Best regards,
> Krzysztof
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread
* [PATCH v2 16/16] drm/msm/mdss: Add support for SM8750
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (14 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 15/16] drm/msm/dpu: Implement new v12.0 DPU differences Krzysztof Kozlowski
@ 2025-02-17 16:41 ` Krzysztof Kozlowski
2025-02-19 21:17 ` [PATCH v2 00/16] drm/msm: " Jessica Zhang
16 siblings, 0 replies; 54+ messages in thread
From: Krzysztof Kozlowski @ 2025-02-17 16:41 UTC (permalink / raw)
To: Rob Clark, Abhinav Kumar, Dmitry Baryshkov, Sean Paul,
Marijn Suijten, David Airlie, Simona Vetter, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Krishna Manikandan,
Jonathan Marek, Kuogee Hsieh, Neil Armstrong
Cc: linux-arm-msm, dri-devel, freedreno, devicetree, linux-kernel,
Krzysztof Kozlowski, Srini Kandagatla
Add support for the Qualcomm SM8750 platform.
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
drivers/gpu/drm/msm/msm_mdss.c | 33 +++++++++++++++++++++++++++++++++
drivers/gpu/drm/msm/msm_mdss.h | 1 +
2 files changed, 34 insertions(+)
diff --git a/drivers/gpu/drm/msm/msm_mdss.c b/drivers/gpu/drm/msm/msm_mdss.c
index dcb49fd30402b80edd2cb5971f95a78eaad6081f..3f00eb6de3a9d2bee7637c6f516efff78b7d872b 100644
--- a/drivers/gpu/drm/msm/msm_mdss.c
+++ b/drivers/gpu/drm/msm/msm_mdss.c
@@ -222,6 +222,24 @@ static void msm_mdss_setup_ubwc_dec_40(struct msm_mdss *msm_mdss)
}
}
+static void msm_mdss_setup_ubwc_dec_50(struct msm_mdss *msm_mdss)
+{
+ const struct msm_mdss_data *data = msm_mdss->mdss_data;
+ u32 value = MDSS_UBWC_STATIC_UBWC_SWIZZLE(data->ubwc_swizzle) |
+ MDSS_UBWC_STATIC_HIGHEST_BANK_BIT(data->highest_bank_bit);
+
+ if (data->ubwc_bank_spread)
+ value |= MDSS_UBWC_STATIC_UBWC_BANK_SPREAD;
+
+ if (data->macrotile_mode)
+ value |= MDSS_UBWC_STATIC_MACROTILE_MODE;
+
+ writel_relaxed(value, msm_mdss->mmio + REG_MDSS_UBWC_STATIC);
+
+ writel_relaxed(4, msm_mdss->mmio + REG_MDSS_UBWC_CTRL_2);
+ writel_relaxed(1, msm_mdss->mmio + REG_MDSS_UBWC_PREDICTION_MODE);
+}
+
#define MDSS_HW_MAJ_MIN \
(MDSS_HW_VERSION_MAJOR__MASK | MDSS_HW_VERSION_MINOR__MASK)
@@ -339,6 +357,9 @@ static int msm_mdss_enable(struct msm_mdss *msm_mdss)
case UBWC_4_3:
msm_mdss_setup_ubwc_dec_40(msm_mdss);
break;
+ case UBWC_5_0:
+ msm_mdss_setup_ubwc_dec_50(msm_mdss);
+ break;
default:
dev_err(msm_mdss->dev, "Unsupported UBWC decoder version %x\n",
msm_mdss->mdss_data->ubwc_dec_version);
@@ -722,6 +743,17 @@ static const struct msm_mdss_data sm8550_data = {
.reg_bus_bw = 57000,
};
+static const struct msm_mdss_data sm8750_data = {
+ .ubwc_enc_version = UBWC_5_0,
+ .ubwc_dec_version = UBWC_5_0,
+ .ubwc_swizzle = 6,
+ .ubwc_bank_spread = true,
+ /* TODO: highest_bank_bit = 2 for LP_DDR4 */
+ .highest_bank_bit = 3,
+ .macrotile_mode = true,
+ .reg_bus_bw = 57000,
+};
+
static const struct msm_mdss_data x1e80100_data = {
.ubwc_enc_version = UBWC_4_0,
.ubwc_dec_version = UBWC_4_3,
@@ -756,6 +788,7 @@ static const struct of_device_id mdss_dt_match[] = {
{ .compatible = "qcom,sm8450-mdss", .data = &sm8350_data },
{ .compatible = "qcom,sm8550-mdss", .data = &sm8550_data },
{ .compatible = "qcom,sm8650-mdss", .data = &sm8550_data},
+ { .compatible = "qcom,sm8750-mdss", .data = &sm8750_data},
{ .compatible = "qcom,x1e80100-mdss", .data = &x1e80100_data},
{}
};
diff --git a/drivers/gpu/drm/msm/msm_mdss.h b/drivers/gpu/drm/msm/msm_mdss.h
index 14dc53704314558841ee1fe08d93309fd2233812..dd0160c6ba1a297cea5b87cd8b03895b2aa08213 100644
--- a/drivers/gpu/drm/msm/msm_mdss.h
+++ b/drivers/gpu/drm/msm/msm_mdss.h
@@ -22,6 +22,7 @@ struct msm_mdss_data {
#define UBWC_3_0 0x30000000
#define UBWC_4_0 0x40000000
#define UBWC_4_3 0x40030000
+#define UBWC_5_0 0x50000000
const struct msm_mdss_data *msm_mdss_get_mdss_data(struct device *dev);
--
2.43.0
^ permalink raw reply related [flat|nested] 54+ messages in thread* Re: [PATCH v2 00/16] drm/msm: Add support for SM8750
2025-02-17 16:41 [PATCH v2 00/16] drm/msm: Add support for SM8750 Krzysztof Kozlowski
` (15 preceding siblings ...)
2025-02-17 16:41 ` [PATCH v2 16/16] drm/msm/mdss: Add support for SM8750 Krzysztof Kozlowski
@ 2025-02-19 21:17 ` Jessica Zhang
2025-02-19 22:02 ` Dmitry Baryshkov
16 siblings, 1 reply; 54+ messages in thread
From: Jessica Zhang @ 2025-02-19 21:17 UTC (permalink / raw)
To: Dmitry Baryshkov
Cc: linux-arm-msm, Marijn Suijten, Rob Herring, Maarten Lankhorst,
Simona Vetter, David Airlie, Abhinav Kumar, dri-devel,
Krzysztof Kozlowski, Neil Armstrong, Kuogee Hsieh, freedreno,
Jonathan Marek, devicetree, linux-kernel, Srini Kandagatla,
Rob Clark, Sean Paul, Maxime Ripard, Thomas Zimmermann,
Krishna Manikandan, Krzysztof Kozlowski, Conor Dooley
On 2/17/2025 8:41 AM, Krzysztof Kozlowski wrote:
> Hi,
>
> Dependency / Rabased on top of:
> https://lore.kernel.org/all/20241214-dpu-drop-features-v1-0-988f0662cb7e@linaro.org/
>
> Changes in v2:
> - Implement LM crossbar, 10-bit alpha and active layer changes:
> New patch: drm/msm/dpu: Implement new v12.0 DPU differences
> - New patch: drm/msm/dpu: Add missing "fetch" name to set_active_pipes()
> - Add CDM
> - Split some DPU patch pieces into separate patches:
> drm/msm/dpu: Drop useless comments
> drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5
> drm/msm/dpu: Add handling of LM_6 and LM_7 bits in pending flush mask
> - Split DSI and DSI PHY patches
> - Mention CLK_OPS_PARENT_ENABLE in DSI commit
> - Mention DSI PHY PLL work:
> https://patchwork.freedesktop.org/patch/542000/?series=119177&rev=1
> - DPU: Drop SSPP_VIG4 comments
> - DPU: Add CDM
> - Link to v1: https://lore.kernel.org/r/20250109-b4-sm8750-display-v1-0-b3f15faf4c97@linaro.org
>
> Description:
> =============
> I got modetest writeback working, but DSI panel on MTP8750 still shows
> darkness.
Hey Dmitry,
Just wanted to emphasize this note on Krzysztof's cover letter.
Can we hold off on picking up the DSI parts of this series until the DSI
panel comes up for MTP8750?
Thanks,
Jessica Zhang
>
> Best regards,
> Krzysztof
>
> ---
> Krzysztof Kozlowski (16):
> dt-bindings: display/msm: dsi-controller-main: Combine if:then: entries
> dt-bindings: display/msm: dsi-controller-main: Add missing minItems
> dt-bindings: display/msm: dsi-phy-7nm: Add SM8750
> dt-bindings: display/msm: dsi-controller-main: Add SM8750
> dt-bindings: display/msm: dp-controller: Add SM8750
> dt-bindings: display/msm: qcom,sm8650-dpu: Add SM8750
> dt-bindings: display/msm: qcom,sm8750-mdss: Add SM8750
> drm/msm/dpu: Drop useless comments
> drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5
> drm/msm/dpu: Add handling of LM_6 and LM_7 bits in pending flush mask
> drm/msm/dsi/phy: Add support for SM8750
> drm/msm/dsi: Add support for SM8750
> drm/msm/dpu: Add support for SM8750
> drm/msm/dpu: Add missing "fetch" name to set_active_pipes()
> drm/msm/dpu: Implement new v12.0 DPU differences
> drm/msm/mdss: Add support for SM8750
>
> .../bindings/display/msm/dp-controller.yaml | 4 +
> .../bindings/display/msm/dsi-controller-main.yaml | 124 +++---
> .../bindings/display/msm/dsi-phy-7nm.yaml | 1 +
> .../bindings/display/msm/qcom,sm8650-dpu.yaml | 1 +
> .../bindings/display/msm/qcom,sm8750-mdss.yaml | 460 +++++++++++++++++++
> .../drm/msm/disp/dpu1/catalog/dpu_12_0_sm8750.h | 496 +++++++++++++++++++++
> drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 59 ++-
> drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 12 +
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 35 +-
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h | 1 +
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c | 71 ++-
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.h | 19 +-
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c | 210 ++++++++-
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.h | 18 +
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h | 6 +
> drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 1 +
> drivers/gpu/drm/msm/dsi/dsi.h | 2 +
> drivers/gpu/drm/msm/dsi/dsi_cfg.c | 25 ++
> drivers/gpu/drm/msm/dsi/dsi_cfg.h | 1 +
> drivers/gpu/drm/msm/dsi/dsi_host.c | 80 ++++
> drivers/gpu/drm/msm/dsi/phy/dsi_phy.c | 2 +
> drivers/gpu/drm/msm/dsi/phy/dsi_phy.h | 1 +
> drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c | 79 +++-
> drivers/gpu/drm/msm/msm_mdss.c | 33 ++
> drivers/gpu/drm/msm/msm_mdss.h | 1 +
> .../gpu/drm/msm/registers/display/dsi_phy_7nm.xml | 14 +
> 26 files changed, 1655 insertions(+), 101 deletions(-)
> ---
> base-commit: 44ddcc7604ae61eadc748ccc6156bf4b98697978
> change-id: 20250109-b4-sm8750-display-6ea537754af1
>
> Best regards,
> --
> Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>
^ permalink raw reply [flat|nested] 54+ messages in thread* Re: [PATCH v2 00/16] drm/msm: Add support for SM8750
2025-02-19 21:17 ` [PATCH v2 00/16] drm/msm: " Jessica Zhang
@ 2025-02-19 22:02 ` Dmitry Baryshkov
0 siblings, 0 replies; 54+ messages in thread
From: Dmitry Baryshkov @ 2025-02-19 22:02 UTC (permalink / raw)
To: Jessica Zhang
Cc: linux-arm-msm, Marijn Suijten, Rob Herring, Maarten Lankhorst,
Simona Vetter, David Airlie, Abhinav Kumar, dri-devel,
Krzysztof Kozlowski, Neil Armstrong, Kuogee Hsieh, freedreno,
Jonathan Marek, devicetree, linux-kernel, Srini Kandagatla,
Rob Clark, Sean Paul, Maxime Ripard, Thomas Zimmermann,
Krishna Manikandan, Krzysztof Kozlowski, Conor Dooley
On Wed, Feb 19, 2025 at 01:17:35PM -0800, Jessica Zhang wrote:
>
>
> On 2/17/2025 8:41 AM, Krzysztof Kozlowski wrote:
> > Hi,
> >
> > Dependency / Rabased on top of:
> > https://lore.kernel.org/all/20241214-dpu-drop-features-v1-0-988f0662cb7e@linaro.org/
> >
> > Changes in v2:
> > - Implement LM crossbar, 10-bit alpha and active layer changes:
> > New patch: drm/msm/dpu: Implement new v12.0 DPU differences
> > - New patch: drm/msm/dpu: Add missing "fetch" name to set_active_pipes()
> > - Add CDM
> > - Split some DPU patch pieces into separate patches:
> > drm/msm/dpu: Drop useless comments
> > drm/msm/dpu: Add LM_7, DSC_[67], PP_[67] and MERGE_3D_5
> > drm/msm/dpu: Add handling of LM_6 and LM_7 bits in pending flush mask
> > - Split DSI and DSI PHY patches
> > - Mention CLK_OPS_PARENT_ENABLE in DSI commit
> > - Mention DSI PHY PLL work:
> > https://patchwork.freedesktop.org/patch/542000/?series=119177&rev=1
> > - DPU: Drop SSPP_VIG4 comments
> > - DPU: Add CDM
> > - Link to v1: https://lore.kernel.org/r/20250109-b4-sm8750-display-v1-0-b3f15faf4c97@linaro.org
> >
> > Description:
> > =============
> > I got modetest writeback working, but DSI panel on MTP8750 still shows
> > darkness.
>
> Hey Dmitry,
>
> Just wanted to emphasize this note on Krzysztof's cover letter.
>
> Can we hold off on picking up the DSI parts of this series until the DSI
> panel comes up for MTP8750?
>
Ack, I will try to remember it.
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 54+ messages in thread