Skip to content

Commit 196da3f

Browse files
cristiccmmind
authored andcommitted
drm/rockchip: vop2: Drop unused if_dclk_rate variable
Commit 5a028e8 ("drm/rockchip: vop2: Add support for rk3588") introduced a variable which ended up being unused: rockchip_drm_vop2.c:1688:23: warning: variable ‘if_dclk_rate’ set but not used [-Wunused-but-set-variable] This has been initially used as part of a formula to compute the clock dividers, but eventually it has been replaced by static values. Drop the variable declaration and move its assignment to the comment block, to serve as documentation of how the constants have been generated. Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patchwork.freedesktop.org/patch/msgid/20240105174007.98054-1-cristian.ciocaltea@collabora.com
1 parent 38709af commit 196da3f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

drivers/gpu/drm/rockchip/rockchip_drm_vop2.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1680,7 +1680,6 @@ static unsigned long rk3588_calc_cru_cfg(struct vop2_video_port *vp, int id,
16801680
unsigned long dclk_core_rate = v_pixclk >> 2;
16811681
unsigned long dclk_rate = v_pixclk;
16821682
unsigned long dclk_out_rate;
1683-
unsigned long if_dclk_rate;
16841683
unsigned long if_pixclk_rate;
16851684
int K = 1;
16861685

@@ -1695,8 +1694,8 @@ static unsigned long rk3588_calc_cru_cfg(struct vop2_video_port *vp, int id,
16951694
}
16961695

16971696
if_pixclk_rate = (dclk_core_rate << 1) / K;
1698-
if_dclk_rate = dclk_core_rate / K;
16991697
/*
1698+
* if_dclk_rate = dclk_core_rate / K;
17001699
* *if_pixclk_div = dclk_rate / if_pixclk_rate;
17011700
* *if_dclk_div = dclk_rate / if_dclk_rate;
17021701
*/

0 commit comments

Comments
 (0)