sched: core: fixed a thread queue build warning

If thread queue's were disabled, the thread header
(include/etaos/thread.h) would trigger an inside parameter list struct
declaration warning. Fixed it by putting the function in question in and
ifdef check.

Signed-off-by: Michel Megens <dev@michelmegens.net>
sched: core: fixed an unresolved mutex ref.

If thread queue's are disabled, some drivers would have an unresolved
reference to `mutex_unlock_from_irq'. Fixed by implementing the correct
function if mutexes are configured as traditional (nopping) locks.

Signed-off-by: Michel Megens <dev@michelmegens.net>
time: delay: added a loop loop delay

Added a 2 looping delay functions:

	* delay(uint ms)
	* delay_us(double delay)

delay:
	Does NOPs until the given amount of miliseconds have passed.

delay_us:
	Does NOPs until the given amout of microseconds have passed.

Signed-off-by: Michel Megens <dev@michelmegens.net>
i2c: core: fixed a timeout bug in the I2C core.

The I2C core transmission function wasn't properly checking if a timeout
had occurred. Fixed by replacing `orig_tick' with `sys_tick' in the
time_after statement.

Also I've added some docs to the delay functions kernel/delay.c

Signed-off-by: Michel Megens <dev@michelmegens.net>
ETA/OS 1.1.2

Signed-off-by: Michel Megens <dev@michelmegens.net>