diff options
author | John Sonnenschein <johns@joyent.com> | 2012-01-12 21:43:07 +0000 |
---|---|---|
committer | John Sonnenschein <johns@joyent.com> | 2012-01-12 21:43:07 +0000 |
commit | ffd3d51cda0d52ac103aaa51865ea8b99ce2bc39 (patch) | |
tree | caccc892b2859e382f40b29bf961281341b6e99c /usr/src/uts/common/os/timer.c | |
parent | 1636e739ebc2ac80c49a1e69f71fda812db48850 (diff) | |
parent | 9aac36a25d67d80901ad3284d1c2045d3d1a6d64 (diff) | |
download | illumos-joyent-ffd3d51cda0d52ac103aaa51865ea8b99ce2bc39.tar.gz |
Merge branch 'master' into gcc4
Diffstat (limited to 'usr/src/uts/common/os/timer.c')
-rw-r--r-- | usr/src/uts/common/os/timer.c | 23 |
1 files changed, 3 insertions, 20 deletions
diff --git a/usr/src/uts/common/os/timer.c b/usr/src/uts/common/os/timer.c index 57c1ed97bd..57e369adca 100644 --- a/usr/src/uts/common/os/timer.c +++ b/usr/src/uts/common/os/timer.c @@ -24,7 +24,9 @@ * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" +/* + * Copyright (c) 2012, Joyent, Inc. All rights reserved. + */ #include <sys/timer.h> #include <sys/systm.h> @@ -772,25 +774,6 @@ timer_settime(timer_t tid, int flags, itimerspec_t *val, itimerspec_t *oval) if ((it = timer_grab(p, tid)) == NULL) return (set_errno(EINVAL)); - /* - * From the man page: - * Time values that are between two consecutive non-negative - * integer multiples of the resolution of the specified timer - * shall be rounded up to the larger multiple of the resolution. - * We assume that the resolution of any clock is less than one second. - */ - if (it->it_backend->clk_clock_getres(&res) == 0 && res.tv_nsec > 1) { - long rem; - - if ((rem = when.it_interval.tv_nsec % res.tv_nsec) != 0) { - when.it_interval.tv_nsec += res.tv_nsec - rem; - timespecfix(&when.it_interval); - } - if ((rem = when.it_value.tv_nsec % res.tv_nsec) != 0) { - when.it_value.tv_nsec += res.tv_nsec - rem; - timespecfix(&when.it_value); - } - } error = it->it_backend->clk_timer_settime(it, flags, &when); timer_release(p, it); |