FreeBSD: use generic bdev size retrieval

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
diff --git a/os/os-freebsd.h b/os/os-freebsd.h
index 3939d65..e517ec0 100644
--- a/os/os-freebsd.h
+++ b/os/os-freebsd.h
@@ -17,7 +17,13 @@
  */
 static inline int blockdev_size(int fd, unsigned long long *bytes)
 {
-	return EINVAL;
+	off_t end = lseek(fd, 0, SEEK_END);
+
+	if (end < 0)
+		return errno;
+
+	*bytes = end;
+	return 0;
 }
 
 static inline int blockdev_invalidate_cache(int fd)