Skip to contentSkip to conversation

drm/amd/display: Simplify bool conversion

PATCH New [email protected] 1 participant 1 message Nov 6, 2022

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/amd/display: Simplify bool conversion

Fix the following coccicheck warning:

drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_crtc.c:109:52-57:
WARNING: conversion to bool not needed here

---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_crtc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_crtc.c +1 -1
index 3675b39e297a..bdac1ea12471 100644
@@ -106,7 +106,7 @@ static void vblank_control_worker(struct work_struct *work)
 		dm->active_vblank_irq_count--;
 
 	dc_allow_idle_optimizations(
-		dm->dc, dm->active_vblank_irq_count == 0 ? true : false);
+		dm->dc, dm->active_vblank_irq_count != 0);
 
 	DRM_DEBUG_KMS("Allow idle optimizations (MALL): %d\n", dm->active_vblank_irq_count == 0);
 
Signature · 1 line
2.25.1