Prechádzať zdrojové kódy

check_hung_task(): unsigned sysctl_hung_task_warnings cannot be less than 0

Impact: fix warnings-limit cutoff check for debug feature

unsigned sysctl_hung_task_warnings cannot be less than 0

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Roel Kluin 16 rokov pred
rodič
commit
201955463a
1 zmenil súbory, kde vykonal 1 pridanie a 1 odobranie
  1. 1 1
      kernel/softlockup.c

+ 1 - 1
kernel/softlockup.c

@@ -188,7 +188,7 @@ static void check_hung_task(struct task_struct *t, unsigned long now)
 	if ((long)(now - t->last_switch_timestamp) <
 					sysctl_hung_task_timeout_secs)
 		return;
-	if (sysctl_hung_task_warnings < 0)
+	if (!sysctl_hung_task_warnings)
 		return;
 	sysctl_hung_task_warnings--;