From: Ingo Molnar Date: Mon, 15 Oct 2007 15:00:13 +0000 (+0200) Subject: sched: break out if printing a warning in sched_domain_debug() X-Git-Tag: v2.6.24-rc1~1289^2~44 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=26797a34a24cfeab9951a6f42f27432c0b2546af;p=linux-2.6 sched: break out if printing a warning in sched_domain_debug() checkpatch.pl and Andy Whitcroft noticed the following bug: we did not break out after printing an error. Signed-off-by: Ingo Molnar --- diff --git a/kernel/sched.c b/kernel/sched.c index 1a80ac1b6d..7fefd8ab8b 100644 --- a/kernel/sched.c +++ b/kernel/sched.c @@ -5534,16 +5534,19 @@ static void sched_domain_debug(struct sched_domain *sd, int cpu) printk("\n"); printk(KERN_ERR "ERROR: domain->cpu_power not " "set\n"); + break; } if (!cpus_weight(group->cpumask)) { printk("\n"); printk(KERN_ERR "ERROR: empty group\n"); + break; } if (cpus_intersects(groupmask, group->cpumask)) { printk("\n"); printk(KERN_ERR "ERROR: repeated CPUs\n"); + break; } cpus_or(groupmask, groupmask, group->cpumask);