In order to achieve a correct (in many runs) calculation I'd say you need to disable interrupts at the start of `hwtimer_wait`, because the wait period is external to it. You can reenable them after calling `hwtimer_now` though, because it does not matter if a potential interrupt occurs before or after adding `now + delay`, the result is the same.

A correct (with regard to time spent waiting) implementation of `hwtimer_wait` would need to be run with interrupts disabled before the delay is calculated in the aplication. The hardware timer needs interrupts in order to work, so it does not make any sense to use it for high precision timing. You will have to live with time spent in ISRs in any case or implement a high precision timer API.

As for the time spent in another task: we have a priority based scheduler. Unless you need a high-precision timer, this is a case for a higher prioritized task.