scsi: megaraid_mbox: Remove redundant initialization of pointer mbox
authorColin Ian King <colin.king@canonical.com>
Tue, 20 Apr 2021 10:49:19 +0000 (11:49 +0100)
committerMartin K. Petersen <martin.petersen@oracle.com>
Mon, 10 May 2021 17:24:07 +0000 (13:24 -0400)
The pointer mbox 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/20210420104919.376734-1-colin.king@canonical.com
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Addresses-Coverity: ("Unused value")

drivers/scsi/megaraid/megaraid_mbox.c

index 145fde3..d0aa384 100644 (file)
@@ -3240,8 +3240,6 @@ megaraid_mbox_fire_sync_cmd(adapter_t *adapter)
        int i;
        uint32_t dword;
 
-       mbox = (mbox_t *)raw_mbox;
-
        memset((caddr_t)raw_mbox, 0, sizeof(mbox_t));
 
        raw_mbox[0] = 0xFF;