[JFFS2] Fix lack of locking in thread_should_wake()