tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: e839a756012b6cad7a4eeb67b0598ac3f349f863 commit: 4d9cb92ca41dd8e905a4569ceba4716c2f39c75a io_uring/rw: fix short rw error handling date: 4 days ago config: x86_64-randconfig-m001 compiler: gcc-11 (Debian 11.3.0-5) 11.3.0 If you fix the issue, kindly add following tag where applicable Reported-by: kernel test robot smatch warnings: io_uring/rw.c:215 io_fixup_rw_res() warn: unsigned 'res' is never less than zero. vim +/res +215 io_uring/rw.c 208 209 static inline unsigned io_fixup_rw_res(struct io_kiocb *req, unsigned res) 210 { 211 struct io_async_rw *io = req->async_data; 212 213 /* add previously done IO, if any */ 214 if (req_has_async_data(req) && io->bytes_done > 0) { > 215 if (res < 0) 216 res = io->bytes_done; 217 else 218 res += io->bytes_done; 219 } 220 return res; 221 } 222 -- 0-DAY CI Kernel Test Service https://01.org/lkp