Browse Source

disp: msm: sde: use rate limited print for crtc event thread

When the vblank event overflow error log occurs due to an inability
to handle incoming vblanks, it is posisble to continuously flood
with error print logs. This could cause the CPU to become further
blocked and creates a cycle of failed callbacks and error logging.

This change changes the overflow log in the crtc event thread to
rate limited.

Change-Id: Ie2d77689c8fa989cf3a294f973851b7dacef098b
Signed-off-by: Nilaan Gunabalachandran <[email protected]>
Nilaan Gunabalachandran 2 năm trước cách đây
mục cha
commit
68d3217032
1 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 2 2
      msm/sde/sde_crtc.c

+ 2 - 2
msm/sde/sde_crtc.c

@@ -2825,7 +2825,7 @@ static void sde_crtc_frame_event_cb(void *data, u32 event, ktime_t ts)
 	spin_unlock_irqrestore(&sde_crtc->event_spin_lock, flags);
 
 	if (!fevent) {
-		SDE_ERROR("crtc%d event %d overflow\n", DRMID(crtc), event);
+		pr_err_ratelimited("crtc%d event %d overflow\n", DRMID(crtc), event);
 		SDE_EVT32(DRMID(crtc), event);
 		return;
 	}
@@ -3079,7 +3079,7 @@ static void sde_crtc_vblank_cb(void *data, ktime_t ts)
 	priv = sde_kms->dev->dev_private;
 
 	if (!vevent) {
-		SDE_ERROR("crtc%d vblank event overflow\n", DRMID(crtc));
+		pr_err_ratelimited("crtc%d vblank event overflow\n", DRMID(crtc));
 		SDE_EVT32(DRMID(crtc), SDE_EVTLOG_ERROR);
 		return;
 	}