diff options
author | kib <kib@FreeBSD.org> | 2015-08-12 09:43:12 +0000 |
---|---|---|
committer | kib <kib@FreeBSD.org> | 2015-08-12 09:43:12 +0000 |
commit | bff0ec5bef3ded3c67c6216c640936ddc7ecc6cc (patch) | |
tree | 3ba70608cf6f80a0055a84464c4fdc84661a9d2e /sys/i386 | |
parent | aa4ad58f86b7a49c39a2491f4738a26a72687ef6 (diff) | |
download | FreeBSD-src-bff0ec5bef3ded3c67c6216c640936ddc7ecc6cc.zip FreeBSD-src-bff0ec5bef3ded3c67c6216c640936ddc7ecc6cc.tar.gz |
AP should load aps_ready with acquire semantic to see BSP updates to
the SMP structures, synchronized with the load by release store in
release_aps().
The change is formal, x86 strong memory model implicitely provided
the guarantees.
Discussed with: bde
Tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks
Diffstat (limited to 'sys/i386')
-rw-r--r-- | sys/i386/i386/mp_machdep.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/i386/i386/mp_machdep.c b/sys/i386/i386/mp_machdep.c index 4812cb0..93845ef 100644 --- a/sys/i386/i386/mp_machdep.c +++ b/sys/i386/i386/mp_machdep.c @@ -291,7 +291,7 @@ init_secondary(void) CHECK_WRITE(0x39, 6); /* Spin until the BSP releases the AP's. */ - while (!aps_ready) + while (atomic_load_acq_int(&aps_ready) == 0) ia32_pause(); /* BSP may have changed PTD while we were waiting */ |