Make sure all pending operations have completed on the existing thread

before (potentially) migrating it to a different CPU.

MFC after:	5 days
This commit is contained in:
Nathan Whitehorn 2012-04-20 23:01:36 +00:00
parent 15a353ce97
commit c13aac3896
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=234517
2 changed files with 2 additions and 0 deletions

View File

@ -113,6 +113,7 @@ ENTRY(cpu_switch)
mr %r3,%r14 /* restore old thread ptr */
bl pmap_deactivate /* Deactivate the current pmap */
sync /* Make sure all of that finished */
stw %r16,TD_LOCK(%r14) /* ULE: update old thread's lock */
cpu_switchin:

View File

@ -139,6 +139,7 @@ ENTRY(cpu_switch)
addi %r1,%r1,48
sync /* Make sure all of that finished */
std %r16,TD_LOCK(%r14) /* ULE: update old thread's lock */
cpu_switchin: