aboutsummaryrefslogtreecommitdiff
path: root/kernel/smp.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/smp.c')
-rw-r--r--kernel/smp.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/kernel/smp.c b/kernel/smp.c
index 87f82e6cc..d02575408 100644
--- a/kernel/smp.c
+++ b/kernel/smp.c
@@ -12,6 +12,7 @@
#include <linux/gfp.h>
#include <linux/smp.h>
#include <linux/cpu.h>
+#include <asm/relaxed.h>
#include "smpboot.h"
@@ -101,8 +102,8 @@ void __init call_function_init(void)
*/
static void csd_lock_wait(struct call_single_data *csd)
{
- while (csd->flags & CSD_FLAG_LOCK)
- cpu_relax();
+ while (cpu_relaxed_read_short(&csd->flags) & CSD_FLAG_LOCK)
+ cpu_read_relax();
}
static void csd_lock(struct call_single_data *csd)