Re: [Freedreno] [PATCH] drm/msm/disp: fix endian bug in debugfs code

2021-10-04 Thread Dan Carpenter
On Tue, Oct 05, 2021 at 02:31:12AM +0300, Dmitry Baryshkov wrote: > On 04/10/2021 16:47, Dan Carpenter wrote: > > The "vbif->features" is type unsigned long but the debugfs file > > is treating it as a u32 type. This will work in little endian > > systems, but the correct thing is to change the de

[Freedreno] [PATCH] drm/msm/dp: Shorten SETUP timeout

2021-10-04 Thread Bjorn Andersson
Found in the middle of a patch from Sankeerth was the reduction of the INIT_SETUP timeout from 10s to 100ms. Upon INIT_SETUP timeout the host is initalized and HPD interrupt start to be serviced, so in the case of eDP this reduction improves the user experience dramatically - i.e. removes 9.9s of b

[Freedreno] [RFC] drm/msm/dp: Add typec_mux implementation

2021-10-04 Thread Bjorn Andersson
Implement a typec_mux in order to allow a Type-C controller to signal the connection and attention of DisplayPort to the related USB-C port. The remains of support for something along this lines was left in the dp_display as the driver was upstreamed, so these are reused with minimal modifications

Re: [Freedreno] [RFC] drm/msm/dp: Allow attaching a drm_panel

2021-10-04 Thread Bjorn Andersson
On Mon 04 Oct 20:50 CDT 2021, Stephen Boyd wrote: > Quoting Bjorn Andersson (2021-10-04 18:11:11) > > On Mon 04 Oct 17:36 PDT 2021, Doug Anderson wrote: > > > > > Hi, > > > > > > On Fri, Oct 1, 2021 at 2:00 PM Bjorn Andersson > > > wrote: > > > > > > > > On Fri 27 Aug 13:52 PDT 2021, Doug Anderso

Re: [Freedreno] [PATCH v1 2/4] arm64: dts: qcom: sc7280: add display dt nodes

2021-10-04 Thread Stephen Boyd
Quoting mkri...@codeaurora.org (2021-09-30 23:39:07) > On 2021-09-30 23:28, Stephen Boyd wrote: > > Quoting mkri...@codeaurora.org (2021-09-30 04:56:59) > >> On 2021-08-19 01:27, Stephen Boyd wrote: > >> > Quoting Krishna Manikandan (2021-08-18 03:27:02) > >> >> diff --git a/arch/arm64/boot/dts/qco

Re: [Freedreno] [RFC] drm/msm/dp: Allow attaching a drm_panel

2021-10-04 Thread Stephen Boyd
Quoting Bjorn Andersson (2021-10-04 18:11:11) > On Mon 04 Oct 17:36 PDT 2021, Doug Anderson wrote: > > > Hi, > > > > On Fri, Oct 1, 2021 at 2:00 PM Bjorn Andersson > > wrote: > > > > > > On Fri 27 Aug 13:52 PDT 2021, Doug Anderson wrote: > > > > > > > Hi, > > > > > > > > On Mon, Jul 26, 2021 at 4:

Re: [Freedreno] [PATCH v3 3/5] drm/msm/dp: Support up to 3 DP controllers

2021-10-04 Thread Stephen Boyd
Quoting Bjorn Andersson (2021-10-04 18:15:20) > On Mon 04 Oct 17:58 PDT 2021, Stephen Boyd wrote: > > > Quoting Bjorn Andersson (2021-10-01 11:00:56) > > > Based on the removal of the g_dp_display and the movement of the > > > priv->dp lookup into the DP code it's now possible to have multiple > >

Re: [Freedreno] [PATCH v3 3/5] drm/msm/dp: Refactor ioremap wrapper

2021-10-04 Thread Bjorn Andersson
On Mon 04 Oct 18:04 PDT 2021, Stephen Boyd wrote: > Quoting Bjorn Andersson (2021-10-01 10:43:58) > > In order to deal with multiple memory ranges in the following commit > > change the ioremap wrapper to not poke directly into the dss_io_data > > struct. > > > > While at it, devm_ioremap_resource

Re: [Freedreno] [PATCH v3 3/5] drm/msm/dp: Support up to 3 DP controllers

2021-10-04 Thread Bjorn Andersson
On Mon 04 Oct 17:58 PDT 2021, Stephen Boyd wrote: > Quoting Bjorn Andersson (2021-10-01 11:00:56) > > Based on the removal of the g_dp_display and the movement of the > > priv->dp lookup into the DP code it's now possible to have multiple > > DP instances. > > > > In line with the other controller

Re: [Freedreno] [RFC] drm/msm/dp: Allow attaching a drm_panel

2021-10-04 Thread Bjorn Andersson
On Mon 04 Oct 17:36 PDT 2021, Doug Anderson wrote: > Hi, > > On Fri, Oct 1, 2021 at 2:00 PM Bjorn Andersson > wrote: > > > > On Fri 27 Aug 13:52 PDT 2021, Doug Anderson wrote: > > > > > Hi, > > > > > > On Mon, Jul 26, 2021 at 4:15 PM Bjorn Andersson > > > wrote: > > > > > > > > +static int dp_p

Re: [Freedreno] [PATCH v3 3/5] drm/msm/dp: Refactor ioremap wrapper

2021-10-04 Thread Stephen Boyd
Quoting Bjorn Andersson (2021-10-01 10:43:58) > In order to deal with multiple memory ranges in the following commit > change the ioremap wrapper to not poke directly into the dss_io_data > struct. > > While at it, devm_ioremap_resource() already prints useful error > messages on failure, so omit t

Re: [Freedreno] [PATCH v3 3/5] drm/msm/dp: Support up to 3 DP controllers

2021-10-04 Thread Stephen Boyd
Quoting Bjorn Andersson (2021-10-01 11:00:56) > Based on the removal of the g_dp_display and the movement of the > priv->dp lookup into the DP code it's now possible to have multiple > DP instances. > > In line with the other controllers in the MSM driver, introduce a > per-compatible list of base

Re: [Freedreno] [RFC] drm/msm/dp: Allow attaching a drm_panel

2021-10-04 Thread Doug Anderson
Hi, On Fri, Oct 1, 2021 at 2:00 PM Bjorn Andersson wrote: > > On Fri 27 Aug 13:52 PDT 2021, Doug Anderson wrote: > > > Hi, > > > > On Mon, Jul 26, 2021 at 4:15 PM Bjorn Andersson > > wrote: > > > > > > +static int dp_parser_find_panel(struct dp_parser *parser) > > > +{ > > > + struct devic

Re: [Freedreno] [PATCH v3 03/14] drm/hdcp: Update property value on content type and user changes

2021-10-04 Thread abhinavk
On 2021-10-01 08:11, Sean Paul wrote: From: Sean Paul This patch updates the connector's property value in 2 cases which were previously missed: 1- Content type changes. The value should revert back to DESIRED from ENABLED in case the driver must re-authenticate the link due to the new c

Re: [Freedreno] [PATCH] drm/msm: potential error pointer dereference in init()

2021-10-04 Thread Dmitry Baryshkov
On 04/10/2021 13:38, Dan Carpenter wrote: The msm_iommu_new() returns error pointers on failure so check for that to avoid an Oops. Fixes: ccac7ce373c1 ("drm/msm: Refactor address space initialization") Signed-off-by: Dan Carpenter --- Reviewed-by: Dmitry Baryshkov drivers/gpu/drm/msm/di

Re: [Freedreno] [PATCH] drm/msm: potential error pointer dereference in init()

2021-10-04 Thread abhinavk
On 2021-10-04 03:38, Dan Carpenter wrote: The msm_iommu_new() returns error pointers on failure so check for that to avoid an Oops. Fixes: ccac7ce373c1 ("drm/msm: Refactor address space initialization") Signed-off-by: Dan Carpenter Reviewed-by: Abhinav Kumar --- drivers/gpu/drm/msm/disp/dpu

Re: [Freedreno] [PATCH] drm/msm/disp: fix endian bug in debugfs code

2021-10-04 Thread abhinavk
On 2021-10-04 06:47, Dan Carpenter wrote: The "vbif->features" is type unsigned long but the debugfs file is treating it as a u32 type. This will work in little endian systems, but the correct thing is to change the debugfs to use an unsigned long. Fixes: 25fdd5933e4c ("drm/msm: Add SDM845 DPU

Re: [Freedreno] [PATCH] drm/msm: Fix potential Oops in a6xx_gmu_rpmh_init()

2021-10-04 Thread Dmitry Baryshkov
On 04/10/2021 16:45, Dan Carpenter wrote: There are two problems here: 1) The "seqptr" is used uninitalized when we free it at the end. This looks like a nice catch, potentially causing troubles. 2) The a6xx_gmu_get_mmio() function returns error pointers. It never returns true. Fixes: 6

Re: [Freedreno] [PATCH] drm/msm/disp: fix endian bug in debugfs code

2021-10-04 Thread Dmitry Baryshkov
On 04/10/2021 16:47, Dan Carpenter wrote: The "vbif->features" is type unsigned long but the debugfs file is treating it as a u32 type. This will work in little endian systems, but the correct thing is to change the debugfs to use an unsigned long. Fixes: 25fdd5933e4c ("drm/msm: Add SDM845 DPU

Re: [Freedreno] [PATCH v3 11/14] drm/msm/dp: Re-order dp_audio_put in deinit_sub_modules

2021-10-04 Thread Dmitry Baryshkov
On 01/10/2021 18:11, Sean Paul wrote: From: Sean Paul Audio is initialized last, it should be de-initialized first to match the order in dp_init_sub_modules(). Reviewed-by: Abhinav Kumar Reviewed-by: Stephen Boyd Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/

Re: [Freedreno] [PATCH v3 10/14] drm/msm/dpu: Remove encoder->enable() hack

2021-10-04 Thread Dmitry Baryshkov
On 01/10/2021 18:11, Sean Paul wrote: From: Sean Paul encoder->commit() was being misused because there were some global resources which needed to be tweaked in encoder->enable() which were not accessible in dpu_encoder.c. That is no longer true and the redirect serves no purpose any longer. So

Re: [Freedreno] [PATCH v3 09/14] drm/msm/dpu: Remove useless checks in dpu_encoder

2021-10-04 Thread Dmitry Baryshkov
On 01/10/2021 18:11, Sean Paul wrote: From: Sean Paul A couple more useless checks to remove in dpu_encoder. Reviewed-by: Stephen Boyd Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20210913175747.47456-10-s...@poorly.run #v1 Link: https://patchwork.freedeskt

Re: [Freedreno] [PATCH v3 08/14] drm/msm/dpu_kms: Re-order dpu includes

2021-10-04 Thread Dmitry Baryshkov
On 01/10/2021 18:11, Sean Paul wrote: From: Sean Paul Make includes alphabetical in dpu_kms.c Reviewed-by: Abhinav Kumar Reviewed-by: Stephen Boyd Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20210913175747.47456-9-s...@poorly.run #v1 Link: https://patchwo

Re: [Freedreno] [PATCH v3 12/14] dt-bindings: msm/dp: Add bindings for HDCP registers

2021-10-04 Thread Bjorn Andersson
On Fri 01 Oct 10:11 CDT 2021, Sean Paul wrote: > From: Sean Paul > > This patch adds the bindings for the MSM DisplayPort HDCP registers > which are required to write the HDCP key into the display controller as > well as the registers to enable HDCP authentication/key > exchange/encryption. > >

Re: [Freedreno] [PATCH v3 12/14] dt-bindings: msm/dp: Add bindings for HDCP registers

2021-10-04 Thread Bjorn Andersson
On Fri 01 Oct 10:11 CDT 2021, Sean Paul wrote: > From: Sean Paul > > This patch adds the bindings for the MSM DisplayPort HDCP registers > which are required to write the HDCP key into the display controller as > well as the registers to enable HDCP authentication/key > exchange/encryption. > >

Re: [Freedreno] [PATCH v3 1/3] dt-bindings: msm: dsi: Add MSM8953 dsi phy

2021-10-04 Thread Rob Herring
On Tue, 28 Sep 2021 18:49:27 +0530, Sireesh Kodali wrote: > SoCs based on the MSM8953 platform use the 14nm DSI PHY driver > > Signed-off-by: Sireesh Kodali > --- > Documentation/devicetree/bindings/display/msm/dsi-phy-14nm.yaml | 1 + > 1 file changed, 1 insertion(+) > Acked-by: Rob Herring

Re: [Freedreno] [PATCH] drm/msm/a6xx: Serialize GMU communication

2021-10-04 Thread Akhil P Oommen
On 10/2/2021 1:02 AM, Rob Clark wrote: From: Rob Clark I've seen some crashes in our crash reporting that *look* like multiple threads stomping on each other while communicating with GMU. So wrap all those paths in a lock. Signed-off-by: Rob Clark --- drivers/gpu/drm/msm/adreno/a6xx_gmu.c

Re: [Freedreno] [PATCH] drm/msm/dsi: use bulk clk API

2021-10-04 Thread Bjorn Andersson
On Fri 01 Oct 18:27 PDT 2021, Dmitry Baryshkov wrote: > Use clk_bulk_* API instead of hand-coding them. Note, this drops support > for legacy clk naming (e.g. "iface_clk" instead of just "iface"), > however all in-kernel device trees were converted long long ago. The > warning is present there sin

[Freedreno] [PATCH] drm/msm: Fix potential Oops in a6xx_gmu_rpmh_init()

2021-10-04 Thread Dan Carpenter
There are two problems here: 1) The "seqptr" is used uninitalized when we free it at the end. 2) The a6xx_gmu_get_mmio() function returns error pointers. It never returns true. Fixes: 64245fc55172 ("drm/msm/a6xx: use AOP-initialized PDC for a650") Fixes: f8fc924e088e ("drm/msm/a6xx: Fix PDC re

[Freedreno] [PATCH] drm/msm/disp: fix endian bug in debugfs code

2021-10-04 Thread Dan Carpenter
The "vbif->features" is type unsigned long but the debugfs file is treating it as a u32 type. This will work in little endian systems, but the correct thing is to change the debugfs to use an unsigned long. Fixes: 25fdd5933e4c ("drm/msm: Add SDM845 DPU support") Signed-off-by: Dan Carpenter ---

[Freedreno] [bug report] drm/msm: Add SDM845 DPU support

2021-10-04 Thread Dan Carpenter
Hello MSM Devs, The patch 25fdd5933e4c: "drm/msm: Add SDM845 DPU support" from Jun 27, 2018, leads to the following Smatch static checker warnings: drivers/gpu/drm/msm/msm_gpu.c:301 msm_gpu_crashstate_capture() error: potential null dereference 'state->bos'. (kcalloc returns null) drivers/gpu/d

[Freedreno] [PATCH] drm/msm: potential error pointer dereference in init()

2021-10-04 Thread Dan Carpenter
The msm_iommu_new() returns error pointers on failure so check for that to avoid an Oops. Fixes: ccac7ce373c1 ("drm/msm: Refactor address space initialization") Signed-off-by: Dan Carpenter --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 4 1 file changed, 4 insertions(+) diff --git a/driver

Re: [Freedreno] [Intel-gfx] [PATCH v2 00/17] drm: cleanup: Use DRM_MODESET_LOCK_ALL_* helpers where possible

2021-10-04 Thread Jani Nikula
On Mon, 04 Oct 2021, Ville Syrjälä wrote: > On Sun, Oct 03, 2021 at 12:32:14AM +0200, Fernando Ramos wrote: >> On 21/10/02 09:13AM, Fernando Ramos wrote: >> > >> > Sean, could you revert the whole patch series? I'll have a deeper look >> > into the >> > patch set and come up with a v3 where all

Re: [Freedreno] [Intel-gfx] [PATCH v2 00/17] drm: cleanup: Use DRM_MODESET_LOCK_ALL_* helpers where possible

2021-10-04 Thread Ville Syrjälä
On Sun, Oct 03, 2021 at 12:32:14AM +0200, Fernando Ramos wrote: > On 21/10/02 09:13AM, Fernando Ramos wrote: > > > > Sean, could you revert the whole patch series? I'll have a deeper look into > > the > > patch set and come up with a v3 where all these issues will be addressed. > > > > Hi Sean,

Re: [Freedreno] [Intel-gfx] [PATCH v2 00/17] drm: cleanup: Use DRM_MODESET_LOCK_ALL_* helpers where possible

2021-10-04 Thread Ville Syrjälä
On Sat, Oct 02, 2021 at 07:28:02PM +0200, Fernando Ramos wrote: > On 21/10/02 09:13AM, Fernando Ramos wrote: > > On 21/10/02 05:30AM, Ville Syrjälä wrote: > > > On Sat, Oct 02, 2021 at 01:05:47AM +0300, Ville Syrjälä wrote: > > > > On Fri, Oct 01, 2021 at 04:48:15PM -0400, Sean Paul wrote: > > > >