]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: fix 1-bit bitfields to be unsigned
authorRandy Dunlap <rdunlap@infradead.org>
Thu, 6 Feb 2020 04:57:10 +0000 (20:57 -0800)
committerJens Axboe <axboe@kernel.dk>
Thu, 6 Feb 2020 20:41:00 +0000 (13:41 -0700)
commit73574153ae504df32976014a34eb543139c08826
tree05b032d0fdabdea41f6f93889d6668908bf4e946
parent1caf8bd170fdc9d277a8e26dc5ab317b9d1a6e4b
io_uring: fix 1-bit bitfields to be unsigned

Make bitfields of size 1 bit be unsigned (since there is no room
for the sign bit).
This clears up the sparse warnings:

  CHECK   ../fs/io_uring.c
../fs/io_uring.c:207:50: error: dubious one-bit signed bitfield
../fs/io_uring.c:208:55: error: dubious one-bit signed bitfield
../fs/io_uring.c:209:63: error: dubious one-bit signed bitfield
../fs/io_uring.c:210:54: error: dubious one-bit signed bitfield
../fs/io_uring.c:211:57: error: dubious one-bit signed bitfield

Found by sight and then verified with sparse.

Fixes: 9e28b5b51046 ("io_uring: change io_ring_ctx bool fields into bit fields")
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: io-uring@vger.kernel.org
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c