]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
scsi: lpfc: remove redundant null check on eqe
authorColin Ian King <colin.king@canonical.com>
Fri, 8 Sep 2017 08:02:01 +0000 (09:02 +0100)
committerJack Vogel <jack.vogel@oracle.com>
Thu, 8 Mar 2018 04:26:40 +0000 (20:26 -0800)
Orabug: 27631736

The pointer eqe is always non-null inside the while loop, so the check
to see if eqe is NULL is redudant and hence can be removed.

Detected by CoverityScan CID#1248693 ("Logically Dead Code")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Acked-by: James Smart <james.smart@broadcom.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
(cherry picked from commit 858e51e8cbe11a8c59b24aaf4cb40f7f4e7a2feb)
Signed-off-by: Dick dkennedy <dick.kennedy@broadcom.com>
 Conflicts:
drivers/scsi/lpfc/lpfc_sli.c
Base nvme patch
Signed-off-by: Dan Duval <dan.duval@oracle.com>
Reviewed-by: Jack Vogel <jack.vogel@oracle.com>
drivers/scsi/lpfc/lpfc_sli.c

index 7ae81b333d813e674770efd7af74c01503a9f2a5..bbfbc8370553c93e40891dd0c3a50a5d5d9c701b 100644 (file)
@@ -12858,8 +12858,6 @@ lpfc_sli4_hba_intr_handler(int irq, void *dev_id)
         * Process all the event on FCP fast-path EQ
         */
        while ((eqe = lpfc_sli4_eq_get(fpeq))) {
-               if (eqe == NULL)
-                       break;
 
                lpfc_sli4_hba_handle_eqe(phba, eqe, fcp_eqidx);
                if (!(++ecount % fpeq->entry_repost))