diff options
| author | Jeff Garzik <jgarzik@pobox.com> | 2005-08-17 00:51:31 -0400 |
|---|---|---|
| committer | Jeff Garzik <jgarzik@pobox.com> | 2005-08-17 00:51:31 -0400 |
| commit | a2e30e529a48ef4e106e405f91cf4ae525bb01c4 (patch) | |
| tree | 2def96ef17c0672c30f1a10287552978bf1d0b1c /kernel/posix-timers.c | |
| parent | edb3366703224d5d8df573ae698ccd6b488dc743 (diff) | |
| parent | 2ad56496627630ebc99f06af5f81ca23e17e014e (diff) | |
Merge /spare/repo/linux-2.6/
Diffstat (limited to 'kernel/posix-timers.c')
| -rw-r--r-- | kernel/posix-timers.c | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/kernel/posix-timers.c b/kernel/posix-timers.c index 5b7b4736d82..38798a2ff99 100644 --- a/kernel/posix-timers.c +++ b/kernel/posix-timers.c @@ -896,21 +896,10 @@ static int adjust_abs_time(struct k_clock *clock, struct timespec *tp, jiffies_64_f = get_jiffies_64(); } /* - * Take away now to get delta + * Take away now to get delta and normalize */ - oc.tv_sec -= now.tv_sec; - oc.tv_nsec -= now.tv_nsec; - /* - * Normalize... - */ - while ((oc.tv_nsec - NSEC_PER_SEC) >= 0) { - oc.tv_nsec -= NSEC_PER_SEC; - oc.tv_sec++; - } - while ((oc.tv_nsec) < 0) { - oc.tv_nsec += NSEC_PER_SEC; - oc.tv_sec--; - } + set_normalized_timespec(&oc, oc.tv_sec - now.tv_sec, + oc.tv_nsec - now.tv_nsec); }else{ jiffies_64_f = get_jiffies_64(); } @@ -1177,7 +1166,6 @@ void exit_itimers(struct signal_struct *sig) tmr = list_entry(sig->posix_timers.next, struct k_itimer, list); itimer_delete(tmr); } - del_timer_sync(&sig->real_timer); } /* |
