Re: [LTP] [PATCH v3 1/4] lib: Add tst_fd iterator

Cyril Hrubis
2024-01-16T15:19:13Z

Hi!
> In file included from ../include/lapi/io_uring.h:17:0,
> from tst_fd.c:21:
> /usr/include/sys/mount.h:35:3: error: expected identifier before numeric constant
> MS_RDONLY = 1, /* Mount read-only. */
> ^

Looks like the best solution for now is:

diff --git a/include/lapi/io_uring.h b/include/lapi/io_uring.h
index a63741a08..03c45190e 100644
--- a/include/lapi/io_uring.h
+++ b/include/lapi/io_uring.h
@@ -14,7 +14,6 @@
#include <sys/types.h>
#include <sys/uio.h>
#include <stdlib.h>
-#include <linux/fs.h>

#include "lapi/syscalls.h"

As far as I can tell the only reason this header is included is the
__kernel_rwf_t definition which has a fallback definition just a few
lines below.

--
Cyril Hrubis
chrubis@suse.cz