Re: [PATCH] drm: sun4i_tcon: use devm_clk_get_enabled in `sun4i_tcon_init_clocks`

2023-05-10 Thread XuDong Liu
On 2023/4/30 19:23, XuDong Liu wrote: Smatch reports: drivers/gpu/drm/sun4i/sun4i_tcon.c:805 sun4i_tcon_init_clocks() warn: 'tcon->clk' from clk_prepare_enable() not released on lines: 792,801. In the function sun4i_tcon_init_clocks(), tcon->clk and tcon->sclk0 are not disabled in the error hand

Re: [PATCH] dma-buf/sync_file: Use fdget()

2023-05-10 Thread Al Viro
On Fri, May 05, 2023 at 10:22:09AM +0200, Christian König wrote: > Am 05.05.23 um 05:03 schrieb ye.xingc...@zte.com.cn: > > From: Ye Xingchen > > > > convert the fget() use to fdget(). > > Well the rational is missing. Why should we do that? We very definitely should not. The series appears to

Re: [PATCH v7 4/8] drm/msm: Add MSM-specific DSC helper methods

2023-05-10 Thread Dmitry Baryshkov
On 11/05/2023 00:03, Jessica Zhang wrote: On 5/9/2023 11:33 PM, Marijn Suijten wrote: On 2023-05-09 15:06:50, Jessica Zhang wrote: Introduce MSM-specific DSC helper methods, as some calculations are common between DP and DSC. Reviewed-by: Dmitry Baryshkov Signed-off-by: Jessica Zhang ---  

Re: [PATCH v7 2/8] drm/display/dsc: add helper to set semi-const parameters

2023-05-10 Thread Dmitry Baryshkov
On 11/05/2023 09:18, Marijn Suijten wrote: On 2023-05-11 07:26:28, Dmitry Baryshkov wrote: On 11/05/2023 01:35, Jessica Zhang wrote: On 5/9/2023 11:29 PM, Marijn Suijten wrote: On 2023-05-09 15:06:48, Jessica Zhang wrote: From: Dmitry Baryshkov Add a helper setting config values which are

Re: [PATCH v7 2/8] drm/display/dsc: add helper to set semi-const parameters

2023-05-10 Thread Marijn Suijten
On 2023-05-11 07:26:28, Dmitry Baryshkov wrote: > On 11/05/2023 01:35, Jessica Zhang wrote: > > > > > > On 5/9/2023 11:29 PM, Marijn Suijten wrote: > >> On 2023-05-09 15:06:48, Jessica Zhang wrote: > >>> From: Dmitry Baryshkov > >>> > >>> Add a helper setting config values which are typically co

Re: [PATCH v7 4/8] drm/msm: Add MSM-specific DSC helper methods

2023-05-10 Thread Marijn Suijten
On 2023-05-10 14:03:14, Jessica Zhang wrote: > > > On 5/9/2023 11:33 PM, Marijn Suijten wrote: > > On 2023-05-09 15:06:50, Jessica Zhang wrote: > >> Introduce MSM-specific DSC helper methods, as some calculations are > >> common between DP and DSC. > >> > >> Reviewed-by: Dmitry Baryshkov > >> Si

Re: [PATCH] dma-buf: Use fdget()

2023-05-10 Thread Al Viro
On Fri, May 05, 2023 at 10:18:47AM +0800, ye.xingc...@zte.com.cn wrote: > From: Ye Xingchen > > convert the fget() use to fdget(). NAK.

Re: [PATCH] dma-buf/sync_file: Use fdget()

2023-05-10 Thread Al Viro
On Fri, May 05, 2023 at 11:03:39AM +0800, ye.xingc...@zte.com.cn wrote: > From: Ye Xingchen > > convert the fget() use to fdget(). NAK.

Re: [PATCH v6 8/8] drm/msm/dpu: tear down DSC data path when DSC disabled

2023-05-10 Thread Dmitry Baryshkov
On 11/05/2023 01:07, Kuogee Hsieh wrote: Unset DSC_ACTIVE bit at dpu_hw_ctl_reset_intf_cfg_v1(), dpu_encoder_unprep_dsc() and dpu_encoder_dsc_pipe_clr() functions to tear down DSC data path if DSC data path was setup previous. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/disp/dpu1/dpu_

Re: [PATCH v6 8/8] drm/msm/dpu: tear down DSC data path when DSC disabled

2023-05-10 Thread Dmitry Baryshkov
On 11/05/2023 01:07, Kuogee Hsieh wrote: Unset DSC_ACTIVE bit at dpu_hw_ctl_reset_intf_cfg_v1(), dpu_encoder_unprep_dsc() and dpu_encoder_dsc_pipe_clr() functions to tear down DSC data path if DSC data path was setup previous. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/disp/dpu1/dpu_

Re: [PATCH v6 5/8] drm/msm/dpu: add support for DSC encoder v1.2 engine

2023-05-10 Thread Dmitry Baryshkov
On 11/05/2023 01:07, Kuogee Hsieh wrote: Add support for DSC 1.2 by providing the necessary hooks to program the DPU DSC 1.2 encoder. Changes in v3: -- fixed kernel test rebot report that "__iomem *off" is declared but not used at dpu_hw_dsc_config_1_2() -- unrolling thresh loops Changes in

Re: [PATCH v6 2/8] drm/msm/dpu: add DPU_PINGPONG_DSC feature bit for DPU < 7.0.0

2023-05-10 Thread Dmitry Baryshkov
On 11/05/2023 07:42, Abhinav Kumar wrote: On 5/10/2023 9:39 PM, Dmitry Baryshkov wrote: On 11/05/2023 07:38, Abhinav Kumar wrote: On 5/10/2023 9:29 PM, Dmitry Baryshkov wrote: On 11/05/2023 01:07, Kuogee Hsieh wrote: DPU < 7.0.0 requires the PINGPONG block to be involved during DSC settin

Re: [PATCH v6 2/8] drm/msm/dpu: add DPU_PINGPONG_DSC feature bit for DPU < 7.0.0

2023-05-10 Thread Abhinav Kumar
On 5/10/2023 9:39 PM, Dmitry Baryshkov wrote: On 11/05/2023 07:38, Abhinav Kumar wrote: On 5/10/2023 9:29 PM, Dmitry Baryshkov wrote: On 11/05/2023 01:07, Kuogee Hsieh wrote: DPU < 7.0.0 requires the PINGPONG block to be involved during DSC setting up. Since DPU >= 7.0.0, enabling and sta

Re: [PATCH v6 2/8] drm/msm/dpu: add DPU_PINGPONG_DSC feature bit for DPU < 7.0.0

2023-05-10 Thread Dmitry Baryshkov
On 11/05/2023 07:38, Abhinav Kumar wrote: On 5/10/2023 9:29 PM, Dmitry Baryshkov wrote: On 11/05/2023 01:07, Kuogee Hsieh wrote: DPU < 7.0.0 requires the PINGPONG block to be involved during DSC setting up. Since DPU >= 7.0.0, enabling and starting the DSC encoder engine moved to INTF with th

Re: [PATCH v6 2/8] drm/msm/dpu: add DPU_PINGPONG_DSC feature bit for DPU < 7.0.0

2023-05-10 Thread Abhinav Kumar
On 5/10/2023 9:29 PM, Dmitry Baryshkov wrote: On 11/05/2023 01:07, Kuogee Hsieh wrote: DPU < 7.0.0 requires the PINGPONG block to be involved during DSC setting up. Since DPU >= 7.0.0, enabling and starting the DSC encoder engine moved to INTF with the help of the flush mechanism. Nit: was

Re: [PATCH v6 3/8] drm/msm/dpu: test DPU_PINGPONG_DSC bit before assign DSC ops to PINGPONG

2023-05-10 Thread Dmitry Baryshkov
On 11/05/2023 01:07, Kuogee Hsieh wrote: DPU < 7.0.0 has DPU_PINGPONG_DSC feature bit set to indicate it requires both dpu_hw_pp_setup_dsc() and dpu_hw_pp_dsc_{enable,disable}() to be executed to complete DSC configuration if DSC hardware block is present. Hence test DPU_PINGPONG_DSC feature bit

Re: [PATCH v6 3/8] drm/msm/dpu: test DPU_PINGPONG_DSC bit before assign DSC ops to PINGPONG

2023-05-10 Thread Dmitry Baryshkov
On 11/05/2023 01:07, Kuogee Hsieh wrote: DPU < 7.0.0 has DPU_PINGPONG_DSC feature bit set to indicate it requires both dpu_hw_pp_setup_dsc() and dpu_hw_pp_dsc_{enable,disable}() to be executed to complete DSC configuration if DSC hardware block is present. Hence test DPU_PINGPONG_DSC feature bit

Re: [PATCH v6 2/8] drm/msm/dpu: add DPU_PINGPONG_DSC feature bit for DPU < 7.0.0

2023-05-10 Thread Dmitry Baryshkov
On 11/05/2023 01:07, Kuogee Hsieh wrote: DPU < 7.0.0 requires the PINGPONG block to be involved during DSC setting up. Since DPU >= 7.0.0, enabling and starting the DSC encoder engine moved to INTF with the help of the flush mechanism. Nit: was moved. Add a DPU_PINGPONG_DSC feature bit to res

Re: [PATCH v7 2/8] drm/display/dsc: add helper to set semi-const parameters

2023-05-10 Thread Dmitry Baryshkov
On 11/05/2023 01:35, Jessica Zhang wrote: On 5/9/2023 11:29 PM, Marijn Suijten wrote: On 2023-05-09 15:06:48, Jessica Zhang wrote: From: Dmitry Baryshkov Add a helper setting config values which are typically constant across operating modes (table E-4 of the standard) and mux_word_size (whi

Re: [PATCH v1 1/2] drm/msm/dp: enable HDP plugin/unplugged interrupts to hpd_enable/disable

2023-05-10 Thread Dmitry Baryshkov
On Wed, 10 May 2023 at 23:31, Kuogee Hsieh wrote: > > The internal_hpd flag was introduced to handle external DP HPD derived from > GPIO > pinmuxed into DP controller. HPD plug/unplug interrupts cannot be enabled > until > internal_hpd flag is set to true. > At both bootup and resume time, the D

Re: [PATCH v1 1/2] drm/msm/dp: enable HDP plugin/unplugged interrupts to hpd_enable/disable

2023-05-10 Thread Abhinav Kumar
On 5/10/2023 4:55 PM, Stephen Boyd wrote: Quoting Kuogee Hsieh (2023-05-10 13:31:04) The internal_hpd flag was introduced to handle external DP HPD derived from GPIO pinmuxed into DP controller. Was it? It looks more like it was done to differentiate between eDP and DP, because internal_hpd

Re: [PATCH] accel/ivpu: Reserve all non-command bo's using DMA_RESV_USAGE_BOOKKEEP

2023-05-10 Thread Jeffrey Hugo
On 4/13/2023 12:38 AM, Stanislaw Gruszka wrote: Use DMA_RESV_USAGE_BOOKKEEP reservation for buffer objects, except for command buffers for which we use DMA_RESV_USAGE_WRITE (since VPU can write to command buffer context save area). Fixes: 0ec8671837a6 ("accel/ivpu: Fix S3 system suspend when not

Re: [PATCH v1 1/2] drm/msm/dp: enable HDP plugin/unplugged interrupts to hpd_enable/disable

2023-05-10 Thread Stephen Boyd
Quoting Kuogee Hsieh (2023-05-10 13:31:04) > The internal_hpd flag was introduced to handle external DP HPD derived from > GPIO > pinmuxed into DP controller. Was it? It looks more like it was done to differentiate between eDP and DP, because internal_hpd is set only if DRM_BRIDGE_OP_HPD is set o

Re: [PATCH v1 2/2] drm/msm/dp: add mutex to protect internal_hpd against race condition between different threads

2023-05-10 Thread Abhinav Kumar
Hi Stephen On 5/10/2023 4:19 PM, Kuogee Hsieh wrote: internal_hpd is referenced at both plug and unplug handle. The majority purpose of  mutext is try to serialize internal_hpd between dp_bridge_hpd_disable() and either plug or unplug handle. On 5/10/2023 4:11 PM, Abhinav Kumar wrote: On

Re: [PATCH v1 2/2] drm/msm/dp: add mutex to protect internal_hpd against race condition between different threads

2023-05-10 Thread Kuogee Hsieh
internal_hpd is referenced at both plug and unplug handle. The majority purpose of  mutext is try to serialize internal_hpd between dp_bridge_hpd_disable() and either plug or unplug handle. On 5/10/2023 4:11 PM, Abhinav Kumar wrote: On 5/10/2023 3:46 PM, Stephen Boyd wrote: Quoting Kuogee

Re: [PATCH v1 2/2] drm/msm/dp: add mutex to protect internal_hpd against race condition between different threads

2023-05-10 Thread Abhinav Kumar
On 5/10/2023 3:46 PM, Stephen Boyd wrote: Quoting Kuogee Hsieh (2023-05-10 13:31:05) Intrenal_hpd is referenced by event thread but set by drm bridge callback context. Add mutex to protect internal_hpd to avoid conflicts between threads. Signed-off-by: Kuogee Hsieh --- This patch looks co

[PATCH v9 6/8] drm/msm/dpu: Fix slice_last_group_size calculation

2023-05-10 Thread Jessica Zhang
Correct the math for slice_last_group_size so that it matches the calculations downstream. Fixes: c110cfd1753e ("drm/msm/disp/dpu1: Add support for DSC") Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Jessica Zhang --- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_dsc.c | 5 ++

[PATCH v9 8/8] drm/msm/dsi: update hdisplay calculation for dsi_timing_setup

2023-05-10 Thread Jessica Zhang
hdisplay for compressed images should be calculated as bytes_per_slice * slice_count. Thus, use MSM DSC helper to calculate hdisplay for dsi_timing_setup instead of directly using mode->hdisplay. Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Jessica Zhang --- drivers

[PATCH v9 0/8] Introduce MSM-specific DSC helpers

2023-05-10 Thread Jessica Zhang
There are some overlap in calculations for MSM-specific DSC variables between DP and DSI. In addition, the calculations for initial_scale_value and det_thresh_flatness that are defined within the DSC 1.2 specifications, but aren't yet included in drm_dsc_helper.c. This series moves these calculati

[PATCH v9 4/8] drm/msm: Add MSM-specific DSC helper methods

2023-05-10 Thread Jessica Zhang
Introduce MSM-specific DSC helper methods, as some calculations are common between DP and DSC. Signed-off-by: Jessica Zhang --- drivers/gpu/drm/msm/Makefile | 1 + drivers/gpu/drm/msm/msm_dsc_helper.c | 26 ++ drivers/gpu/drm/msm/msm_dsc_helper.h | 69 +++

[PATCH v9 3/8] drm/msm/dsi: use DRM DSC helpers for DSC setup

2023-05-10 Thread Jessica Zhang
From: Dmitry Baryshkov Use new DRM DSC helpers to setup DSI DSC configuration. The initial_scale_value needs to be adjusted according to the standard, but this is a separate change. Signed-off-by: Dmitry Baryshkov Reviewed-by: Abhinav Kumar Signed-off-by: Jessica Zhang --- drivers/gpu/drm/ms

[PATCH v9 7/8] drm/msm/dsi: Use MSM and DRM DSC helper methods

2023-05-10 Thread Jessica Zhang
Use MSM and DRM DSC helper methods to configure DSC for DSI. Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Jessica Zhang --- drivers/gpu/drm/msm/dsi/dsi_host.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/msm/dsi/dsi_host

[PATCH v9 5/8] drm/msm/dpu: Use fixed DRM DSC helper for det_thresh_flatness

2023-05-10 Thread Jessica Zhang
The current dpu_hw_dsc calculation for det_thresh_flatness does not match the downstream calculation or the DSC spec. Use the DRM DSC helper for det_thresh_flatness to match downstream implementation and the DSC spec. Fixes: c110cfd1753e ("drm/msm/disp/dpu1: Add support for DSC") Reviewed-by: Dmi

[PATCH v9 2/8] drm/display/dsc: add helper to set semi-const parameters

2023-05-10 Thread Jessica Zhang
From: Dmitry Baryshkov Add a helper setting config values which are typically constant across operating modes (table E-4 of the standard) and mux_word_size (which is a const according to 3.5.2). Signed-off-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Jessica Zhang --- driv

[PATCH v9 1/8] drm/display/dsc: Add flatness and initial scale value calculations

2023-05-10 Thread Jessica Zhang
Add helpers to calculate det_thresh_flatness and initial_scale_value as these calculations are defined within the DSC spec. Signed-off-by: Jessica Zhang Signed-off-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Jessica Zhang --- include/drm/display/drm_dsc_helper.h | 11 +

Re: [PATCH v1 2/2] drm/msm/dp: add mutex to protect internal_hpd against race condition between different threads

2023-05-10 Thread Stephen Boyd
Quoting Kuogee Hsieh (2023-05-10 13:31:05) > Intrenal_hpd is referenced by event thread but set by drm bridge callback > context. Add mutex to protect internal_hpd to avoid conflicts between > threads. > > Signed-off-by: Kuogee Hsieh > --- This patch looks completely unnecessary. How can dp_bridg

[PATCH v8 5/8] drm/msm/dpu: Use fixed DRM DSC helper for det_thresh_flatness

2023-05-10 Thread Jessica Zhang
The current dpu_hw_dsc calculation for det_thresh_flatness does not match the downstream calculation or the DSC spec. Use the DRM DSC helper for det_thresh_flatness to match downstream implementation and the DSC spec. Fixes: c110cfd1753e ("drm/msm/disp/dpu1: Add support for DSC") Reviewed-by: Dmi

[PATCH v8 8/8] drm/msm/dsi: update hdisplay calculation for dsi_timing_setup

2023-05-10 Thread Jessica Zhang
hdisplay for compressed images should be calculated as bytes_per_slice * slice_count. Thus, use MSM DSC helper to calculate hdisplay for dsi_timing_setup instead of directly using mode->hdisplay. Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Jessica Zhang --- drivers

[PATCH v8 4/8] drm/msm: Add MSM-specific DSC helper methods

2023-05-10 Thread Jessica Zhang
Introduce MSM-specific DSC helper methods, as some calculations are common between DP and DSC. Reviewed-by: Dmitry Baryshkov Signed-off-by: Jessica Zhang --- drivers/gpu/drm/msm/Makefile | 1 + drivers/gpu/drm/msm/msm_dsc_helper.c | 26 ++ drivers/gpu/drm/msm/msm_dsc_helper

[PATCH v8 6/8] drm/msm/dpu: Fix slice_last_group_size calculation

2023-05-10 Thread Jessica Zhang
Correct the math for slice_last_group_size so that it matches the calculations downstream. Fixes: c110cfd1753e ("drm/msm/disp/dpu1: Add support for DSC") Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Jessica Zhang --- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_dsc.c | 5 ++

[PATCH v8 3/8] drm/msm/dsi: use DRM DSC helpers for DSC setup

2023-05-10 Thread Jessica Zhang
From: Dmitry Baryshkov Use new DRM DSC helpers to setup DSI DSC configuration. The initial_scale_value needs to be adjusted according to the standard, but this is a separate change. Signed-off-by: Dmitry Baryshkov Reviewed-by: Abhinav Kumar Signed-off-by: Jessica Zhang --- drivers/gpu/drm/ms

[PATCH v8 0/8] Introduce MSM-specific DSC helpers

2023-05-10 Thread Jessica Zhang
There are some overlap in calculations for MSM-specific DSC variables between DP and DSI. In addition, the calculations for initial_scale_value and det_thresh_flatness that are defined within the DSC 1.2 specifications, but aren't yet included in drm_dsc_helper.c. This series moves these calculati

[PATCH v8 7/8] drm/msm/dsi: Use MSM and DRM DSC helper methods

2023-05-10 Thread Jessica Zhang
Use MSM and DRM DSC helper methods to configure DSC for DSI. Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Jessica Zhang --- drivers/gpu/drm/msm/dsi/dsi_host.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/msm/dsi/dsi_host

[PATCH v8 1/8] drm/display/dsc: Add flatness and initial scale value calculations

2023-05-10 Thread Jessica Zhang
Add helpers to calculate det_thresh_flatness and initial_scale_value as these calculations are defined within the DSC spec. Signed-off-by: Jessica Zhang Signed-off-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Jessica Zhang --- include/drm/display/drm_dsc_helper.h | 11 +

[PATCH v8 2/8] drm/display/dsc: add helper to set semi-const parameters

2023-05-10 Thread Jessica Zhang
From: Dmitry Baryshkov Add a helper setting config values which are typically constant across operating modes (table E-4 of the standard) and mux_word_size (which is a const according to 3.5.2). Signed-off-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Jessica Zhang --- driv

Re: [PATCH v7 2/8] drm/display/dsc: add helper to set semi-const parameters

2023-05-10 Thread Jessica Zhang
On 5/9/2023 11:29 PM, Marijn Suijten wrote: On 2023-05-09 15:06:48, Jessica Zhang wrote: From: Dmitry Baryshkov Add a helper setting config values which are typically constant across operating modes (table E-4 of the standard) and mux_word_size (which is a const according to 3.5.2). Signed

Re: [Intel-gfx] [PATCH v9 6/8] drm/i915/uapi/pxp: Add a GET_PARAM for PXP

2023-05-10 Thread Jordan Justen
On 2023-05-10 15:00:03, Teres Alexis, Alan Previn wrote: > > alan:snip > > > This is why I asked if it was it was "basically certain that in a > > production environment, then it will eventually return 1 meaning it's > > ready". Alan's response was a little ambiguous on this point. > alan: if we

Re: [PATCH v7 4/4] drm/i915: Allow user to set cache at BO creation

2023-05-10 Thread Andi Shyti
Hi, On Tue, May 09, 2023 at 09:59:42AM -0700, fei.y...@intel.com wrote: > From: Fei Yang > > To comply with the design that buffer objects shall have immutable > cache setting through out their life cycle, {set, get}_caching ioctl's > are no longer supported from MTL onward. With that change cac

[PATCH v6 8/8] drm/msm/dpu: tear down DSC data path when DSC disabled

2023-05-10 Thread Kuogee Hsieh
Unset DSC_ACTIVE bit at dpu_hw_ctl_reset_intf_cfg_v1(), dpu_encoder_unprep_dsc() and dpu_encoder_dsc_pipe_clr() functions to tear down DSC data path if DSC data path was setup previous. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 44 +

[PATCH v6 6/8] drm/msm/dpu: separate DSC flush update out of interface

2023-05-10 Thread Kuogee Hsieh
Current DSC flush update is piggyback inside dpu_hw_ctl_intf_cfg_v1(). This patch separates DSC flush away from dpu_hw_ctl_intf_cfg_v1() by adding dpu_hw_ctl_update_pending_flush_dsc_v1() to handle both per DSC engine and DSC flush bits at same time to make it consistent with the location of flush

[PATCH v6 4/8] drm/msm/dpu: Introduce PINGPONG_NONE to disconnect DSC from PINGPONG

2023-05-10 Thread Kuogee Hsieh
Disabling the crossbar mux between DSC and PINGPONG currently requires a bogus enum dpu_pingpong value to be passed when calling dsc_bind_pingpong_blk() with enable=false, even though the register value written is independent of the current PINGPONG block. Replace that `bool enable` parameter with

[PATCH v6 7/8] drm/msm/dpu: add DSC 1.2 hw blocks for relevant chipsets

2023-05-10 Thread Kuogee Hsieh
From: Abhinav Kumar Add DSC 1.2 hardware blocks to the catalog with necessary sub-block and feature flag information. 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. changes in v4: -- delet

[PATCH v6 5/8] drm/msm/dpu: add support for DSC encoder v1.2 engine

2023-05-10 Thread Kuogee Hsieh
Add support for DSC 1.2 by providing the necessary hooks to program the DPU DSC 1.2 encoder. Changes in v3: -- fixed kernel test rebot report that "__iomem *off" is declared but not used at dpu_hw_dsc_config_1_2() -- unrolling thresh loops Changes in v4: -- delete DPU_DSC_HW_REV_1_1 -- delete

[PATCH v6 3/8] drm/msm/dpu: test DPU_PINGPONG_DSC bit before assign DSC ops to PINGPONG

2023-05-10 Thread Kuogee Hsieh
DPU < 7.0.0 has DPU_PINGPONG_DSC feature bit set to indicate it requires both dpu_hw_pp_setup_dsc() and dpu_hw_pp_dsc_{enable,disable}() to be executed to complete DSC configuration if DSC hardware block is present. Hence test DPU_PINGPONG_DSC feature bit and assign DSC related functions to the ops

[PATCH v6 2/8] drm/msm/dpu: add DPU_PINGPONG_DSC feature bit for DPU < 7.0.0

2023-05-10 Thread Kuogee Hsieh
DPU < 7.0.0 requires the PINGPONG block to be involved during DSC setting up. Since DPU >= 7.0.0, enabling and starting the DSC encoder engine moved to INTF with the help of the flush mechanism. Add a DPU_PINGPONG_DSC feature bit to restrict the availability of dpu_hw_pp_setup_dsc() and dpu_hw_pp_d

[PATCH v6 1/8] drm/msm/dpu: add dsc blocks for remaining chipsets in catalog

2023-05-10 Thread Kuogee Hsieh
From: Abhinav Kumar There are some platforms has DSC blocks but it is not declared at catalog. For completeness, this patch adds DSC blocks for platforms which missed them. Signed-off-by: Abhinav Kumar Reviewed-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_3_0_msm8998.h |

[PATCH v6 0/8] add DSC 1.2 dpu supports

2023-05-10 Thread Kuogee Hsieh
This series adds the DPU side changes to support DSC 1.2 encoder. This was validated with both DSI DSC 1.2 panel and DP DSC 1.2 monitor. The DSI and DP parts will be pushed later on top of this change. This seriel is rebase on [1], [2] and catalog fixes from rev-4 of [3]. [1]: https://patchwork.fr

Re: [Intel-gfx] [PATCH v9 6/8] drm/i915/uapi/pxp: Add a GET_PARAM for PXP

2023-05-10 Thread Teres Alexis, Alan Previn
alan:snip > This is why I asked if it was it was "basically certain that in a > production environment, then it will eventually return 1 meaning it's > ready". Alan's response was a little ambiguous on this point. alan: if we get a '2' and never transition to '1' - thats a kernel bug or firmware

Re: [PATCH 03/53] drm/arm/malidp: Convert to platform remove callback returning void

2023-05-10 Thread Liviu Dudau
On Sun, May 07, 2023 at 06:25:26PM +0200, Uwe Kleine-König wrote: > The .remove() callback for a platform driver returns an int which makes > many driver authors wrongly assume it's possible to do error handling by > returning an error code. However the value returned is (mostly) ignored > and this

Re: [PATCH 02/53] drm/arm/hdlcd: Convert to platform remove callback returning void

2023-05-10 Thread Liviu Dudau
On Sun, May 07, 2023 at 06:25:25PM +0200, Uwe Kleine-König wrote: > The .remove() callback for a platform driver returns an int which makes > many driver authors wrongly assume it's possible to do error handling by > returning an error code. However the value returned is (mostly) ignored > and this

Re: [Intel-gfx] [PATCH v9 6/8] drm/i915/uapi/pxp: Add a GET_PARAM for PXP

2023-05-10 Thread Jordan Justen
...fixing some Cc email addresses I somehow mangled. On 2023-05-10 12:40:07, Souza, Jose wrote: > On Mon, 2023-05-08 at 17:49 +, Teres Alexis, Alan Previn wrote: > > On Fri, 2023-05-05 at 00:39 -0700, Justen, Jordan L wrote: > > > On 2023-05-04 22:30:07, Teres Alexis, Alan Previn wrote: > > >

Re: [PATCH 01/53] drm/komeda: Convert to platform remove callback returning void

2023-05-10 Thread Liviu Dudau
On Sun, May 07, 2023 at 06:25:24PM +0200, Uwe Kleine-König wrote: > The .remove() callback for a platform driver returns an int which makes > many driver authors wrongly assume it's possible to do error handling by > returning an error code. However the value returned is (mostly) ignored > and this

Re: [PATCH v7 4/8] drm/msm: Add MSM-specific DSC helper methods

2023-05-10 Thread Jessica Zhang
On 5/9/2023 11:33 PM, Marijn Suijten wrote: On 2023-05-09 15:06:50, Jessica Zhang wrote: Introduce MSM-specific DSC helper methods, as some calculations are common between DP and DSC. Reviewed-by: Dmitry Baryshkov Signed-off-by: Jessica Zhang --- drivers/gpu/drm/msm/Makefile | 1

[PATCH] drm/i1915/guc: Fix probe injection CI failures after recent change

2023-05-10 Thread John . C . Harrison
From: John Harrison A recent change bumped a 'notice' message up to 'error' level for debug builds to help trap incorrect configurations in CI systems. Unfortunaetly, tha error condition in question is triggered by the error injection probe test. So change the message again to be 'probe error' le

Re: [Intel-xe] [PATCH 0/2] drm/xe: Fix unprotected rebind_list accesses

2023-05-10 Thread Souza, Jose
On Wed, 2023-05-10 at 16:19 +0200, Thomas Hellström wrote: > Each VM has two rebind lists, one protected by the VM resv, the other > one protected essentially by the VM notifier.list_lock. This series > intends to fix two points of illegal access. > > Patch 1 fixes an access of VM rebind_lists' li

[PATCH v1 2/2] drm/msm/dp: add mutex to protect internal_hpd against race condition between different threads

2023-05-10 Thread Kuogee Hsieh
Intrenal_hpd is referenced by event thread but set by drm bridge callback context. Add mutex to protect internal_hpd to avoid conflicts between threads. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git

[PATCH v1 0/2] enable HDP plugin/unplugged interrupts to hpd_enable/disable

2023-05-10 Thread Kuogee Hsieh
There is bug report on exteranl DP display does not work. This patch add below two patches to fix the problem. 1) enable HDP plugin/unplugged interrupts to hpd_enable/disable 2) add mutex to protect internal_hpd against race condition between different threads Kuogee Hsieh (2): drm/msm/dp:

[PATCH v1 1/2] drm/msm/dp: enable HDP plugin/unplugged interrupts to hpd_enable/disable

2023-05-10 Thread Kuogee Hsieh
The internal_hpd flag was introduced to handle external DP HPD derived from GPIO pinmuxed into DP controller. HPD plug/unplug interrupts cannot be enabled until internal_hpd flag is set to true. At both bootup and resume time, the DP driver will enable external DP plugin interrupts and handle plugi

[PATCH v4] console/parisc: Fix STI console on 64-bit only machines

2023-05-10 Thread Helge Deller
Fix the STI console to be able to execute either the 64-bit STI ROM code or the 32-bit STI ROM code. This is necessary on 64-bit only machines (e.g. C8000 workstation) which otherwise won't show the STI text console with HP graphic cards like Visualize-FX5/FX10/FXe. When calling 32-bit code from

[PATCH v3] console/parisc: Fix STI console on 64-bit only machines

2023-05-10 Thread Helge Deller
Fix the STI console to be able to execute either the 64-bit STI ROM code or the 32-bit STI ROM code. This is necessary on 64-bit only machines (e.g. C8000 workstation) which otherwise won't show the STI text console with HP graphic cards like Visualize-FX5/FX10/FXe. When calling 32-bit code from

Re: [RFC PATCH 0/4] Add support for DRM cgroup memory accounting.

2023-05-10 Thread Tejun Heo
Hello, On Wed, May 10, 2023 at 04:59:01PM +0200, Maarten Lankhorst wrote: > The misc controller is not granular enough. A single computer may have any > number of > graphics cards, some of them with multiple regions of vram inside a single > card. Extending the misc controller to support dynami

Re: [PATCH v4 2/4] ARM: dts: sunxi: rename tcon's clock output

2023-05-10 Thread Jernej Škrabec
Dne petek, 05. maj 2023 ob 07:21:08 CEST je Roman Beranek napisal(a): > While the rate of TCON0's DCLK matches dotclock for parallel and LVDS > outputs, this doesn't hold for DSI. According manuals from Allwinner, > DCLK is an abbreviation of Data Clock, not dotclock, so go with that > instead. >

Re: [PATCH v4 1/4] clk: sunxi-ng: a64: force select PLL_MIPI in TCON0 mux

2023-05-10 Thread Jernej Škrabec
Dne petek, 05. maj 2023 ob 07:21:07 CEST je Roman Beranek napisal(a): > TCON0's source clock can be fed from either PLL_MIPI, or PLL_VIDEO0(2X), > however MIPI DSI output only seems to work when PLL_MIPI is selected and > thus the choice must be hardcoded in. > > Currently, this driver can't propa

Re: [PATCH v2 0/7] drm: sun4i: set proper TCON0 DCLK rate in DSI mode

2023-05-10 Thread Jernej Škrabec
Dne ponedeljek, 08. maj 2023 ob 16:08:32 CEST je Frank Oltmanns napisal(a): > Hello again, > > On 2023-05-08 at 08:54:28 +0200, Frank Oltmanns wrote: > > Hello Roman, > > > > On 2023-05-03 at 16:22:32 +0200, "Roman Beranek" wrote: > >> Hello everyone, > >> > >> I apologize for my absence from

[PATCH] drm/i915/hwmon: Silence UBSAN uninitialized bool variable warning

2023-05-10 Thread Ashutosh Dixit
Loading i915 on UBSAN enabled kernels (CONFIG_UBSAN/CONFIG_UBSAN_BOOL) causes the following warning: UBSAN: invalid-load in drivers/gpu/drm/i915/gt/uc/intel_uc.c:558:2 load of value 255 is not a valid value for type '_Bool' Call Trace: dump_stack_lvl+0x57/0x7d ubsan_epilogue+0x5/0x40

Re: [PATCH v6 1/6] fbdev/matrox: Remove trailing whitespaces

2023-05-10 Thread Sui Jingfeng
Hi, Thomas I love your patch, yet something to improve: On 2023/5/10 19:05, Thomas Zimmermann wrote: Fix coding style. No functional changes. Signed-off-by: Thomas Zimmermann Reviewed-by: Arnd Bergmann Reviewed-by: Sam Ravnborg Reviewed-by: Sui Jingfeng Tested-by: Sui Jingfeng --- dri

[PATCH v10 5/8] drm/i915/pxp: Add ARB session creation and cleanup

2023-05-10 Thread Alan Previn
Add MTL's function for ARB session creation using PXP firmware version 4.3 ABI structure format. While relooking at the ARB session creation flow in intel_pxp_start, let's address missing UAPI documentation. Without actually changing backward compatible behavior, update i915's drm-uapi comments th

[PATCH v10 6/8] drm/i915/uapi/pxp: Add a GET_PARAM for PXP

2023-05-10 Thread Alan Previn
Because of the additional firmware, component-driver and initialization depedencies required on MTL platform before a PXP context can be created, UMD calling for PXP creation as a way to get-caps can take a long time. An actual real world customer stack has seen this happen in the 4-to-8 second ran

[PATCH v10 3/8] drm/i915/pxp: Add MTL helpers to submit Heci-Cmd-Packet to GSC

2023-05-10 Thread Alan Previn
Add helper functions into a new file for heci-packet-submission. The helpers will handle generating the MTL GSC-CS Memory-Header and submission of the Heci-Cmd-Packet instructions to the engine. NOTE1: These common functions for heci-packet-submission will be used by different i915 callers: 1

[PATCH v10 8/8] drm/i915/pxp: Enable PXP with MTL-GSC-CS

2023-05-10 Thread Alan Previn
Enable PXP with MTL-GSC-CS: add the has_pxp into device info and increase the debugfs teardown timeouts to align with new GSC-CS + firmware specs. Now that we have 3 places that are selecting pxp timeouts based on tee vs gsccs back-end, let's add a helper. Signed-off-by: Alan Previn Reviewed-by:

[PATCH v10 4/8] drm/i915/pxp: Add GSC-CS backend to send GSC fw messages

2023-05-10 Thread Alan Previn
Add GSC engine based method for sending PXP firmware packets to the GSC firmware for MTL (and future) products. Use the newly added helpers to populate the GSC-CS memory header and send the message packet to the FW by dispatching the GSC_HECI_CMD_PKT instruction on the GSC engine. We use non-priv

[PATCH v10 7/8] drm/i915/pxp: On MTL, KCR enabling doesn't wait on tee component

2023-05-10 Thread Alan Previn
On legacy platforms, KCR HW enabling is done at the time the mei component interface is bound. It's also disabled during unbind. However, for MTL onwards, we don't depend on a tee component to start sending GSC-CS firmware messages. Thus, immediately enable (or disable) KCR HW on PXP's init, fini

[PATCH v10 1/8] drm/i915/pxp: Add GSC-CS back-end resource init and cleanup

2023-05-10 Thread Alan Previn
For MTL, the PXP back-end transport uses the GSC engine to submit HECI packets through the HW to the GSC firmware for PXP arb session management. This submission uses a non-priveleged batch buffer, a buffer for the command packet and of course a context targeting the GSC-CS. Thus for MTL, we need

[PATCH v10 2/8] drm/i915/pxp: Add MTL hw-plumbing enabling for KCR operation

2023-05-10 Thread Alan Previn
Add MTL hw-plumbing enabling for KCR operation under PXP which includes: 1. Updating 'pick-gt' to get the media tile for KCR interrupt handling 2. Adding MTL's KCR registers for PXP operation (init, status-checking, etc.). While doing #2, lets create a separate registers header file for PXP

[PATCH v10 0/8] drm/i915/pxp: Add MTL PXP Support

2023-05-10 Thread Alan Previn
This series enables PXP on MTL. On ADL/TGL platforms, we rely on the mei driver via the i915-mei PXP component interface to establish a connection to the security firmware via the HECI device interface. That interface is used to create and teardown the PXP ARB session. PXP ARB session is created wh

Re: [PATCH v3] firmware/sysfb: Fix VESA format selection

2023-05-10 Thread Pierre Asselin
Thomas Zimmerman writes: > > I found this casting mess even more unreadable. I went back to v2, fixed > the style issues and committed the patch as v4 (still under your name). > > https://cgit.freedesktop.org/drm/drm-tip/commit?id=1b617bc93178912fa36f87a957c15d1f1708c299 Will this patch make it i

Re: [PATCH] accel/qaic: silence some uninitialized variable warnings

2023-05-10 Thread Dan Carpenter
On Wed, May 10, 2023 at 08:57:03AM -0600, Jeffrey Hugo wrote: > On 5/3/2023 4:41 AM, Dan Carpenter wrote: > > Smatch complains that these are not initialized if get_cntl_version() > > fails but we still print them in the debug message. Not the end of > > the world, but true enough. Let's just ini

[PATCH v2] drm/mediatek: Stop using iommu_present()

2023-05-10 Thread Robin Murphy
Remove the pointless check. If an IOMMU is providing transparent DMA API ops for any device(s) we care about, the DT code will have enforced the appropriate probe ordering already. Signed-off-by: Robin Murphy --- v2: Rebase to 6.4-rc1 drivers/gpu/drm/mediatek/mtk_drm_drv.c | 4 1 file cha

Re: [PATCH v6 5/6] drm: lcdif: Add multiple encoders and first bridges support

2023-05-10 Thread Marek Vasut
On 5/10/23 11:24, Liu Ying wrote: The single LCDIF embedded in i.MX93 SoC may drive multiple displays simultaneously. Look at LCDIF output port's remote port parents to find all enabled first bridges. Add an encoder for each found bridge and attach the bridge to the encoder. This is a preparat

Re: [PATCH v6 2/6] drm: lcdif: Drop unnecessary NULL pointer check on lcdif->bridge

2023-05-10 Thread Marek Vasut
On 5/10/23 11:24, Liu Ying wrote: A valid bridge is already found in lcdif_attach_bridge() and set to lcdif->bridge, so lcdif->bridge cannot be a NULL pointer. Drop the unnecessary NULL pointer check in KMS stage. Tested-by: Alexander Stein Reviewed-by: Alexander Stein Signed-off-by: Liu Ying

Re: [PATCH v2] backlight: lm3630a: turn off both led strings when display is blank

2023-05-10 Thread Sam Ravnborg
On Wed, May 10, 2023 at 10:52:39AM +0200, Maximilian Weigand wrote: > From: Maximilian Weigand > > Use backlight_is_blank() to determine if the led strings should be turned > off in the update_status() functions of both strings. > > Reviewed-by: Daniel Thompson > Signed-off-by: Maximilian Weiga

Re: [PATCH 36/53] drm/panfrost: Convert to platform remove callback returning void

2023-05-10 Thread Steven Price
On 07/05/2023 17:25, Uwe Kleine-König wrote: > The .remove() callback for a platform driver returns an int which makes > many driver authors wrongly assume it's possible to do error handling by > returning an error code. However the value returned is (mostly) ignored > and this typically results in

[PATCH 5/5] gpu: host1x: Stop open-coding of_device_uevent()

2023-05-10 Thread Miquel Raynal
There is apparently no reasons to open-code of_device_uevent() besides: - The helper receives a struct device while we want to use the of_node member of the struct device *parent*. - of_device_uevent() could not be called by modules because of a missing EXPORT_SYMBOL*(). In practice, the forme

[PATCH 1/5] of: module: Mutate of_device_modalias() into two helpers

2023-05-10 Thread Miquel Raynal
Move the content of the helper providing printable modaliases in module.c. Call this new function from an of_device.c inline helper. There is no functional changes. However, as a side effect, we fix the return value of the inline helper (in the !CONFIG_OF case) which should be a ssize_t instead of

[PATCH 3/5] of: module: Mutate of_device_uevent_modalias() into two helpers

2023-05-10 Thread Miquel Raynal
Let's move the logic of the former helper into module.c and use it from an inline helper located under of_device.c. This way there is no change for users while the logic gets moved to an OF-only file. Signed-off-by: Miquel Raynal --- drivers/of/device.c | 23 --- driver

[PATCH 0/5] of: More 'device' vs. 'module' cleanups

2023-05-10 Thread Miquel Raynal
Hello, As part of a previous series, Rob suggested that keeping too much logic in of/device.c was backward and would benefit from a gradual cleanup with the hope some day to move the remaining helpers into inline functions wrapping the proper of_*() methods. Link: https://lore.kernel.org/lkml/ca

[PATCH 4/5] of: module: Export of_uevent()

2023-05-10 Thread Miquel Raynal
The content of of_uevent() is currently hardcoded in a driver that can be compiled as a module. Nothing prevents of_uevent() to be exported to modules, most of the other helpers in of_device.c actually are.The reason why this helper was not exported is because it has been so far only useful in driv

[PATCH 2/5] of: module: Mutate of_device_uevent() into two helpers

2023-05-10 Thread Miquel Raynal
Move the OF related logic inside of/module.c and use it from of_device.h with an inline helper so there is no visible change from the users point of view. Signed-off-by: Miquel Raynal --- drivers/of/device.c | 42 --- drivers/of/module.c | 41 +

Re: [PATCH v6 5/6] fbdev: Move framebuffer I/O helpers into

2023-05-10 Thread Arnd Bergmann
On Wed, May 10, 2023, at 16:27, Thomas Zimmermann wrote: > Am 10.05.23 um 16:15 schrieb Arnd Bergmann: >> On Wed, May 10, 2023, at 16:03, kernel test robot wrote: >> I think that's a preexisting bug and I have no idea what the >> correct solution is. Looking for HD64461 shows it being used >> bot

Re: [PATCH v6 5/6] fbdev: Move framebuffer I/O helpers into

2023-05-10 Thread Thomas Zimmermann
Hi Geert Am 10.05.23 um 16:34 schrieb Geert Uytterhoeven: Hi Thomas, On Wed, May 10, 2023 at 4:20 PM Thomas Zimmermann wrote: Am 10.05.23 um 14:34 schrieb Geert Uytterhoeven: On Wed, May 10, 2023 at 1:06 PM Thomas Zimmermann wrote: Implement framebuffer I/O helpers, such as fb_read*() and

  1   2   >