Commit fa74af6b authored by Colin Ian King's avatar Colin Ian King Committed by Greg Kroah-Hartman

staging: unisys: visorhba: remove redundant initialization of variables scsicmd_id and rc

The variables scsicmd_id and rc is being initialized with a value
that is never read and are being updated later with a new value.
The initializations are redundant and can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20200723155415.994036-1-colin.king@canonical.comSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 20a2d16d
...@@ -305,7 +305,7 @@ static int forward_taskmgmt_command(enum task_mgmt_types tasktype, ...@@ -305,7 +305,7 @@ static int forward_taskmgmt_command(enum task_mgmt_types tasktype,
(struct visorhba_devdata *)scsidev->host->hostdata; (struct visorhba_devdata *)scsidev->host->hostdata;
int notifyresult = 0xffff; int notifyresult = 0xffff;
wait_queue_head_t notifyevent; wait_queue_head_t notifyevent;
int scsicmd_id = 0; int scsicmd_id;
if (devdata->serverdown || devdata->serverchangingstate) if (devdata->serverdown || devdata->serverchangingstate)
return FAILED; return FAILED;
...@@ -1186,7 +1186,7 @@ static struct visor_driver visorhba_driver = { ...@@ -1186,7 +1186,7 @@ static struct visor_driver visorhba_driver = {
*/ */
static int visorhba_init(void) static int visorhba_init(void)
{ {
int rc = -ENOMEM; int rc;
visorhba_debugfs_dir = debugfs_create_dir("visorhba", NULL); visorhba_debugfs_dir = debugfs_create_dir("visorhba", NULL);
if (!visorhba_debugfs_dir) if (!visorhba_debugfs_dir)
......
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