Fix issues on win32 with multithreading.

We weren't properly rechecking based on spurious wakeups (which
technically can happen on x64 too.)
Fix incorrect state after reset in multithreading.

This would change coreState from CORE_POWERUP too early.  It's already
done in BootDone().
Merge pull request #6514 from unknownbrackets/multithread

Fix a couple minor issues in multithreading