[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070828090709.GA24578@elte.hu>
Date: Tue, 28 Aug 2007 11:07:09 +0200
From: Ingo Molnar <mingo@...e.hu>
To: Hugh Dickins <hugh@...itas.com>
Cc: linux-kernel@...r.kernel.org,
Linus Torvalds <torvalds@...ux-foundation.org>
Subject: Re: fix bogus hotplug cpu warning
this commit:
commit d243769d3f83b318813a04a9592bb7cfedc6c280
Author: Hugh Dickins <hugh@...itas.com>
Date: Mon Aug 27 16:06:19 2007 +0100
fix bogus hotplug cpu warning
Fix bogus DEBUG_PREEMPT warning on x86_64, when cpu brought online
after bootup: current_is_keventd is right to note its use of
smp_processor_id is preempt-safe, but should use
raw_smp_processor_id to avoid the warning.
- int cpu = smp_processor_id(); /* preempt-safe: keventd is per-cpu */
+ int cpu = raw_smp_processor_id(); /* preempt-safe: keventd is per-cpu */
is incorrect. smp_processor_id() will _not_ warn about true per-cpu
tasks:
/*
* Kernel threads bound to a single CPU can safely use
* smp_processor_id():
*/
this_mask = cpumask_of_cpu(this_cpu);
if (cpus_equal(current->cpus_allowed, this_mask))
goto out;
so if this check triggered for the cpu-offline code it's because keventd
was _not_ per-cpu (perhaps because the cpu offline code broke its
affinity?). So your patch hides a real bug.
Ingo
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists