Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp454739ybc; Fri, 22 Nov 2019 07:50:00 -0800 (PST) X-Google-Smtp-Source: APXvYqzovGrNK4Tw0beD8z5QWtLhPQZMTqZdXsvNCQYvmK5IHPrLaZvy80lTXA/14wMJPhdozWtD X-Received: by 2002:a50:de06:: with SMTP id z6mr1896676edk.279.1574437800452; Fri, 22 Nov 2019 07:50:00 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574437800; cv=none; d=google.com; s=arc-20160816; b=Yf71PkAADkhHqzHUkvFUeIPPIoqfHihKK09pvC7FxSSfBzja/7JHEGVm5qRYbxGLsg 9sQeLsf4OxDipr4xrdZf0n9FDgf6z0HE3OQR8nvuMjfcjBR4mEfBAZLdM6ekElezjvs9 5bVvQkU9W++ktL0kJrGq4qV0zNIwINKj9HnsYPJlgSYC0tEbKz4RQMHhalXuWmzP/l2l OttJ5xvvjM3RL7ioFO+mwdw0JJ5N2C8oRx+LNSCA3vJ60fDbnMz8Kw2zXG5+vSHjr+co Vs4/iiRGfnn0VIIEs8TPFvH+uualQlifvN23cPycHaUtIbgBpveS1Wqy88XjtFMkS6tc 6ljQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=pgTi5QBKzrwN1pM7jLakcYjnVBUi63H7U1xM6nR5A7Y=; b=RpUddDJG7gQZagz3opOFjSW3RXz/nfNW89aKEhCfgNiAsWa+yEqHme+7tzmJraTax/ gmDr+gC3+ZbVIA3MWGuWQoSevCzQpeSrRdyGQW+rxoPVvWjFoVxHWiZ09LZswCA2Y1q7 kyqaekQQQBcni7l7gMeWhcCk0yqATj1AcO+mKTnPqUrom6CD/DGPn5Qb2zV9j+Q43Ws3 Va3Ut5m6psfUvsetixP2MpoJ0ghyrat3QOaXm2vP5/UhDnH1SgQC6FOMGpcp6g81JJnz RX0R3qsuE6nSPqVsDmvfZW05AVvuiKXShDPsLeEeZvp9HxIaAat+1vCHE5EkfIl6cp2G UohQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=canonical.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u93si1494707edc.184.2019.11.22.07.49.36; Fri, 22 Nov 2019 07:50:00 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=canonical.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726962AbfKVPsU (ORCPT + 99 others); Fri, 22 Nov 2019 10:48:20 -0500 Received: from youngberry.canonical.com ([91.189.89.112]:33873 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726613AbfKVPsU (ORCPT ); Fri, 22 Nov 2019 10:48:20 -0500 Received: from 1.general.cking.uk.vpn ([10.172.193.212] helo=localhost) by youngberry.canonical.com with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1iYBAN-0001CC-6r; Fri, 22 Nov 2019 15:48:15 +0000 From: Colin King To: Mike Marciniszyn , Dennis Dalessandro , Doug Ledford , Jason Gunthorpe , linux-rdma@vger.kernel.org Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] IB/hfi1: remove redundant assignment to variable ret Date: Fri, 22 Nov 2019 15:48:14 +0000 Message-Id: <20191122154814.87257-1-colin.king@canonical.com> X-Mailer: git-send-email 2.24.0 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Colin Ian King The variable ret 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. Addresses-Coverity: ("Unused value") Signed-off-by: Colin Ian King --- drivers/infiniband/hw/hfi1/platform.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/infiniband/hw/hfi1/platform.c b/drivers/infiniband/hw/hfi1/platform.c index cbf7faa5038c..36593f2efe26 100644 --- a/drivers/infiniband/hw/hfi1/platform.c +++ b/drivers/infiniband/hw/hfi1/platform.c @@ -634,7 +634,7 @@ static void apply_tx_lanes(struct hfi1_pportdata *ppd, u8 field_id, u32 config_data, const char *message) { u8 i; - int ret = HCMD_SUCCESS; + int ret; for (i = 0; i < 4; i++) { ret = load_8051_config(ppd->dd, field_id, i, config_data); -- 2.24.0