Subversion Repositories HelenOS

Compare Revisions

Regard whitespace Rev 411 → Rev 404

/SPARTAN/trunk/src/time/timeout.c
52,11 → 52,11
}
 
 
/** Reinitialize timeout
/** Initialize empty timeout list
*
* Initialize all members except the lock.
* Initialize the timeout list to be empty.
*
* @param t Timeout to be initialized.
* @param t Timeout list to be initialized.
*
*/
void timeout_reinitialize(timeout_t *t)
69,11 → 69,11
}
 
 
/** Initialize timeout
/** Initialize timeout list
*
* Initialize all members including the lock.
* Initialize the timeout list and its spinlock.
*
* @param t Timeout to be initialized.
* @param t Timeout list to be initialized.
*
*/
void timeout_initialize(timeout_t *t)
83,13 → 83,13
}
 
 
/** Register timeout
/** Register timeout callback
*
* Insert timeout handler f (with argument arg)
* to timeout list and make it execute in
* Insert the timeout handler f (with argument arg)
* to the timeout list and make it execute in
* time microseconds (or slightly more).
*
* @param t Timeout structure.
* @param t Timeout list.
* @param time Number of usec in the future to execute
* the handler.
* @param f Timeout handler function.
96,7 → 96,7
* @param arg Timeout handler argument.
*
*/
void timeout_register(timeout_t *t, __u64 time, timeout_handler_t f, void *arg)
void timeout_register(timeout_t *t, __u64 time, timeout_handler f, void *arg)
{
timeout_t *hlp;
link_t *l, *m;
156,15 → 156,14
}
 
 
/** Unregister timeout
/** Unregister timeout callback
*
* Remove timeout from timeout list.
*
* @param t Timeout to unregister.
*
* @return true on success, false on failure.
*/
bool timeout_unregister(timeout_t *t)
int timeout_unregister(timeout_t *t)
{
timeout_t *hlp;
link_t *l;
176,7 → 175,7
if (!t->cpu) {
spinlock_unlock(&t->lock);
cpu_priority_restore(pri);
return false;
return 0;
}
if (!spinlock_trylock(&t->cpu->timeoutlock)) {
spinlock_unlock(&t->lock);
204,5 → 203,5
spinlock_unlock(&t->lock);
 
cpu_priority_restore(pri);
return true;
return 1;
}
/SPARTAN/trunk/src/time/clock.c
52,7 → 52,7
{
link_t *l;
timeout_t *h;
timeout_handler_t f;
timeout_handler f;
void *arg;
 
/*