* Make cpuid driver preempt safe.
@ 2003-03-24 16:41 davej
0 siblings, 0 replies; only message in thread
From: davej @ 2003-03-24 16:41 UTC (permalink / raw)
To: torvalds; +Cc: linux-kernel
diff -urpN --exclude-from=/home/davej/.exclude bk-linus/arch/i386/kernel/cpuid.c linux-2.5/arch/i386/kernel/cpuid.c
--- bk-linus/arch/i386/kernel/cpuid.c 2003-03-08 09:56:25.000000000 +0000
+++ linux-2.5/arch/i386/kernel/cpuid.c 2003-03-18 21:22:12.000000000 +0000
@@ -64,6 +64,7 @@ static inline void do_cpuid(int cpu, u32
{
struct cpuid_command cmd;
+ preempt_disable();
if ( cpu == smp_processor_id() ) {
cpuid(reg, &data[0], &data[1], &data[2], &data[3]);
} else {
@@ -73,6 +74,7 @@ static inline void do_cpuid(int cpu, u32
smp_call_function(cpuid_smp_cpuid, &cmd, 1, 1);
}
+ preempt_enable();
}
#else /* ! CONFIG_SMP */
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2003-03-24 16:34 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-03-24 16:41 Make cpuid driver preempt safe davej
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®