From patchwork Fri Jun 18 15:55:06 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Suganath Prabu S X-Patchwork-Id: 464128 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.9 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI,MIME_NO_TEXT, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C5637C48BDF for ; Fri, 18 Jun 2021 15:55:23 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 9DBD7611CD for ; Fri, 18 Jun 2021 15:55:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233871AbhFRP5c (ORCPT ); Fri, 18 Jun 2021 11:57:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36608 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232395AbhFRP5b (ORCPT ); Fri, 18 Jun 2021 11:57:31 -0400 Received: from mail-pj1-x1030.google.com (mail-pj1-x1030.google.com [IPv6:2607:f8b0:4864:20::1030]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6EBB4C06175F for ; Fri, 18 Jun 2021 08:55:22 -0700 (PDT) Received: by mail-pj1-x1030.google.com with SMTP id k5so5949920pjj.1 for ; Fri, 18 Jun 2021 08:55:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:mime-version; bh=hYwMuGpl1XBfY2Fob5xZyvs1A2JqveibGGPcZ49UTEk=; b=bOFzc21jRH6+RVAwFJgniJBg+GZ5YOYwedWgw/qFoPCJ9AJ6EzD5E9lzm3jZOZQqbc kmlHOcMWV6t7xQTJdZ1XbN53nT1p/We0qcvEnm9qiJG8dkqNkVEmvlRuejqZg1a6MJry iYnLlCImCAf8TVAGb4WQSzkdzgpQwz8Kl5XKs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version; bh=hYwMuGpl1XBfY2Fob5xZyvs1A2JqveibGGPcZ49UTEk=; b=nku7x3jSwUal75elXb93LR4YuXxcARAvbY3L8RHYnIPOWOzBvWgobAs9yzcmbM2zXP Vsekm2Vnp4SO8c26sQwLSiFN1UUMNsoZBvDZgtFRsaKa1hfcmzqDhjwJA3aMhu8JdBzv u1TrcSlIj8DGddGyj0VZE2jRDGAyL/DlDkEyeiZXv5DHQluguTAw+J1HnDyp//SAUc9s DGPyd09re4pFzboTx1TeJVHrwheIAA6l4GzPJ0xbZpnExVY+hqhkI/17Qx0AgQvTg9S9 A1pjQSOiaK0LTIu40BvBtxEdP72GIKiUHQJ5SJWaNN3C8TFEZZb7dj5Eaop7zmlil0L5 9oZg== X-Gm-Message-State: AOAM530JNroSyAZ9bUKCpTGKJhGDaoiFuUU0dmrnhlTGo8bkUKF2a/W+ TjSNphSn/ZMp8QbFE4jp6m747m8yJheZb2/KdXOYtmn7cwOGtkfAIn0oUZivWubtpvBp4vGkFX2 LTxnPIokQdpqRJqdXmv5YzfhgFYgUacor1k+6PTLZYx7GaR9mU0VZNZbSMhMDUhTAN647w8+N1r MvSjK8o06faQGsunIkjVqffVW9wg== X-Google-Smtp-Source: ABdhPJx2VC0exTRuId0QiWYYgRzx934p6TLmgZn4B2nrIVuUuwIFJM6oXnFF8hMWro7SM/sZLx0fcg== X-Received: by 2002:a17:902:7288:b029:121:c0e1:f088 with SMTP id d8-20020a1709027288b0290121c0e1f088mr2582693pll.67.1624031721332; Fri, 18 Jun 2021 08:55:21 -0700 (PDT) Received: from dhcp-10-123-20-76.dhcp.broadcom.net ([192.19.234.250]) by smtp.gmail.com with ESMTPSA id w14sm4968384pjb.3.2021.06.18.08.55.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 18 Jun 2021 08:55:20 -0700 (PDT) From: Suganath Prabu S To: linux-scsi@vger.kernel.org, martin.petersen@oracle.com Cc: Sathya.Prakash@broadcom.com, sreekanth.reddy@broadcom.com, Suganath Prabu S , Colin Ian King Subject: [PATCH] mpt3sas: Fix Coverity reported issue. Date: Fri, 18 Jun 2021 21:25:06 +0530 Message-Id: <20210618155506.2609112-1-suganath-prabu.subramani@broadcom.com> X-Mailer: git-send-email 2.27.0 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org Fix the Structurally dead code (UNREACHABLE) type of error reported by coverity. Reported-by: Colin Ian King Signed-off-by: Suganath Prabu S --- drivers/scsi/mpt3sas/mpt3sas_base.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/mpt3sas/mpt3sas_base.c b/drivers/scsi/mpt3sas/mpt3sas_base.c index e592b1a..75e5c6c 100644 --- a/drivers/scsi/mpt3sas/mpt3sas_base.c +++ b/drivers/scsi/mpt3sas/mpt3sas_base.c @@ -7206,6 +7206,7 @@ mpt3sas_port_enable_done(struct MPT3SAS_ADAPTER *ioc, u16 smid, u8 msix_index, ioc->port_enable_failed = 1; if (ioc->port_enable_cmds.status & MPT3_CMD_COMPLETE_ASYNC) { + ioc->port_enable_cmds.status &= ~MPT3_CMD_COMPLETE_ASYNC; if (ioc_status == MPI2_IOCSTATUS_SUCCESS) { mpt3sas_port_enable_complete(ioc); return 1; @@ -7214,7 +7215,6 @@ mpt3sas_port_enable_done(struct MPT3SAS_ADAPTER *ioc, u16 smid, u8 msix_index, ioc->start_scan = 0; return 1; } - ioc->port_enable_cmds.status &= ~MPT3_CMD_COMPLETE_ASYNC; } complete(&ioc->port_enable_cmds.done); return 1;