summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Richardson <[email protected]>2020-08-28 00:09:26 +0100
committerBrian Behlendorf <[email protected]>2020-08-27 16:09:51 -0700
commita00c61db44874285576ae198fd9edb277e8a6670 (patch)
treedaac2b10dcfc08810442d5fcbd95010c449f321b
parentc2068750d7604a2b15254e99acfbb7934927e312 (diff)
Fix definition of BLKGETSIZE64 on FreeBSD
The matching ioctl is DIOCGMEDIASIZE. Reviewed-by: Alexander Motin <[email protected]> Reviewed-by: Brian Behlendorf <[email protected]> Reviewed-by: Ryan Moeller <[email protected]> Signed-off-by: Alex Richardson <[email protected]> Closes #10818
-rw-r--r--lib/libspl/include/os/freebsd/sys/mount.h6
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/libspl/include/os/freebsd/sys/mount.h b/lib/libspl/include/os/freebsd/sys/mount.h
index b40239100..e99518571 100644
--- a/lib/libspl/include/os/freebsd/sys/mount.h
+++ b/lib/libspl/include/os/freebsd/sys/mount.h
@@ -35,12 +35,8 @@
#include <string.h>
#include <stdlib.h>
-/*
- * Some old glibc headers don't define BLKGETSIZE64
- * and we don't want to require the kernel headers
- */
#if !defined(BLKGETSIZE64)
-#define BLKGETSIZE64 _IOR(0x12, 114, size_t)
+#define BLKGETSIZE64 DIOCGMEDIASIZE
#endif
/*