qlcnic: remove redundant assignment to variable err
authorColin Ian King <colin.king@canonical.com>
Wed, 3 Jul 2019 08:32:14 +0000 (09:32 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 3 Jul 2019 18:33:55 +0000 (11:33 -0700)
The variable err 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.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qlcnic/qlcnic_sriov_pf.c

index af3b037fa44286580b574f7978af3ad3d2decdc5..5632da05145a5500776f58801e681d7aab6c94c3 100644 (file)
@@ -1066,7 +1066,7 @@ static int qlcnic_sriov_pf_cfg_ip_cmd(struct qlcnic_bc_trans *trans,
 {
        struct qlcnic_vf_info *vf = trans->vf;
        struct qlcnic_adapter *adapter = vf->adapter;
-       int err = -EIO;
+       int err;
 
        cmd->req.arg[1] |= vf->vp->handle << 16;
        cmd->req.arg[1] |= BIT_31;