Re: [Freedreno] [RFC PATCH 1/4] drm/msm/mdss: convert UBWC setup to use match data

2023-01-11 Thread Marijn Suijten
On 2023-01-09 12:32:18, Abhinav Kumar wrote: > >> On 12/7/2022 4:08 PM, Dmitry Baryshkov wrote: > >>> +struct msm_mdss_data { > >>> +    u32 ubwc_version; > >>> +    u32 ubwc_swizzle; > >>> +    u32 ubwc_static; > >>> +    u32 highest_bank_bit; > >>> +    u32 macrotile_mode; > >>> +}; This magic

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

2023-01-11 Thread Neil Armstrong
On 08/01/2023 17:56, Dmitry Baryshkov wrote: 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. Sig

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

2023-01-11 Thread Neil Armstrong
On 08/01/2023 17:56, Dmitry Baryshkov wrote: 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 i

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

2023-01-11 Thread Neil Armstrong
On 08/01/2023 17:56, Dmitry Baryshkov wrote: 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/

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

2023-01-11 Thread Neil Armstrong
On 08/01/2023 17:56, Dmitry Baryshkov wrote: 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 ++

Re: [Freedreno] [v3, 3/7] drm/bridge_connector: rely on drm_kms_helper_poll_* for HPD enablement

2023-01-11 Thread Marek Szyprowski
On 02.11.2022 19:07, Dmitry Baryshkov wrote: > Use drm_connector's helpers enable_hpd and disable_hpd to enable and > disable HPD automatically by the means of drm_kms_helper_poll_* > functions. As the drm_bridge_connector_enable_hpd() and > drm_bridge_connector_disable_hpd() functions are now unus

Re: [Freedreno] [PATCH] dt-bindings: msm/dsi: Don't require vcca-supply on 14nm PHY

2023-01-11 Thread Rob Herring
On Wed, Nov 30, 2022 at 7:58 AM Konrad Dybcio wrote: > > On some SoCs (hello SM6115) vcca-supply is not wired to any smd-rpm > or rpmh regulator, but instead powered by the VDD_MX line, which is > voted for in the DSI ctrl node. > > Signed-off-by: Konrad Dybcio > --- > Documentation/devicetree/b

Re: [Freedreno] [RFC PATCH 1/4] drm/msm/mdss: convert UBWC setup to use match data

2023-01-11 Thread Dmitry Baryshkov
On 11/01/2023 10:44, Marijn Suijten wrote: On 2023-01-09 12:32:18, Abhinav Kumar wrote: On 12/7/2022 4:08 PM, Dmitry Baryshkov wrote: +struct msm_mdss_data { +    u32 ubwc_version; +    u32 ubwc_swizzle; +    u32 ubwc_static; +    u32 highest_bank_bit; +    u32 macrotile_mode; +}; This mag

Re: [Freedreno] [PATCH] drm/msm/gpu: Fix potential double-free

2023-01-11 Thread Rob Clark
On Tue, Jan 10, 2023 at 1:29 PM Rob Clark wrote: > > From: Rob Clark > > If userspace was calling the MSM_SET_PARAM ioctl on multiple threads to > set the COMM or CMDLINE param, it could trigger a race causing the > previous value to be kfree'd multiple times. Fix this by serializing on > the gp

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

2023-01-11 Thread Dmitry Baryshkov
On 11/01/2023 12:57, Neil Armstrong wrote: On 08/01/2023 17:56, Dmitry Baryshkov wrote: 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 ---   dri

[Freedreno] [PATCH 1/2] drm/msm/dsi: add a helper method to compute the dsi byte clk

2023-01-11 Thread Abhinav Kumar
Re-arrange the dsi_calc_pclk method to two helpers, one to compute the DSI byte clk and the other to compute the pclk. This makes the separation of the two clean and also allows clients to compute and use the dsi byte clk separately. changes in v2: - move the assignments to definition lin

[Freedreno] [PATCH 2/2] drm/msm/dsi: implement opp table based check for dsi_mgr_bridge_mode_valid()

2023-01-11 Thread Abhinav Kumar
Currently there is no protection against a user trying to set an unsupported mode on DSI. Implement a check based on the opp table whether the byte clock for the mode can be supported by validating whether an opp table entry exists. For devices which have not added opp table support yet, skip this

Re: [Freedreno] [v11] drm/msm/disp/dpu1: add support for dspp sub block flush in sc7280

2023-01-11 Thread Marijn Suijten
On 2022-12-20 05:25:19, Kalyan Thota wrote: > Flush mechanism for DSPP blocks has changed in sc7280 family, it > allows individual sub blocks to be flushed in coordination with > master flush control. > > Representation: master_flush && (PCC_flush | IGC_flush .. etc ) > > This change adds necessa

Re: [Freedreno] [RFC PATCH 1/4] drm/msm/mdss: convert UBWC setup to use match data

2023-01-11 Thread Marijn Suijten
On 2023-01-11 17:11:03, Dmitry Baryshkov wrote: > On 11/01/2023 10:44, Marijn Suijten wrote: > > On 2023-01-09 12:32:18, Abhinav Kumar wrote: > > > On 12/7/2022 4:08 PM, Dmitry Baryshkov wrote: > > > > +struct msm_mdss_data { > > +    u32 ubwc_version; > > +    u32 ubwc_swizzle;

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

2023-01-11 Thread Marijn Suijten
On 2023-01-10 06:40:27, Dmitry Baryshkov wrote: > On 09/01/2023 09:49, Marijn Suijten wrote: > > On 2023-01-09 07:01:49, Dmitry Baryshkov wrote: > >> +description: | > > > > Should multiline descriptions be treated as a oneline string with `>`? > > Ack, I'm fine with either of them, let's us

Re: [Freedreno] [RFC PATCH v3 0/3] Support for Solid Fill Planes

2023-01-11 Thread Daniel Vetter
On Fri, Jan 06, 2023 at 04:33:04PM -0800, Abhinav Kumar wrote: > Hi Daniel > > Thanks for looking into this series. > > On 1/6/2023 1:49 PM, Dmitry Baryshkov wrote: > > On Fri, 6 Jan 2023 at 20:41, Daniel Vetter wrote: > > > > > > On Fri, Jan 06, 2023 at 05:43:23AM +0200, Dmitry Baryshkov wrote

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

2023-01-11 Thread Dmitry Baryshkov
On 12/01/2023 00:29, Marijn Suijten wrote: On 2023-01-10 06:40:27, Dmitry Baryshkov wrote: On 09/01/2023 09:49, Marijn Suijten wrote: On 2023-01-09 07:01:49, Dmitry Baryshkov wrote: +description: | Should multiline descriptions be treated as a oneline string with `>`? Ack, I'm fine w

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

2023-01-11 Thread Marijn Suijten
On 2023-01-09 20:30:01, Dmitry Baryshkov wrote: > The usual problem is that there are two dimensions: with each > generations there are new (and removed) features, but on the other hand > within each generation there are units that are feature-rich and the > ones that are feature-deprived. qcm2

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

2023-01-11 Thread Marijn Suijten
On 2023-01-12 00:31:33, Dmitry Baryshkov wrote: > On 12/01/2023 00:29, Marijn Suijten wrote: > > On 2023-01-10 06:40:27, Dmitry Baryshkov wrote: > >> On 09/01/2023 09:49, Marijn Suijten wrote: > >>> On 2023-01-09 07:01:49, Dmitry Baryshkov wrote: > > > +description: | > >>> > >>> Should m

[Freedreno] [PATCH v2 1/2] drm/msm/dsi: add a helper method to compute the dsi byte clk

2023-01-11 Thread Abhinav Kumar
Re-arrange the dsi_calc_pclk method to two helpers, one to compute the DSI byte clk and the other to compute the pclk. This makes the separation of the two clean and also allows clients to compute and use the dsi byte clk separately. changes in v2: - move the assignments to definition lin

[Freedreno] [PATCH v2 2/2] drm/msm/dsi: implement opp table based check for dsi_mgr_bridge_mode_valid()

2023-01-11 Thread Abhinav Kumar
Currently there is no protection against a user trying to set an unsupported mode on DSI. Implement a check based on the opp table whether the byte clock for the mode can be supported by validating whether an opp table entry exists. For devices which have not added opp table support yet, skip this

Re: [Freedreno] [PATCH v2 2/2] drm/msm/dsi: implement opp table based check for dsi_mgr_bridge_mode_valid()

2023-01-11 Thread Dmitry Baryshkov
On 12/01/2023 00:52, Abhinav Kumar wrote: Currently there is no protection against a user trying to set an unsupported mode on DSI. Implement a check based on the opp table whether the byte clock for the mode can be supported by validating whether an opp table entry exists. For devices which hav

Re: [Freedreno] [PATCH v2 2/2] drm/msm/dsi: implement opp table based check for dsi_mgr_bridge_mode_valid()

2023-01-11 Thread Abhinav Kumar
On 1/11/2023 2:56 PM, Dmitry Baryshkov wrote: On 12/01/2023 00:52, Abhinav Kumar wrote: Currently there is no protection against a user trying to set an unsupported mode on DSI. Implement a check based on the opp table whether the byte clock for the mode can be supported by validating whether

[Freedreno] [PATCH v3 1/2] drm/msm/dsi: add a helper method to compute the dsi byte clk

2023-01-11 Thread Abhinav Kumar
Re-arrange the dsi_calc_pclk method to two helpers, one to compute the DSI byte clk and the other to compute the pclk. This makes the separation of the two clean and also allows clients to compute and use the dsi byte clk separately. changes in v2: - move the assignments to definition lin

[Freedreno] [PATCH v3 2/2] drm/msm/dsi: implement opp table based check for dsi_mgr_bridge_mode_valid()

2023-01-11 Thread Abhinav Kumar
Currently there is no protection against a user trying to set an unsupported mode on DSI. Implement a check based on the opp table whether the byte clock for the mode can be supported by validating whether an opp table entry exists. For devices which have not added opp table support yet, skip this

Re: [Freedreno] [PATCH] drm/msm/dpu: Remove some unused variables

2023-01-11 Thread Dmitry Baryshkov
On 12/01/2023 05:38, Jiapeng Chong wrote: Variables 'sc8280xp_regdma' and 'sm8350_regdma' are defined in the dpu_hw_catalog.c file, but not used elsewhere, so remove these unused variables. drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c:2029:37: warning: unused variable 'sc8280xp_regdma'. drive

[Freedreno] [PATCH] drm/msm/dpu: Remove some unused variables

2023-01-11 Thread Jiapeng Chong
Variables 'sc8280xp_regdma' and 'sm8350_regdma' are defined in the dpu_hw_catalog.c file, but not used elsewhere, so remove these unused variables. drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c:2029:37: warning: unused variable 'sc8280xp_regdma'. drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c:20

Re: [Freedreno] [PATCH v3 2/2] drm/msm/dsi: implement opp table based check for dsi_mgr_bridge_mode_valid()

2023-01-11 Thread Dmitry Baryshkov
On 12/01/2023 02:16, Abhinav Kumar wrote: Currently there is no protection against a user trying to set an unsupported mode on DSI. Implement a check based on the opp table whether the byte clock for the mode can be supported by validating whether an opp table entry exists. For devices which hav

Re: [Freedreno] [PATCH v3 1/2] drm/msm/dsi: add a helper method to compute the dsi byte clk

2023-01-11 Thread Dmitry Baryshkov
On 12/01/2023 02:15, Abhinav Kumar wrote: Re-arrange the dsi_calc_pclk method to two helpers, one to compute the DSI byte clk and the other to compute the pclk. This makes the separation of the two clean and also allows clients to compute and use the dsi byte clk separately. changes in v2:

[Freedreno] [PATCH] drm/msm/dpu: merge two CRTC debugfs dirs

2023-01-11 Thread Dmitry Baryshkov
For each CRTC we are creating two different debugfs directories one using crtc index (created automatically for the CRC files) and another one using CRTC name/object ID (for state and status files). This can be confusing, so move our custom files to crtc->debugfs_entry, effetively merging two debu