Re: [Freedreno] [PATCH v2 0/8] drm/msm: DSC Electric Boogaloo for sm8[12]50

2023-01-08 Thread Marijn Suijten
On 2023-01-05 15:49:58, Daniel Vetter wrote: > On Thu, Dec 22, 2022 at 12:19:35AM +0100, Marijn Suijten wrote: > > [..] > > Please note that Electric Boogaloo/Boogaloo Boys has been appropriated by > US alt-right groups, and so is really not a great thing to put into the > cover letter for your pa

Re: [Freedreno] [PATCH v5 1/4] dt-bindings: display/msm: convert MDP5 schema to YAML format

2023-01-08 Thread Marijn Suijten
On 2023-01-09 07:01:49, Dmitry Baryshkov wrote: > Convert the mdp5.txt into the yaml format. Changes to the existing (txt) > schema: > - MSM8996 has additional "iommu" clock, define it separately > - Add new properties used on some of platforms: >- interconnects, interconnect-names >- io

[Freedreno] [PATCH] dt-bindings: display/msm: gpu: add rbcpr clock

2023-01-08 Thread Dmitry Baryshkov
Describe the RBCPR clock used on msm8996 (A530), MSM8998 (A540) and SDM630/660 (A508/A512). Signed-off-by: Dmitry Baryshkov --- Documentation/devicetree/bindings/display/msm/gpu.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetree/bindings/display/msm/gpu.yaml b/D

[Freedreno] [PATCH 5/6] arm64: dts: qcom: rename mdp nodes to display-controller

2023-01-08 Thread Dmitry Baryshkov
Follow the schema change and rename mdp nodes to generic name 'display-controller'. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/msm8916.dtsi | 2 +- arch/arm64/boot/dts/qcom/msm8953.dtsi | 2 +- arch/arm64/boot/dts/qcom/msm8996.dtsi | 2 +- arch/arm64/boot/dts/qcom/sdm630.dtsi

[Freedreno] [PATCH 3/6] arm64: dts: qcom: rename mdss nodes to display-subsystem

2023-01-08 Thread Dmitry Baryshkov
Follow the schema change and rename mdss nodes to generic name 'display-subsystem'. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/msm8916.dtsi | 2 +- arch/arm64/boot/dts/qcom/msm8953.dtsi | 2 +- arch/arm64/boot/dts/qcom/msm8996.dtsi | 2 +- arch/arm64/boot/dts/qcom/sc7180.dtsi

[Freedreno] [PATCH 4/6] ARM: dts: qcom-msm8974: rename mdss node to display-subsystem

2023-01-08 Thread Dmitry Baryshkov
Follow the schema change and rename mdss node to generic name 'display-subsystem'. Signed-off-by: Dmitry Baryshkov --- arch/arm/boot/dts/qcom-msm8974.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/boot/dts/qcom-msm8974.dtsi b/arch/arm/boot/dts/qcom-msm8974.dts

[Freedreno] [PATCH 6/6] ARM: dts: qcom: rename mdp nodes to display-controller

2023-01-08 Thread Dmitry Baryshkov
Follow the schema change and rename mdp nodes to generic name 'display-controller'. Signed-off-by: Dmitry Baryshkov --- arch/arm/boot/dts/qcom-apq8064.dtsi | 2 +- arch/arm/boot/dts/qcom-msm8974.dtsi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/boot/dts/qcom-ap

[Freedreno] [PATCH 2/6] dt-bindings: display/msm: rename mdp nodes to display-controller

2023-01-08 Thread Dmitry Baryshkov
Follow the 'generic names' rule and rename mdp nodes to display-controller. Signed-off-by: Dmitry Baryshkov --- .../devicetree/bindings/display/msm/dpu-common.yaml | 8 .../devicetree/bindings/display/msm/qcom,mdp5.yaml| 3 +++ .../devicetree/bindings/display/msm/qcom,mdss

[Freedreno] [PATCH 1/6] dt-bindings: display/msm: rename mdss nodes to display-sybsystem

2023-01-08 Thread Dmitry Baryshkov
Follow the 'generic names' rule and rename mdss nodes to display-subsystem. Signed-off-by: Dmitry Baryshkov --- .../devicetree/bindings/display/msm/mdss-common.yaml | 8 .../devicetree/bindings/display/msm/qcom,mdss.yaml| 5 - 2 files changed, 12 insertions(+), 1 deleti

[Freedreno] [PATCH 0/6] dt-bindings: display/msm: rename mdss and mdp nodes

2023-01-08 Thread Dmitry Baryshkov
Finish the process of renaming display-related nodes on Qualcomm systems. Fix it in the schema that MDSS (Mobile Display SubSystem) devices are named `display-subsystem' and both MDP (Mobile Display Processor) and DPU (Display Processor Unit) nodes are named `display-controller'. Dmitry Baryshkov

[Freedreno] [PATCH v5 2/4] dt-bindings: display/msm: add SoC-specific compats to qcom, mdp5.yaml

2023-01-08 Thread Dmitry Baryshkov
Add platform-specific compatible entries to the qcom,mdp5.yaml to allow distinguishing between various platforms. For msm8998 list qcom,msm8998-dpu rather than -mdp5 to allow this binding to be handled by either of the drivers. Signed-off-by: Dmitry Baryshkov --- .../bindings/display/msm/qcom,md

[Freedreno] [PATCH v5 1/4] dt-bindings: display/msm: convert MDP5 schema to YAML format

2023-01-08 Thread Dmitry Baryshkov
Convert the mdp5.txt into the yaml format. Changes to the existing (txt) schema: - MSM8996 has additional "iommu" clock, define it separately - Add new properties used on some of platforms: - interconnects, interconnect-names - iommus - power-domains - operating-points-v2, opp-table

[Freedreno] [PATCH v5 3/4] ARM: dts: qcom-msm8974: add SoC specific compat string to mdp5 node

2023-01-08 Thread Dmitry Baryshkov
Add SoC-specific compat string to the MDP5 device node to ease distinguishing between various platforms. Signed-off-by: Dmitry Baryshkov --- arch/arm/boot/dts/qcom-msm8974.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/boot/dts/qcom-msm8974.dtsi b/arch/arm/boo

[Freedreno] [PATCH v5 4/4] arm64: dts: qcom: add SoC specific compat strings to mdp5 nodes

2023-01-08 Thread Dmitry Baryshkov
Add SoC-specific compat string to the MDP5 device nodes to ease distinguishing between various platforms. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/msm8916.dtsi | 2 +- arch/arm64/boot/dts/qcom/msm8996.dtsi | 2 +- arch/arm64/boot/dts/qcom/sdm630.dtsi | 2 +- arch/arm64/boot/

[Freedreno] [PATCH v5 0/4] dt-bindings: display/msm: convert MDP5 schema to YAML format

2023-01-08 Thread Dmitry Baryshkov
This patch concludes the conversion of display/msm schema from txt files to YAML format. The per-SoC compat (new addition) is required to ease migrating platform support between mdp5 and dpu drivers. Changes since v4: - Adjust qcom,mdss.yaml to follow the addition of per-SoC compatibles Changes

[Freedreno] [PATCH] dt-bindings: display/msm: qcom, sdm845-mdss: document the DP device

2023-01-08 Thread Dmitry Baryshkov
Document the DP controller added to the sdm845 display subsystem. Signed-off-by: Dmitry Baryshkov --- .../devicetree/bindings/display/msm/qcom,sdm845-mdss.yaml | 6 ++ 1 file changed, 6 insertions(+) diff --git a/Documentation/devicetree/bindings/display/msm/qcom,sdm845-mdss.yaml b/Docu

[Freedreno] [PATCH] dt-bindings: display/msm: qcom, mdss: fix HDMI PHY node names

2023-01-08 Thread Dmitry Baryshkov
On Qualcomm devices HDMI PHY node names were changed from hdmi-phy to phy. Follow this change. Signed-off-by: Dmitry Baryshkov --- .../devicetree/bindings/display/msm/qcom,mdss.yaml | 6 -- 1 file changed, 6 deletions(-) diff --git a/Documentation/devicetree/bindings/display/msm/qc

[Freedreno] [PATCH v2] drm/msm/dsi: Add missing check for alloc_ordered_workqueue

2023-01-08 Thread Jiasheng Jiang
Add check for the return value of alloc_ordered_workqueue as it may return NULL pointer and cause NULL pointer dereference. Moreover, change the "goto fail" into "return ret" and drop the "fail" label since they are the same. Signed-off-by: Jiasheng Jiang --- Changelog: v1 -> v2: 1. Change the

[Freedreno] [PATCH v2] drm/msm: Add missing check and destroy for alloc_ordered_workqueue

2023-01-08 Thread Jiasheng Jiang
Add check for the return value of alloc_ordered_workqueue as it may return NULL pointer. Moreover, use the destroy_workqueue in the later fails in order to avoid memory leak. Signed-off-by: Jiasheng Jiang --- Changelog: v1 -> v2: 1. Convert "goto err_destroy_workqueue" into "goto err_msm_unit"

[Freedreno] [PATCH v3 1/4] dt-bindings: display/msm: convert MDP5 schema to YAML format

2023-01-08 Thread Dmitry Baryshkov
Convert the mdp5.txt into the yaml format. Changes to the existing (txt) schema: - MSM8996 has additional "iommu" clock, define it separately - Add new properties used on some of platforms: - interconnects, interconnect-names - iommus - power-domains - operating-points-v2, opp-table

[Freedreno] [PATCH v3 4/4] arm64: dts: qcom: add SoC specific compat strings to mdp5 nodes

2023-01-08 Thread Dmitry Baryshkov
Add SoC-specific compat string to the MDP5 device nodes to ease distinguishing between various platforms. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/msm8916.dtsi | 2 +- arch/arm64/boot/dts/qcom/msm8996.dtsi | 2 +- arch/arm64/boot/dts/qcom/sdm630.dtsi | 2 +- arch/arm64/boot/

[Freedreno] [PATCH v3 3/4] ARM: dts: qcom-msm8974: add SoC specific compat string to mdp5 node

2023-01-08 Thread Dmitry Baryshkov
Add SoC-specific compat string to the MDP5 device node to ease distinguishing between various platforms. Signed-off-by: Dmitry Baryshkov --- arch/arm/boot/dts/qcom-msm8974.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/boot/dts/qcom-msm8974.dtsi b/arch/arm/boo

[Freedreno] [PATCH v3 0/4]

2023-01-08 Thread Dmitry Baryshkov
This patch concludes the conversion of display/msm schema from txt files to YAML format. The per-SoC compat (new addition) is required to ease migrating platform support between mdp5 and dpu drivers. Changes since v2: - Fix MSM8998 compatible list: "qcom,msm8998-dpu", "msm,mdp5" to allow handli

[Freedreno] [PATCH v3 2/4] dt-bindings: display/msm: add SoC-specific compats to qcom, mdp5.yaml

2023-01-08 Thread Dmitry Baryshkov
Add platform-specific compatible entries to the qcom,mdp5.yaml to allow distinguishing between various platforms. For msm8998 list qcom,msm8998-dpu rather than -mdp5 to allow this binding to be handled by either of the drivers. Signed-off-by: Dmitry Baryshkov --- .../bindings/display/msm/qcom,md

Re: [Freedreno] [PATCH v2 6/8] drm/msm/dpu: Remove num_enc from topology struct in favour of num_dsc

2023-01-08 Thread Dmitry Baryshkov
On 22/12/2022 01:19, Marijn Suijten wrote: Downstream calls this num_enc yet the DSC patches introduced a new num_dsc struct member, leaving num_enc effectively unused. Fixes: 7e9cc175b159 ("drm/msm/disp/dpu1: Add support for DSC in topology") Signed-off-by: Marijn Suijten --- drivers/gpu/drm

Re: [Freedreno] [PATCH v2 4/8] drm/msm/dpu: Disallow unallocated resources to be returned

2023-01-08 Thread Dmitry Baryshkov
On 09/01/2023 01:28, Dmitry Baryshkov wrote: On 22/12/2022 01:19, Marijn Suijten wrote: In the event that the topology requests resources that have not been created by the system (because they are typically not represented in dpu_mdss_cfg ^1), the resource(s) in global_state (in this case DSC bl

Re: [Freedreno] [PATCH v2 5/8] drm/msm/dpu: Reject topologies for which no DSC blocks are available

2023-01-08 Thread Dmitry Baryshkov
On 22/12/2022 01:19, Marijn Suijten wrote: Resource allocation of DSC blocks should behave more like LMs and CTLs where NULL resources (based on initial hw_blk creation via definitions in the catalog) are skipped ^1. The current hardcoded mapping of DSC blocks however means that resource allocat

Re: [Freedreno] [PATCH v2 4/8] drm/msm/dpu: Disallow unallocated resources to be returned

2023-01-08 Thread Dmitry Baryshkov
On 22/12/2022 01:19, Marijn Suijten wrote: In the event that the topology requests resources that have not been created by the system (because they are typically not represented in dpu_mdss_cfg ^1), the resource(s) in global_state (in this case DSC blocks) remain NULL but will still be returned o

Re: [Freedreno] [PATCH v2 1/8] drm/msm/dpu: Wire up DSC mask for active CTL configuration

2023-01-08 Thread Dmitry Baryshkov
On 22/12/2022 01:19, Marijn Suijten wrote: Active CTLs have to configure what DSC block(s) have to be enabled, and what DSC block(s) have to be flushed; this value was initialized to zero resulting in the necessary register writes to never happen (or would write zero otherwise). This seems to ha

Re: [Freedreno] [PATCH 3/6] drm/msm/dpu: add support for SM8550

2023-01-08 Thread Dmitry Baryshkov
On 04/01/2023 11:08, Neil Armstrong wrote: Add definitions for the display hardware used on Qualcomm SM8550 platform. Signed-off-by: Neil Armstrong --- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 197 + drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h | 1 + dri

Re: [Freedreno] [PATCH 2/6] dt-bindings: display/msm: document the display hardware for SM8550

2023-01-08 Thread Dmitry Baryshkov
On 04/01/2023 11:08, Neil Armstrong wrote: Document the MDSS and DPU blocks found on the Qualcomm SM8550 platform. Signed-off-by: Neil Armstrong Please split this into two patches: one for mdss, one for dpu. --- .../bindings/display/msm/qcom,sm8550-dpu.yaml | 134 + .../bind

Re: [Freedreno] [PATCH 0/6] drm/msm: add support for SM8450

2023-01-08 Thread Dmitry Baryshkov
On 04/01/2023 11:08, Neil Armstrong wrote: This adds support for the MDSS/DPU/DSI on the Qualcomm SM8550 platform. Nit: please change the subject for v2. It's 8550, not 8450. This patchset is based on the SM8450 display support serie at [1]. In order to work, the following patchsets are req

Re: [Freedreno] [PATCH 1/6] dt-bindings: display/msm: document the SM8550 DSI PHY

2023-01-08 Thread Dmitry Baryshkov
On 06/01/2023 17:41, Krzysztof Kozlowski wrote: On 04/01/2023 10:08, Neil Armstrong wrote: Document the SM8550 DSI PHY which is very close from the 7nm and 5nm DSI PHYs found in earlier platforms. Signed-off-by: Neil Armstrong --- Documentation/devicetree/bindings/display/msm/dsi-phy-7nm.yam

Re: [Freedreno] [PATCH RESEND] drm/msm: Add missing check and destroy for alloc_ordered_workqueue

2023-01-08 Thread Dmitry Baryshkov
On 06/01/2023 10:47, Jiasheng Jiang wrote: Add check for the return value of alloc_ordered_workqueue as it may return NULL pointer. Moreover, use the destroy_workqueue in the later fails in order to avoid memory leak. Fixes: c8afe684c95c ("drm/msm: basic KMS driver for snapdragon") Signed-off-by

Re: [Freedreno] [PATCH] drm/msm/dsi: Add missing check for alloc_ordered_workqueue

2023-01-08 Thread Dmitry Baryshkov
On 06/01/2023 04:56, Jiasheng Jiang wrote: Add check for the return value of alloc_ordered_workqueue as it may return NULL pointer and cause NULL pointer dereference. Moreover, change the "return ret" into "goto fail" in order to be consistent with the others. Fixes: a689554ba6ed ("drm/msm: Init

Re: [Freedreno] [PATCH] drm/msm/hdmi: Add missing check for alloc_ordered_workqueue

2023-01-08 Thread Dmitry Baryshkov
On 06/01/2023 04:30, Jiasheng Jiang wrote: Add check for the return value of alloc_ordered_workqueue as it may return NULL pointer and cause NULL pointer dereference in `hdmi_hdcp.c` and `hdmi_hpd.c`. Fixes: c6a57a50ad56 ("drm/msm/hdmi: add hdmi hdcp support (V3)") Signed-off-by: Jiasheng Jiang

Re: [Freedreno] [PATCH] drm/msm/dpu: Add check for cstate

2023-01-08 Thread Dmitry Baryshkov
On 08/01/2023 23:56, Dmitry Baryshkov wrote: On 06/12/2022 10:05, Jiasheng Jiang wrote: As kzalloc may fail and return NULL pointer, it should be better to check cstate in order to avoid the NULL pointer dereference in __drm_atomic_helper_crtc_reset. Fixes: 1cff7440a86e ("drm/msm: Convert to us

Re: [Freedreno] [PATCH] drm/msm/dpu: Add check for cstate

2023-01-08 Thread Dmitry Baryshkov
On 06/12/2022 10:05, Jiasheng Jiang wrote: As kzalloc may fail and return NULL pointer, it should be better to check cstate in order to avoid the NULL pointer dereference in __drm_atomic_helper_crtc_reset. Fixes: 1cff7440a86e ("drm/msm: Convert to using __drm_atomic_helper_crtc_reset() for rese

Re: [Freedreno] [PATCH v5 02/12] drm/msm/dpu: Introduce SC8280XP

2023-01-08 Thread Dmitry Baryshkov
On 09/12/2022 01:31, Kuogee Hsieh wrote: On 12/7/2022 2:00 PM, Bjorn Andersson wrote: From: Bjorn Andersson The Qualcomm SC8280XP platform contains DPU version 8.0.0, has 9 interfaces, 2 DSI controllers and 4 DisplayPort controllers. Extend the necessary definitions and describe the DPU in th

[Freedreno] [PATCH] drm/msm/dpu: sort entries in the HW catalog

2023-01-08 Thread Dmitry Baryshkov
Different entries into the catalog were added quite randomly. Enforce the sorting order of some kind. It is not alphabetic to prevent the patch from growing uncontrollably. Thus SDM comes before SC and SM platforms and QCM is kept as the last one. There are no functional changes in this patch. Sig

Re: [Freedreno] [PATCH v4 04/11] drm/msm/dpu: Add support for SM8350

2023-01-08 Thread Dmitry Baryshkov
On 30/12/2022 17:35, Robert Foss wrote: Add compatibles string, "qcom,sm8350-dpu", for the display processing unit used on Qualcomm SM8350 platform. Signed-off-by: Robert Foss --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 1 + 1 file changed, 1 insertion(+) Reviewed-by: Dmitry Baryshkov

Re: [Freedreno] [PATCH v3 1/1] dt-bindings: msm: dsi-phy-28nm: Add missing qcom, dsi-phy-regulator-ldo-mode

2023-01-08 Thread Rob Herring
On Thu, 29 Dec 2022 12:44:38 +, Bryan O'Donoghue wrote: > Add in missing qcom,dsi-phy-regulator-ldo-mode to the 28nm DSI PHY. > When converting from .txt to .yaml we missed this one. > > Fixes: 4dbe55c97741 ("dt-bindings: msm: dsi: add yaml schemas for DSI > bindings") > Reviewed-by: Dmitry

Re: [Freedreno] [PATCH 2/2] dt-bindings: display: msm: drop unneeded list for single compatible

2023-01-08 Thread Rob Herring
On Sun, 25 Dec 2022 12:59:25 +0100, Krzysztof Kozlowski wrote: > With only one compatible, there is no need to define it as list (items). > > Signed-off-by: Krzysztof Kozlowski > --- > .../devicetree/bindings/display/msm/qcom,msm8998-dpu.yaml | 3 +-- > .../devicetree/bindings/display/msm

Re: [Freedreno] [PATCH 1/2] dt-bindings: display: msm: drop redundant part of title

2023-01-08 Thread Rob Herring
On Sun, 25 Dec 2022 12:59:24 +0100, Krzysztof Kozlowski wrote: > The Devicetree bindings document does not have to say in the title that > contains "DT properties", but instead just describe the hardware. > > Signed-off-by: Krzysztof Kozlowski > --- > .../devicetree/bindings/display/msm/dsi-ph

[Freedreno] [PATCH v2 11/13] drm/bridge: lt9611: rework infoframes handling

2023-01-08 Thread Dmitry Baryshkov
Rework handling infoframes: - Write full HDMI AVI infoframe instead of just fixing the VIC value - Also send the HDMI Vendor Specific infoframe, as recommended by the HDMI spec. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/bridge/lontium-lt9611.c | 57 +++-- 1 file c

[Freedreno] [PATCH v2 08/13] drm/bridge: lt9611: attach to the next bridge

2023-01-08 Thread Dmitry Baryshkov
The bindings require that there is a next bridge after the lt9611. If nothing else it can be the hdmi-connector (as used on the RB3 platform, see sdm845-db845c.dts). Bring in the next bridge into the drm bridges chain and attach to it. Since lt9611 is not anymore the last bridge in the chain, thi

[Freedreno] [PATCH v2 07/13] drm/bridge: lt9611: rework the mode_set function

2023-01-08 Thread Dmitry Baryshkov
The mode_set callback is deprectated for drm_bridges in favour of using atomic_enable callback. Move corresponding code into the function lt9611_bridge_atomic_enable() and turn lt9611_bridge_pre_enable() into the proper atomic_pre_enable callback. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/

[Freedreno] [PATCH v2 05/13] drm/bridge: lt9611: fix clock calculation

2023-01-08 Thread Dmitry Baryshkov
Instead of having several fixed values for the pcr register, calculate it before programming. This allows the bridge to support most of the display modes. Fixes: 23278bf54afe ("drm/bridge: Introduce LT9611 DSI to HDMI bridge") Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/bridge/lontium-lt

[Freedreno] [PATCH v2 13/13] drm/bridge: lt9611: properly program the dual host mode

2023-01-08 Thread Dmitry Baryshkov
If the bridge is connected using both DSI ports, the driver should use both of them all the time. Correct programming sequence to always use dual-port mode if both dsi0 and dsi1 are connected. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/bridge/lontium-lt9611.c | 28 --

[Freedreno] [PATCH v2 12/13] drm/bridge: lt9611: stop filtering modes via the table

2023-01-08 Thread Dmitry Baryshkov
The lt9611 bridge can support different modes, it makes no sense to list them in the table. Drop the table and check the number of interfaces using the fixed value. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/bridge/lontium-lt9611.c | 41 +++-- 1 file changed, 4 inser

[Freedreno] [PATCH v2 10/13] drm/bridge: lt9611: simplify video timings programming

2023-01-08 Thread Dmitry Baryshkov
Inline calculated values to simplify the calculation in lt9611_mipi_video_setup(). Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/bridge/lontium-lt9611.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/bridge/lontium-lt9611.c b/drivers/gpu/drm/bridge

[Freedreno] [PATCH v2 09/13] drm/bridge: lt9611: fix sync polarity for DVI output

2023-01-08 Thread Dmitry Baryshkov
Attaching DVI sink to the lt9611 requires different setup. Fix the register write to make the DVI displays sync onto the correct sync pulse. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/bridge/lontium-lt9611.c | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/dr

[Freedreno] [PATCH v2 04/13] drm/bridge: lt9611: fix programming of video modes

2023-01-08 Thread Dmitry Baryshkov
Program the upper part of the hfront_porch into the proper register. Fixes: 23278bf54afe ("drm/bridge: Introduce LT9611 DSI to HDMI bridge") Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/bridge/lontium-lt9611.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/g

[Freedreno] [PATCH v2 06/13] drm/bridge: lt9611: pass a pointer to the of node

2023-01-08 Thread Dmitry Baryshkov
Pass a pointer to the OF node while registering lt9611 MIPI device. Fixes: 23278bf54afe ("drm/bridge: Introduce LT9611 DSI to HDMI bridge") Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/bridge/lontium-lt9611.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/

[Freedreno] [PATCH v2 02/13] drm/bridge: lt9611: fix HPD reenablement

2023-01-08 Thread Dmitry Baryshkov
The driver will reset the bridge in the atomic_pre_enable(). However this will also drop the HPD interrupt state. Instead of resetting the bridge, properly wake it up. This fixes the HPD interrupt delivery after the disable/enable cycle. Fixes: 23278bf54afe ("drm/bridge: Introduce LT9611 DSI to HD

[Freedreno] [PATCH v2 03/13] drm/bridge: lt9611: fix polarity programming

2023-01-08 Thread Dmitry Baryshkov
Fix programming of hsync and vsync polarities Fixes: 23278bf54afe ("drm/bridge: Introduce LT9611 DSI to HDMI bridge") Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/bridge/lontium-lt9611.c | 17 - 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm

[Freedreno] [PATCH v2 01/13] drm/bridge: lt9611: fix sleep mode setup

2023-01-08 Thread Dmitry Baryshkov
On atomic_post_disable the bridge goes to the low power state. However the code disables too much of the chip, so the HPD event is not being detected and delivered to the host. Reduce the power saving in order to get the HPD event. Fixes: 23278bf54afe ("drm/bridge: Introduce LT9611 DSI to HDMI bri

[Freedreno] [PATCH v2 00/13] drm/bridge: lt9611: several fixes and improvements

2023-01-08 Thread Dmitry Baryshkov
A series of patches to fix mode programming for the Lontium lt9611 DSI-to-HDMI bridge (found e.g. on the Thundercomm RB3/Dragonboard845c platform). Changes since v1: - Fixed the double-DSI check to look for the lt9611->dsi1_node rather than lt9611->dsi1, modesetting happens before lt9611->dsi1