]> git.baikalelectronics.ru Git - kernel.git/commit
scsi: storvsc: Fix unsigned comparison to zero
authorYueHaibing <yuehaibing@huawei.com>
Mon, 27 Dec 2021 04:03:11 +0000 (12:03 +0800)
committerWei Liu <wei.liu@kernel.org>
Wed, 5 Jan 2022 12:26:27 +0000 (12:26 +0000)
commit159c122ff0ef5715d13f05cf958dcd7457d21fa6
tree5b2fe695a510f05384f8133a4ab04399ba9838c6
parent25ac848c49f49701165c8ee5a83f3075475379f4
scsi: storvsc: Fix unsigned comparison to zero

The unsigned variable sg_count is being assigned a return value
from the call to scsi_dma_map() that can return -ENOMEM.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Reviewed-by: Michael Kelley <mikelley@microsoft.com>
Link: https://lore.kernel.org/r/20211227040311.54584-1-yuehaibing@huawei.com
Signed-off-by: Wei Liu <wei.liu@kernel.org>
drivers/scsi/storvsc_drv.c