28 lines
516 B
Diff
28 lines
516 B
Diff
|
From: Michal Kubecek <mkubecek@suse.cz>
|
||
|
Date: Fri, 15 Jan 2016 07:30:15 +0100
|
||
|
Subject: use sysconf(_SC_CLK_TCK) if HZ undefined
|
||
|
Patch-mainline: No
|
||
|
|
||
|
---
|
||
|
lib/utils.c | 4 ++++
|
||
|
1 file changed, 4 insertions(+)
|
||
|
|
||
|
diff --git a/lib/utils.c b/lib/utils.c
|
||
|
index e77bd302530b..0919bb201229 100644
|
||
|
--- a/lib/utils.c
|
||
|
+++ b/lib/utils.c
|
||
|
@@ -49,6 +49,10 @@ int get_hex(char c)
|
||
|
return -1;
|
||
|
}
|
||
|
|
||
|
+#ifndef HZ
|
||
|
+#define HZ sysconf(_SC_CLK_TCK)
|
||
|
+#endif
|
||
|
+
|
||
|
int get_integer(int *val, const char *arg, int base)
|
||
|
{
|
||
|
long res;
|
||
|
--
|
||
|
2.14.1
|
||
|
|