提交 2ab21bb9 编写于 作者: D Deepak R Varma 提交者: Alex Deucher

drm/amd/display: Conversion to bool not necessary

A logical evaluation already results in bool. There is no need for using
a ternary operator based evaluation and bool conversion of the outcome.
Issue identified using boolconv.cocci Coccinelle semantic patch.
This was also reported by the Kernel Test Robot. Hence

Fixes: 473683a0 ("drm/amd/display: Create a file dedicated for CRTC")
Reported-by: Nkernel test robot <lkp@intel.com>
Signed-off-by: NDeepak R Varma <drv@mailo.com>
Signed-off-by: NAlex Deucher <alexander.deucher@amd.com>
上级 35a45d63
...@@ -105,8 +105,7 @@ static void vblank_control_worker(struct work_struct *work) ...@@ -105,8 +105,7 @@ static void vblank_control_worker(struct work_struct *work)
else if (dm->active_vblank_irq_count) else if (dm->active_vblank_irq_count)
dm->active_vblank_irq_count--; dm->active_vblank_irq_count--;
dc_allow_idle_optimizations( dc_allow_idle_optimizations(dm->dc, dm->active_vblank_irq_count == 0);
dm->dc, dm->active_vblank_irq_count == 0 ? true : false);
DRM_DEBUG_KMS("Allow idle optimizations (MALL): %d\n", dm->active_vblank_irq_count == 0); DRM_DEBUG_KMS("Allow idle optimizations (MALL): %d\n", dm->active_vblank_irq_count == 0);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册