t/io_uring: remove duplicate definition of gettid()
authorJens Axboe <axboe@kernel.dk>
Fri, 26 Aug 2022 20:14:44 +0000 (14:14 -0600)
committerJens Axboe <axboe@kernel.dk>
Fri, 26 Aug 2022 20:17:40 +0000 (14:17 -0600)
commita5a2429ece9b2a7e35e2b8a0248e7b1de6d075c3
tree38849d041528402bedc14fff550d10a93b726168
parenta2947c330d299e67bb532d622e2eccdcf27afc46
t/io_uring: remove duplicate definition of gettid()

With a recent change, we now include os.h through nvme.h, and this
can cause a duplicate gettid() definition:

t/io_uring.c:499:12: error: redefinition of ‘gettid’
 static int gettid(void)
            ^~~~~~
In file included from t/../engines/../os/os.h:39,
                 from t/../engines/../thread_options.h:5,
                 from t/../engines/../fio.h:18,
                 from t/../engines/nvme.h:10,
                 from t/io_uring.c:38:
t/../engines/../os/os-linux.h:147:19: note: previous definition of
‘gettid’ was here
 static inline int gettid(void)
                   ^~~~~~

Include os.h directly to make it clear that we use it, and remove the
gettid() definition from io_uring.c.

Reported-by: Yi Zhang <yi.zhang@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
t/io_uring.c