lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20230110164044.755234-1-harshit.m.mogalapalli@oracle.com>
Date:   Tue, 10 Jan 2023 08:40:43 -0800
From:   Harshit Mogalapalli <harshit.m.mogalapalli@...cle.com>
To:     unlisted-recipients:; (no To-header on input)
Cc:     stable@...r.kernel.org, harshit.m.mogalapalli@...cle.com,
        error27@...il.com, darren.kenny@...cle.com,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Jens Axboe <axboe@...nel.dk>,
        Pavel Begunkov <asml.silence@...il.com>,
        Sasha Levin <sashal@...nel.org>, linux-kernel@...r.kernel.org
Subject: [PATCH 5.10.y] io_uring: Fix unsigned 'res' comparison with zero in io_fixup_rw_res()

Smatch warning: io_fixup_rw_res() warn:
	unsigned 'res' is never less than zero.

Change type of 'res' from unsigned to long.

Fixes: 788d0824269b ("io_uring: import 5.15-stable io_uring")
Signed-off-by: Harshit Mogalapalli <harshit.m.mogalapalli@...cle.com>
---
Note: The Fixes commit is a 5.15 to 5.10 backport, the commit which
this patch actually Fixes in 5.15 is d6b7efc722a2
---
 io_uring/io_uring.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/io_uring/io_uring.c b/io_uring/io_uring.c
index 945faf036ad0..0c4d16afb9ef 100644
--- a/io_uring/io_uring.c
+++ b/io_uring/io_uring.c
@@ -2702,7 +2702,7 @@ static bool __io_complete_rw_common(struct io_kiocb *req, long res)
 	return false;
 }
 
-static inline int io_fixup_rw_res(struct io_kiocb *req, unsigned res)
+static inline int io_fixup_rw_res(struct io_kiocb *req, long res)
 {
 	struct io_async_rw *io = req->async_data;
 
-- 
2.38.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ