File tree Expand file tree Collapse file tree
drivers/gpu/drm/msm/disp/dpu1 Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11// SPDX-License-Identifier: GPL-2.0-only
22/*
33 * Copyright (c) 2016-2018, The Linux Foundation. All rights reserved.
4- * Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
4+ * Copyright (c) 2023-2024 Qualcomm Innovation Center, Inc. All rights reserved.
55 */
66
77#define pr_fmt (fmt ) "[drm:%s] " fmt, __func__
88#include "dpu_kms.h"
99#include "dpu_hw_lm.h"
1010#include "dpu_hw_ctl.h"
1111#include "dpu_hw_cdm.h"
12+ #include "dpu_hw_cwb.h"
1213#include "dpu_hw_pingpong.h"
1314#include "dpu_hw_sspp.h"
1415#include "dpu_hw_intf.h"
@@ -122,6 +123,19 @@ int dpu_rm_init(struct drm_device *dev,
122123 rm -> hw_wb [wb -> id - WB_0 ] = hw ;
123124 }
124125
126+ for (i = 0 ; i < cat -> cwb_count ; i ++ ) {
127+ struct dpu_hw_cwb * hw ;
128+ const struct dpu_cwb_cfg * cwb = & cat -> cwb [i ];
129+
130+ hw = dpu_hw_cwb_init (dev , cwb , mmio );
131+ if (IS_ERR (hw )) {
132+ rc = PTR_ERR (hw );
133+ DPU_ERROR ("failed cwb object creation: err %d\n" , rc );
134+ goto fail ;
135+ }
136+ rm -> cwb_blks [cwb -> id - CWB_0 ] = & hw -> base ;
137+ }
138+
125139 for (i = 0 ; i < cat -> ctl_count ; i ++ ) {
126140 struct dpu_hw_ctl * hw ;
127141 const struct dpu_ctl_cfg * ctl = & cat -> ctl [i ];
Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ struct dpu_global_state;
2020 * @ctl_blks: array of ctl hardware resources
2121 * @hw_intf: array of intf hardware resources
2222 * @hw_wb: array of wb hardware resources
23+ * @hw_cwb: array of cwb hardware resources
2324 * @dspp_blks: array of dspp hardware resources
2425 * @hw_sspp: array of sspp hardware resources
2526 * @cdm_blk: cdm hardware resource
@@ -30,6 +31,7 @@ struct dpu_rm {
3031 struct dpu_hw_blk * ctl_blks [CTL_MAX - CTL_0 ];
3132 struct dpu_hw_intf * hw_intf [INTF_MAX - INTF_0 ];
3233 struct dpu_hw_wb * hw_wb [WB_MAX - WB_0 ];
34+ struct dpu_hw_blk * cwb_blks [CWB_MAX - CWB_0 ];
3335 struct dpu_hw_blk * dspp_blks [DSPP_MAX - DSPP_0 ];
3436 struct dpu_hw_blk * merge_3d_blks [MERGE_3D_MAX - MERGE_3D_0 ];
3537 struct dpu_hw_blk * dsc_blks [DSC_MAX - DSC_0 ];
You can’t perform that action at this time.
0 commit comments