Messages in this thread | | | From | Chaitanya Kulkarni <> | Subject | Re: [PATCH] nvmet-auth: Fix unsigned comparison with less than zero | Date | Tue, 19 Jul 2022 07:09:43 +0000 |
| |
On 7/19/22 00:00, Jiapeng Chong wrote: > The return from the call to nvmet_auth_challenge() and nvmet_setup_auth() > is int, it can be a negative error code, however this is being assigned > to an u16 variable 'status', so making 'status' an int, and change the > position to keep the code format. > > This was found by coccicheck: > > ./drivers/nvme/target/fabrics-cmd-auth.c:488:6-12: WARNING: Unsigned expression compared with zero: status < 0. > ./drivers/nvme/target/fabrics-cmd-auth.c:251:8-14: WARNING: Unsigned expression compared with zero: status < 0. > > Reported-by: Abaci Robot <abaci@linux.alibaba.com> > Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com> > ---
I've already sent out the fix and it is been reviewed-by author of the code.
-ck
| |