diff mbox series

[1/1] lib: Fix compilation on old toolchains

Message ID 20240126105455.487510-1-pvorel@suse.cz
State Superseded
Headers show
Series [1/1] lib: Fix compilation on old toolchains | expand

Commit Message

Petr Vorel Jan. 26, 2024, 10:54 a.m. UTC
Some old toolchains require to add <linux/types.h> to fix:

tst_safe_io_uring.c: In function ‘safe_io_uring_init’:
tst_safe_io_uring.c:34:45: error: ‘__u32’ undeclared (first use in this function)
   34 |                 params->sq_entries * sizeof(__u32);
      |                                             ^~~~~

Fixes: 3f2ff5431 ("Add safe functions for io_uring to LTP library")
Signed-off-by: Petr Vorel <pvorel@suse.cz>
---
 lib/tst_safe_io_uring.c | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/lib/tst_safe_io_uring.c b/lib/tst_safe_io_uring.c
index de6869f50..982a10bd4 100644
--- a/lib/tst_safe_io_uring.c
+++ b/lib/tst_safe_io_uring.c
@@ -4,6 +4,8 @@ 
  */
 
 #define TST_NO_DEFAULT_MAIN
+
+#include <linux/types.h>
 #include "tst_test.h"
 #include "tst_safe_io_uring.h"