zfs-test/mmap_seek: fix build on musl

The build on musl needs linux/fs.h for SEEK_DATA and friends,
and sys/sysmacros.h for P2ROUNDUP.  Add the needed headers.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org>
Closes #12891
This commit is contained in:
Georgy Yakovlev 2021-12-21 16:44:18 -08:00 committed by GitHub
parent bfb3b0d77a
commit 2f411512be
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -29,7 +29,11 @@
#include <stdlib.h>
#include <string.h>
#include <sys/mman.h>
#include <sys/sysmacros.h>
#include <errno.h>
#ifdef __linux__
#include <linux/fs.h>
#endif
static void
seek_data(int fd, off_t offset, off_t expected)