DragonFlyBSD Kernel Audit
DF-1302 / fix.diff
← back to finding ↓ download raw
diff --git a/sys/dev/drm/amd/display/dc/dce110/dce110_hw_sequencer.c b/sys/dev/drm/amd/display/dc/dce110/dce110_hw_sequencer.c
--- a/sys/dev/drm/amd/display/dc/dce110/dce110_hw_sequencer.c
+++ b/sys/dev/drm/amd/display/dc/dce110/dce110_hw_sequencer.c
@@ -1620,7 +1620,7 @@
 
 	total_dest_line_time_ns = 1000000UL *
 		stream->timing.h_total /
-		stream->timing.pix_clk_khz +
+		(stream->timing.pix_clk_khz ? stream->timing.pix_clk_khz : 1) +
 		pstate_blackout_duration_ns;
 
 	return total_dest_line_time_ns;