Fixing race condition for timers in os_waitqueue_prepare.
Unfortunately I detected a few new things
Intermediate state
We have 2 issues to fix:
- missing timeout destroy inside os_waitqueue_destroy() (for this I started to
  additional test case in test_waitqueue.c but then I found second issue)
- something is wrong with setting task->block_code ... on test it is shown as
  OS_TIMEOUTED, while it should be OS_OK because we signalize all tasks
  I left this work in the middle. THere is FIXME inside os_waitqueue_wakeup_sync
  describibg that