[Freedreno] [PATCH v6 4/4] drm/msm: stop storing the array of CRTCs in struct msm_drm_private

2022-06-17 Thread Dmitry Baryshkov
The array of CRTC in the struct msm_drm_private duplicates a list of CRTCs in the drm_device. Drop it and use the existing list for CRTC enumeration. Reported-by: kernel test robot Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 2 +-

[Freedreno] [PATCH v6 2/4] drm/msm/mdp4: convert to drm_crtc_handle_vblank()

2022-06-17 Thread Dmitry Baryshkov
Stop using deprecated drm_handle_vblank(), use drm_crtc_handle_vblank() instead. Reviewed-by: Abhinav Kumar Reviewed-by: Stephen Boyd Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/mdp4/mdp4_irq.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git

[Freedreno] [PATCH v6 3/4] drm/msm/mdp5: convert to drm_crtc_handle_vblank()

2022-06-17 Thread Dmitry Baryshkov
Stop using deprecated drm_handle_vblank(), use drm_crtc_handle_vblank() instead. Reviewed-by: Abhinav Kumar Reviewed-by: Stephen Boyd Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/mdp5/mdp5_irq.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git

[Freedreno] [PATCH v6 1/4] drm/msm: clean event_thread->worker in case of an error

2022-06-17 Thread Dmitry Baryshkov
If worker creation fails, nullify the event_thread->worker, so that msm_drm_uninit() doesn't try accessing invalid memory location. While we are at it, remove duplicate assignment to the ret variable. Fixes: 1041dee2178f ("drm/msm: use kthread_create_worker instead of kthread_run")

[Freedreno] [PATCH v6 0/4] drm/msm: convet to drm_crtc_handle_vblank()

2022-06-17 Thread Dmitry Baryshkov
This patchseries replaces drm_handle_vblank() with drm_crtc_handle_vblank(). As a bonus result of this conversion it is possible to drop the stored array of allocated CRTCs and use the core CRTC iterators. Changes since v5: - Clean up the event_thread->worker in case of an error to fix possible

[Freedreno] [PATCH v2 3/3] drm/msm/dp: remove dp_display_en/disable prototypes and data argument

2022-06-17 Thread Dmitry Baryshkov
Remove unused dp_display_en/disable prototypes. While we are at it, remove extra 'data' argument that is unused. Signed-off-by: Dmitry Baryshkov --- Changes since v1: - Rebased and dropped the dp_display_enable() chunk --- drivers/gpu/drm/msm/dp/dp_display.c | 9 +++-- 1 file changed, 3

[Freedreno] [PATCH v2 2/3] drm/msm/dp: rename second dp_display_enable()'s argument

2022-06-17 Thread Dmitry Baryshkov
To follow up recent changes, rename (and change type of) second dp_display_enable()'s argument from generic u32 data to bool force_link_train, which is later passed to dp_ctrl_on_stream(). Signed-off-by: Dmitry Baryshkov --- Changes since v1: - Added patch ---

[Freedreno] [PATCH v2 1/3] drm/msm/dp: remove unused stubs

2022-06-17 Thread Dmitry Baryshkov
Refactoring DP code transformed several functions into empty stubs. Remove them. Reviewed-by: Stephen Boyd Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/dp/dp_display.c | 35 - 1 file changed, 35 deletions(-) diff --git

Re: [Freedreno] [PATCH 2/3] drm/msm/dp: Remove pixel_rate from struct dp_ctrl

2022-06-17 Thread Dmitry Baryshkov
On 17/06/2022 23:47, Stephen Boyd wrote: This struct member is stored to in the function that calls the function which uses it. That's possible with a function argument instead of storing to a struct member. Pass the pixel_rate as an argument instead to simplify the code. Note that

Re: [Freedreno] [PATCH 1/3] drm/msm/dp: Reorganize code to avoid forward declaration

2022-06-17 Thread Dmitry Baryshkov
On 17/06/2022 23:47, Stephen Boyd wrote: Let's move these functions around to avoid having to forward declare dp_ctrl_on_stream_phy_test_report(). Also remove dp_ctrl_reinitialize_mainlink() forward declaration because we're doing that sort of task. Cc: Kuogee Hsieh Signed-off-by: Stephen Boyd

Re: [Freedreno] [PATCH v5 3/3] drm/msm: stop storing the array of CRTCs in struct msm_drm_private

2022-06-17 Thread Dmitry Baryshkov
On Fri, 17 Jun 2022 at 23:52, Stephen Boyd wrote: > > Quoting Dmitry Baryshkov (2022-06-17 12:14:29) > > diff --git a/drivers/gpu/drm/msm/msm_drv.c b/drivers/gpu/drm/msm/msm_drv.c > > index 44485363f37a..567e77dae43b 100644 > > --- a/drivers/gpu/drm/msm/msm_drv.c > > +++

Re: [Freedreno] [PATCH 3/3] arm64: dts: qcom: msm8996: add #clock-cells to the HDMI PHY node

2022-06-17 Thread Stephen Boyd
Quoting Dmitry Baryshkov (2022-06-17 03:36:08) > Add #clock-cells property to the HDMI PHY device node to let other nodes > resolve the hdmipll clock. > > Signed-off-by: Dmitry Baryshkov > --- Reviewed-by: Stephen Boyd

Re: [Freedreno] [PATCH 2/3] drm/msm/hdmi: make hdmi_phy_8996 OF clk provider

2022-06-17 Thread Stephen Boyd
Quoting Dmitry Baryshkov (2022-06-17 03:36:07) > On MSM8996 the HDMI PHY provides the PLL clock to the MMCC. As we are > preparing to convert the MSM8996 to use DT clocks properties (rather > than global clock names), register the OF clock provider. > > Signed-off-by: Dmitry Baryshkov > ---

Re: [Freedreno] [PATCH] drm/msm/hdmi: support attaching the "next" bridge

2022-06-17 Thread Stephen Boyd
Quoting Dmitry Baryshkov (2022-06-16 01:50:57) > There might be a chain of bridges attached to the HDMI node > (including but not limited to the display-connector bridge). Add support > for attaching them right to the HDMI bridge chain. > > Signed-off-by: Dmitry Baryshkov > --- Reviewed-by:

Re: [Freedreno] [PATCH] drm/msm/hdmi: drop empty bridge callbacks

2022-06-17 Thread Stephen Boyd
Quoting Dmitry Baryshkov (2022-06-16 01:50:54) > Drop empty callbacks msm_hdmi_bridge_enable() and > msm_hdmi_bridge_disable(). > > Signed-off-by: Dmitry Baryshkov > --- Reviewed-by: Stephen Boyd

Re: [Freedreno] [PATCH v5 3/3] drm/msm: stop storing the array of CRTCs in struct msm_drm_private

2022-06-17 Thread Stephen Boyd
Quoting Dmitry Baryshkov (2022-06-17 12:14:29) > diff --git a/drivers/gpu/drm/msm/msm_drv.c b/drivers/gpu/drm/msm/msm_drv.c > index 44485363f37a..567e77dae43b 100644 > --- a/drivers/gpu/drm/msm/msm_drv.c > +++ b/drivers/gpu/drm/msm/msm_drv.c > @@ -427,20 +428,23 @@ static int msm_drm_init(struct

Re: [Freedreno] [PATCH v5 2/3] drm/msm/mdp5: convert to drm_crtc_handle_vblank()

2022-06-17 Thread Stephen Boyd
Quoting Dmitry Baryshkov (2022-06-17 12:14:28) > Stop using deprecated drm_handle_vblank(), use drm_crtc_handle_vblank() > instead. > > Reviewed-by: Abhinav Kumar > Signed-off-by: Dmitry Baryshkov > --- Reviewed-by: Stephen Boyd

Re: [Freedreno] [PATCH v5 1/3] drm/msm/mdp4: convert to drm_crtc_handle_vblank()

2022-06-17 Thread Stephen Boyd
Quoting Dmitry Baryshkov (2022-06-17 12:14:27) > Stop using deprecated drm_handle_vblank(), use drm_crtc_handle_vblank() > instead. > > Reviewed-by: Abhinav Kumar > Signed-off-by: Dmitry Baryshkov > --- Reviewed-by: Stephen Boyd

[Freedreno] [PATCH 3/3] drm/msm/dp: Get rid of dp_ctrl_on_stream_phy_test_report()

2022-06-17 Thread Stephen Boyd
This API isn't really more than a couple lines now that we don't store the pixel_rate to the struct member. Inline it into the caller. Cc: Kuogee Hsieh Signed-off-by: Stephen Boyd --- drivers/gpu/drm/msm/dp/dp_ctrl.c | 40 1 file changed, 15 insertions(+), 25

[Freedreno] [PATCH 2/3] drm/msm/dp: Remove pixel_rate from struct dp_ctrl

2022-06-17 Thread Stephen Boyd
This struct member is stored to in the function that calls the function which uses it. That's possible with a function argument instead of storing to a struct member. Pass the pixel_rate as an argument instead to simplify the code. Note that dp_ctrl_link_maintenance() was storing the pixel_rate

[Freedreno] [PATCH 1/3] drm/msm/dp: Reorganize code to avoid forward declaration

2022-06-17 Thread Stephen Boyd
Let's move these functions around to avoid having to forward declare dp_ctrl_on_stream_phy_test_report(). Also remove dp_ctrl_reinitialize_mainlink() forward declaration because we're doing that sort of task. Cc: Kuogee Hsieh Signed-off-by: Stephen Boyd --- drivers/gpu/drm/msm/dp/dp_ctrl.c |

[Freedreno] [PATCH 0/3] drm/msm/dp: More cleanups for force link train

2022-06-17 Thread Stephen Boyd
These patches do a little cleanup on the v9 patch from Kuogee. Stephen Boyd (3): drm/msm/dp: Reorganize code to avoid forward declaration drm/msm/dp: Remove pixel_rate from struct dp_ctrl drm/msm/dp: Get rid of dp_ctrl_on_stream_phy_test_report() drivers/gpu/drm/msm/dp/dp_ctrl.c | 145

Re: [Freedreno] [PATCH 2/2] drm/msm/dp: remove dp_display_en/disable prototypes and data argument

2022-06-17 Thread Dmitry Baryshkov
On 17/06/2022 23:15, Stephen Boyd wrote: Quoting Dmitry Baryshkov (2022-06-17 12:49:21) Remove unused dp_display_en/disable prototypes. While we are at it, remove extra 'data' argument that is unused. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/dp/dp_display.c | 13 +

Re: [Freedreno] [PATCH 1/2] drm/msm/dp: remove unused stubs

2022-06-17 Thread Stephen Boyd
Quoting Dmitry Baryshkov (2022-06-17 12:49:20) > Refactoring DP code transformed several functions into empty stubs. > Remove them. > > Signed-off-by: Dmitry Baryshkov > --- Reviewed-by: Stephen Boyd

Re: [Freedreno] [PATCH 2/2] drm/msm/dp: remove dp_display_en/disable prototypes and data argument

2022-06-17 Thread Stephen Boyd
Quoting Dmitry Baryshkov (2022-06-17 12:49:21) > Remove unused dp_display_en/disable prototypes. While we are at it, > remove extra 'data' argument that is unused. > > Signed-off-by: Dmitry Baryshkov > --- > drivers/gpu/drm/msm/dp/dp_display.c | 13 + > 1 file changed, 5

[Freedreno] [PATCH 2/2] drm/msm/dp: remove dp_display_en/disable prototypes and data argument

2022-06-17 Thread Dmitry Baryshkov
Remove unused dp_display_en/disable prototypes. While we are at it, remove extra 'data' argument that is unused. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/dp/dp_display.c | 13 + 1 file changed, 5 insertions(+), 8 deletions(-) diff --git

[Freedreno] [PATCH 1/2] drm/msm/dp: remove unused stubs

2022-06-17 Thread Dmitry Baryshkov
Refactoring DP code transformed several functions into empty stubs. Remove them. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/dp/dp_display.c | 35 - 1 file changed, 35 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_display.c

[Freedreno] [PATCH v5 3/3] drm/msm: stop storing the array of CRTCs in struct msm_drm_private

2022-06-17 Thread Dmitry Baryshkov
The array of CRTC in the struct msm_drm_private duplicates a list of CRTCs in the drm_device. Drop it and use the existing list for CRTC enumeration. Reported-by: kernel test robot Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 2 +-

[Freedreno] [PATCH v5 1/3] drm/msm/mdp4: convert to drm_crtc_handle_vblank()

2022-06-17 Thread Dmitry Baryshkov
Stop using deprecated drm_handle_vblank(), use drm_crtc_handle_vblank() instead. Reviewed-by: Abhinav Kumar Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/mdp4/mdp4_irq.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git

[Freedreno] [PATCH v5 2/3] drm/msm/mdp5: convert to drm_crtc_handle_vblank()

2022-06-17 Thread Dmitry Baryshkov
Stop using deprecated drm_handle_vblank(), use drm_crtc_handle_vblank() instead. Reviewed-by: Abhinav Kumar Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/mdp5/mdp5_irq.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git

[Freedreno] [PATCH v5 0/3] drm/msm: convet to drm_crtc_handle_vblank()

2022-06-17 Thread Dmitry Baryshkov
This patchseries replaces drm_handle_vblank() with drm_crtc_handle_vblank(). As a bonus result of this conversion it is possible to drop the stored array of allocated CRTCs and use the core CRTC iterators. Changes since v4: - Removed the duplicate word 'duplicate' from the last patch'es commit

Re: [Freedreno] [PATCH] drm/msm/dpu: limit wb modes based on max_mixer_width

2022-06-17 Thread Dmitry Baryshkov
On 16/06/2022 22:26, Abhinav Kumar wrote: As explained in [1], using max_linewidth to limit the modes does not seem to remove 4K modes on chipsets such as sm8250 where the max_linewidth actually supports 4k. This would have been alright if dual SSPP support was present but otherwise fails the

[Freedreno] [PATCH v4 1/3] drm/msm/mdp4: convert to drm_crtc_handle_vblank()

2022-06-17 Thread Dmitry Baryshkov
Stop using deprecated drm_handle_vblank(), use drm_crtc_handle_vblank() instead. Reviewed-by: Abhinav Kumar Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/mdp4/mdp4_irq.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git

[Freedreno] [PATCH v4 2/3] drm/msm/mdp5: convert to drm_crtc_handle_vblank()

2022-06-17 Thread Dmitry Baryshkov
Stop using deprecated drm_handle_vblank(), use drm_crtc_handle_vblank() instead. Reviewed-by: Abhinav Kumar Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/mdp5/mdp5_irq.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git

[Freedreno] [PATCH v4 3/3] drm/msm: stop storing the array of CRTCs in struct msm_drm_private

2022-06-17 Thread Dmitry Baryshkov
Handling the array of CRTC duplicate the struct msm_drm_private duplicates a list of CRTCs in the drm_device. Drop it and use the existing list for CRTC enumeration. Reported-by: kernel test robot Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 2 +-

[Freedreno] [PATCH v4 0/3] drm/msm: convet to drm_crtc_handle_vblank()

2022-06-17 Thread Dmitry Baryshkov
This patchseries replaces drm_handle_vblank() with drm_crtc_handle_vblank(). As a bonus result of this conversion it is possible to drop the stored array of allocated CRTCs and use the core CRTC iterators. Changes since v3: - In msm_drm_init simplify the code by using an interim var for the

[Freedreno] [PATCH v3 3/3] drm/msm: stop storing the array of CRTCs in struct msm_drm_private

2022-06-17 Thread Dmitry Baryshkov
Handling the array of CRTC duplicate the struct msm_drm_private duplicates a list of CRTCs in the drm_device. Drop it and use the existing list for CRTC enumeration. Reported-by: kernel test robot Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 2 +-

[Freedreno] [PATCH v3 2/3] drm/msm/mdp5: convert to drm_crtc_handle_vblank()

2022-06-17 Thread Dmitry Baryshkov
Stop using deprecated drm_handle_vblank(), use drm_crtc_handle_vblank() instead. Reviewed-by: Abhinav Kumar Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/mdp5/mdp5_irq.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git

[Freedreno] [PATCH v3 1/3] drm/msm/mdp4: convert to drm_crtc_handle_vblank()

2022-06-17 Thread Dmitry Baryshkov
Stop using deprecated drm_handle_vblank(), use drm_crtc_handle_vblank() instead. Reviewed-by: Abhinav Kumar Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/mdp4/mdp4_irq.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git

Re: [Freedreno] [PATCH v8 2/2] drm/msm/dp: clean up pixel_rate from dp_ctrl.c

2022-06-17 Thread kernel test robot
tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/intel-lab-lkp/linux/commits/Kuogee-Hsieh/force-link-training-for-display-resolution-change/20220617-00 base: git

[Freedreno] [PATCH] arm64: dts: qcom: msm8996: add second DSI interface

2022-06-17 Thread Dmitry Baryshkov
Add device nodes for the DSI1, second DSI interface found on MSM8996/APQ8096 platforms. For example on db820c it is routed to the secondary HS expansion connector. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/msm8996.dtsi | 73 +++ 1 file changed, 73

[Freedreno] [PATCH 3/3] arm64: dts: qcom: msm8996: add #clock-cells to the HDMI PHY node

2022-06-17 Thread Dmitry Baryshkov
Add #clock-cells property to the HDMI PHY device node to let other nodes resolve the hdmipll clock. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/msm8996.dtsi | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/msm8996.dtsi

[Freedreno] [PATCH 2/3] drm/msm/hdmi: make hdmi_phy_8996 OF clk provider

2022-06-17 Thread Dmitry Baryshkov
On MSM8996 the HDMI PHY provides the PLL clock to the MMCC. As we are preparing to convert the MSM8996 to use DT clocks properties (rather than global clock names), register the OF clock provider. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/hdmi/hdmi_phy_8996.c | 15 ++-

[Freedreno] [PATCH 1/3] dt-bindings: phy: qcom, hdmi-phy-qmp: add clock-cells

2022-06-17 Thread Dmitry Baryshkov
As the QMP HDMI PHY is a clock provider, add constant #clock-cells property. For the compatibility with older DTs the property is not marked as required. Signed-off-by: Dmitry Baryshkov --- Documentation/devicetree/bindings/phy/qcom,hdmi-phy-qmp.yaml | 4 1 file changed, 4 insertions(+)

[Freedreno] [PATCH 0/3] drm/msm/hdmi: turn MSM8996 HDMI PHY into OF clock provider

2022-06-17 Thread Dmitry Baryshkov
On MSM8996 the HDMI PHY is the QMP PHY, it provides an HDMI PLL clock used by the MMCC. Add support for providing this clock to the OF framework by registerding the clock provider and adding #clock-cells property to the DT node. Dmitry Baryshkov (3): dt-bindings: phy: qcom,hdmi-phy-qmp: add