diff options
author | Adam Leventhal <ahl@delphix.com> | 2013-08-28 16:05:48 -0700 |
---|---|---|
committer | Brian Behlendorf <behlendorf1@llnl.gov> | 2013-11-04 10:55:25 -0800 |
commit | 63fd3c6cfd264cab94dc186fe8cceecac8bc0d50 (patch) | |
tree | 2b4c580be7c82a4c5160ef99c0020c4752ba9eff /lib/libspl | |
parent | c1fabe7961b100a7dfd77cddba1650d9a6580dc0 (diff) |
Illumos #3582, #3584
3582 zfs_delay() should support a variable resolution
3584 DTrace sdt probes for ZFS txg states
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Christopher Siden <christopher.siden@delphix.com>
Reviewed by: Dan McDonald <danmcd@nexenta.com>
Reviewed by: Richard Elling <richard.elling@dey-sys.com>
Approved by: Garrett D'Amore <garrett@damore.org>
References:
https://www.illumos.org/issues/3582
illumos/illumos-gate@0689f76
Ported by: Ned Bass <bass6@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Issue #1775
Diffstat (limited to 'lib/libspl')
-rw-r--r-- | lib/libspl/include/sys/time.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/libspl/include/sys/time.h b/lib/libspl/include/sys/time.h index 0cbbd928d..852b2eff9 100644 --- a/lib/libspl/include/sys/time.h +++ b/lib/libspl/include/sys/time.h @@ -50,6 +50,14 @@ #define NSEC_PER_USEC 1000L #endif +#ifndef MSEC2NSEC +#define MSEC2NSEC(m) ((hrtime_t)(m) * (NANOSEC / MILLISEC)) +#endif + +#ifndef NSEC2MSEC +#define NSEC2MSEC(n) ((n) / (NANOSEC / MILLISEC)) +#endif + extern hrtime_t gethrtime(void); extern void gethrestime(timestruc_t *); |