aboutsummaryrefslogtreecommitdiffstats
path: root/module/spl/spl-generic.c
diff options
context:
space:
mode:
Diffstat (limited to 'module/spl/spl-generic.c')
-rw-r--r--module/spl/spl-generic.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/module/spl/spl-generic.c b/module/spl/spl-generic.c
index 2a8972691..b38fe254c 100644
--- a/module/spl/spl-generic.c
+++ b/module/spl/spl-generic.c
@@ -43,9 +43,8 @@
#include <linux/ctype.h>
#include <sys/disp.h>
#include <sys/random.h>
+#include <sys/strings.h>
#include <linux/kmod.h>
-#include <linux/math64_compat.h>
-#include <linux/proc_compat.h>
char spl_version[32] = "SPL v" SPL_META_VERSION "-" SPL_META_RELEASE;
EXPORT_SYMBOL(spl_version);
@@ -260,6 +259,12 @@ __udivdi3(uint64_t u, uint64_t v)
}
EXPORT_SYMBOL(__udivdi3);
+/* BEGIN CSTYLED */
+#ifndef abs64
+#define abs64(x) ({ uint64_t t = (x) >> 63; ((x) ^ t) - t; })
+#endif
+/* END CSTYLED */
+
/*
* Implementation of 64-bit signed division for 32-bit machines.
*/