Skip to content

Commit 786de93

Browse files
Abhinav Kumarlumag
authored andcommitted
drm/msm/dpu: rename dpu_hw_pipe_cdp_cfg to dpu_hw_cdp_cfg
Rename dpu_hw_pipe_cdp_cfg to dpu_hw_cdp_cfg and move it to dpu_hw_utils file so that other modules in addition to SSPP such as writeback can use it as all the fields can be used by writeback as well. Suggested-by: Dmitry Baryshkov <[email protected]> Signed-off-by: Abhinav Kumar <[email protected]> Reviewed-by: Dmitry Baryshkov <[email protected]> Patchwork: https://patchwork.freedesktop.org/patch/483503/ Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Dmitry Baryshkov <[email protected]>
1 parent e1a950e commit 786de93

File tree

4 files changed

+19
-20
lines changed

4 files changed

+19
-20
lines changed

drivers/gpu/drm/msm/disp/dpu1/dpu_hw_sspp.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -627,7 +627,7 @@ static void dpu_hw_sspp_setup_qos_ctrl(struct dpu_hw_pipe *ctx,
627627
}
628628

629629
static void dpu_hw_sspp_setup_cdp(struct dpu_hw_pipe *ctx,
630-
struct dpu_hw_pipe_cdp_cfg *cfg,
630+
struct dpu_hw_cdp_cfg *cfg,
631631
enum dpu_sspp_multirect_index index)
632632
{
633633
u32 idx;

drivers/gpu/drm/msm/disp/dpu1/dpu_hw_sspp.h

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -192,22 +192,6 @@ enum {
192192
DPU_SSPP_CDP_PRELOAD_AHEAD_64
193193
};
194194

195-
/**
196-
* struct dpu_hw_pipe_cdp_cfg : CDP configuration
197-
* @enable: true to enable CDP
198-
* @ubwc_meta_enable: true to enable ubwc metadata preload
199-
* @tile_amortize_enable: true to enable amortization control for tile format
200-
* @preload_ahead: number of request to preload ahead
201-
* DPU_SSPP_CDP_PRELOAD_AHEAD_32,
202-
* DPU_SSPP_CDP_PRELOAD_AHEAD_64
203-
*/
204-
struct dpu_hw_pipe_cdp_cfg {
205-
bool enable;
206-
bool ubwc_meta_enable;
207-
bool tile_amortize_enable;
208-
u32 preload_ahead;
209-
};
210-
211195
/**
212196
* struct dpu_hw_pipe_ts_cfg - traffic shaper configuration
213197
* @size: size to prefill in bytes, or zero to disable
@@ -359,7 +343,7 @@ struct dpu_hw_sspp_ops {
359343
* @index: rectangle index in multirect
360344
*/
361345
void (*setup_cdp)(struct dpu_hw_pipe *ctx,
362-
struct dpu_hw_pipe_cdp_cfg *cfg,
346+
struct dpu_hw_cdp_cfg *cfg,
363347
enum dpu_sspp_multirect_index index);
364348
};
365349

drivers/gpu/drm/msm/disp/dpu1/dpu_hw_util.h

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -298,6 +298,21 @@ struct dpu_drm_scaler_v2 {
298298
struct dpu_drm_de_v1 de;
299299
};
300300

301+
/**
302+
* struct dpu_hw_cdp_cfg : CDP configuration
303+
* @enable: true to enable CDP
304+
* @ubwc_meta_enable: true to enable ubwc metadata preload
305+
* @tile_amortize_enable: true to enable amortization control for tile format
306+
* @preload_ahead: number of request to preload ahead
307+
* DPU_*_CDP_PRELOAD_AHEAD_32,
308+
* DPU_*_CDP_PRELOAD_AHEAD_64
309+
*/
310+
struct dpu_hw_cdp_cfg {
311+
bool enable;
312+
bool ubwc_meta_enable;
313+
bool tile_amortize_enable;
314+
u32 preload_ahead;
315+
};
301316

302317
u32 *dpu_hw_util_get_log_mask_ptr(void);
303318

drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1246,9 +1246,9 @@ static void dpu_plane_sspp_atomic_update(struct drm_plane *plane)
12461246
pstate->multirect_index);
12471247

12481248
if (pdpu->pipe_hw->ops.setup_cdp) {
1249-
struct dpu_hw_pipe_cdp_cfg cdp_cfg;
1249+
struct dpu_hw_cdp_cfg cdp_cfg;
12501250

1251-
memset(&cdp_cfg, 0, sizeof(struct dpu_hw_pipe_cdp_cfg));
1251+
memset(&cdp_cfg, 0, sizeof(struct dpu_hw_cdp_cfg));
12521252

12531253
cdp_cfg.enable = pdpu->catalog->perf.cdp_cfg
12541254
[DPU_PERF_CDP_USAGE_RT].rd_enable;

0 commit comments

Comments
 (0)