Received: by 2002:a05:7412:f690:b0:e2:908c:2ebd with SMTP id ej16csp199725rdb; Thu, 19 Oct 2023 01:31:13 -0700 (PDT) X-Google-Smtp-Source: AGHT+IE4Q1lmGdRzvT7TIotPvoDNZqIPU+io0UOLSbxdgmO2ydz9N/xl/pFHDA31cq2xx6j3clQS X-Received: by 2002:a17:90b:2dd1:b0:27d:d9d:c54d with SMTP id sk17-20020a17090b2dd100b0027d0d9dc54dmr1455914pjb.34.1697704272858; Thu, 19 Oct 2023 01:31:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697704272; cv=none; d=google.com; s=arc-20160816; b=uXv6d5RBo6+X7E4Y2tW7OvcZrKNGIpaWbv6q022aN2vbP7m+b0nqWbDZoUut2EyVq7 S6D3qUvXJyTiVdHeKFx0fCZsrrYqzrTzDnEY1+i5NgHPhYOGIXpqn+QgwxQNjzLRKRtZ 16MVuteXuC2QUBGzcLMl2IjkX2ixJvVxgrzXgajP3t7GbN9HmpaM2PDrLcWUQOi0h3qt QJCLeH2KkceVoXJk12UPTDZ15MGND6R/e5teXhP/NgmJDquLNrPiUrHQEflzxeSciTVc +ErLS6RL9+KHLKJ0nkHs/1PtHkbzqhO9nF7DeQNXsXcdKptvCp2TouHc/WvNAgXAMgzD iUpg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=TD8W71TlIBlx3C8GrZqvTqyg30DCGB4el4RyOKcoImo=; fh=0oGkIorvZdNPSGCzgOvDexnfugsrsVpiJn/WCWA0zjc=; b=0oYz8Zr11ySDjQua74MiA1Bux903eZwNrmFBZjDZCggYHkIxDZb5hNOlMI0IDsHRT9 YCESMI8TsbnlDXJpYlN4I5vYztPlOUROYhAVgtMcn3NlehiipVjYtbS+PdFOqnnihA7T w1hORPbVyXrIiQA51fJUrWeZYuzZ46M/R4fzTYytm8jCC9Vul+bHHlGNdoMS4HRrEipD QWc7N2Vdb1/0gcLO68SsUz4INwihQP7LqtB0Mic61BJRmZFayvBEuLLY291EPn4z5GvL m6ZN1jMr+EUVnYC8J1ySXi//jcx0spvK7pYpVZITOrsRZRitvwUv8AhKaMQuhmZHdp20 PjHg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from pete.vger.email (pete.vger.email. [2620:137:e000::3:6]) by mx.google.com with ESMTPS id mu16-20020a17090b389000b0026d0a89ad68si1862020pjb.43.2023.10.19.01.31.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Oct 2023 01:31:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) client-ip=2620:137:e000::3:6; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id 39660818FBC8; Thu, 19 Oct 2023 01:31:10 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232383AbjJSIa5 (ORCPT + 99 others); Thu, 19 Oct 2023 04:30:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54990 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232813AbjJSIaz (ORCPT ); Thu, 19 Oct 2023 04:30:55 -0400 Received: from mail.nfschina.com (unknown [42.101.60.195]) by lindbergh.monkeyblade.net (Postfix) with SMTP id BC39911F; Thu, 19 Oct 2023 01:30:49 -0700 (PDT) Received: from localhost.localdomain (unknown [180.167.10.98]) by mail.nfschina.com (Maildata Gateway V2.8.8) with ESMTPA id CA64C6071E208; Thu, 19 Oct 2023 16:30:32 +0800 (CST) X-MD-Sfrom: suhui@nfschina.com X-MD-SrcIP: 180.167.10.98 From: Su Hui To: kartilak@cisco.com, sebaddel@cisco.com, jejb@linux.ibm.com, martin.petersen@oracle.com Cc: Su Hui , linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [PATCH] scsi: snici: Remove dead code in snic_dr_clean_pending_req Date: Thu, 19 Oct 2023 16:30:27 +0800 Message-Id: <20231019083026.1525366-1-suhui@nfschina.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Thu, 19 Oct 2023 01:31:10 -0700 (PDT) Value stored to 'ret' is never read, remove it to save space. Signed-off-by: Su Hui --- drivers/scsi/snic/snic_scsi.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/scsi/snic/snic_scsi.c b/drivers/scsi/snic/snic_scsi.c index c50ede326cc4..badd0d5640bc 100644 --- a/drivers/scsi/snic/snic_scsi.c +++ b/drivers/scsi/snic/snic_scsi.c @@ -1867,11 +1867,8 @@ snic_dr_clean_pending_req(struct snic *snic, struct scsi_cmnd *lr_sc) schedule_timeout(msecs_to_jiffies(100)); /* Walk through all the cmds and check abts status. */ - if (snic_is_abts_pending(snic, lr_sc)) { - ret = FAILED; - + if (snic_is_abts_pending(snic, lr_sc)) goto clean_err; - } ret = 0; SNIC_SCSI_DBG(snic->shost, "clean_pending_req: Success.\n"); -- 2.30.2