diff options
| author | Jens Axboe <axboe@r7625.kernel.dk> | 2024-06-13 22:28:27 +0300 |
|---|---|---|
| committer | Jens Axboe <axboe@kernel.dk> | 2024-06-16 23:54:55 +0300 |
| commit | 3474d1b93f897ab33ce160e759afd47d5f412de4 (patch) | |
| tree | b9a3cfb1fc551cb18c6082431c99ca0256744685 /include/linux | |
| parent | f2a93294edce87c909d61e18b506404127394891 (diff) | |
| download | linux-3474d1b93f897ab33ce160e759afd47d5f412de4.tar.xz | |
io_uring/io-wq: make io_wq_work flags atomic
The work flags can be set/accessed from different tasks, both the
originator of the request, and the io-wq workers. While modifications
aren't concurrent, it still makes KMSAN unhappy. There's no real
downside to just making the flag reading/manipulation use proper
atomics here.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/io_uring_types.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/io_uring_types.h b/include/linux/io_uring_types.h index 850e30be9322..1052a68fd68d 100644 --- a/include/linux/io_uring_types.h +++ b/include/linux/io_uring_types.h @@ -50,7 +50,7 @@ struct io_wq_work_list { struct io_wq_work { struct io_wq_work_node list; - unsigned flags; + atomic_t flags; /* place it here instead of io_kiocb as it fills padding and saves 4B */ int cancel_seq; }; |
