Commit 55eb809f authored by Colin Ian King's avatar Colin Ian King Committed by Martin K. Petersen

scsi: libsas: Remove redundant assignment to variable res

The variable 'res' is being initialized with a value that is never read and
it is being updated later with a new value. The initialization is redundant
and can be removed.

Link: https://lore.kernel.org/r/20200722154404.959267-1-colin.king@canonical.comReviewed-by: default avatarJohn Garry <john.garry@huawei.com>
Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
Addresses-Coverity: ("Unused value")
parent 38653379
......@@ -427,7 +427,7 @@ int sas_ex_phy_discover(struct domain_device *dev, int single)
static int sas_expander_discover(struct domain_device *dev)
{
struct expander_device *ex = &dev->ex_dev;
int res = -ENOMEM;
int res;
ex->ex_phy = kcalloc(ex->num_phys, sizeof(*ex->ex_phy), GFP_KERNEL);
if (!ex->ex_phy)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment