Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp1595489pxb; Fri, 10 Sep 2021 09:16:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJztFumLwMwXmicFlfGtMvEdtz2xFbv9INSxmhIo+EmiDD0f7DxnS92F5bOWaHN6MDTvBy+g X-Received: by 2002:a17:906:584:: with SMTP id 4mr10380851ejn.56.1631290607472; Fri, 10 Sep 2021 09:16:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631290607; cv=none; d=google.com; s=arc-20160816; b=keiK+scOjiGXw66Pdd3eWJ2A1yz+RXMTYZs0e1YgqimXmsnyJIDwPPt8/SQ8XRr+Fo yh6i2L7jwnEsVA+X4IaoHycA9iPeXp2t8o340AjVAZ+CTOihKQQW6toy/POeUY9idYcZ onH6aQ9tSPrgO31/ordNwNrVxROFOz5YTlSCXinV9diAE3E1sBNqXrDfR10+69dxa4fZ XR9puiaxpDL/a32I72iFjWHWDeGAHOZ62WaUlA1KoXDmGq2MpjCWXCGSXiqSWBfMy0HO WPc+KkMY3dmUAJQcRjmpa3XOTgeMFc2/KoXvTp50b9qu6PJ/gY7i+zPnWDVDI3h0oEcD ABkQ== 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:dkim-signature; bh=+Q2vTAAq7QHzyF1atFoswScUho+hy4URUfVAKgzhNG0=; b=X4ns+ywxFJwvSV/DyBe6JDHtBFt8UDMgWDPuNOT2ew5ZYeQn4uPwywZwNziC4F7N9H o+BwIECVsHRVGRih/WhbAqU9bJJjvmMKafEp5Nq70/W97X5SIK0gCT8FJ64WOdrBMA5l 2j2DjO5I6FPTeeRCVEzfsZLkehvPYqeYwjZHCWDyIFMP+YUrdnyZvO5dpcQKsmZBZ0pz diGQNyGynD+uEBWzECh0UZHumhtvOU5tCwBhfDV0SSXAAV30UaqICH4cV8LuRB74SMm6 vSF6W9cG4qwFBbEseOSRSdjCohvcaAgA4HPp5Q25AW5o+5b1R7ZpI7qxRF5t1eGk2UxV frQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@canonical.com header.s=20210705 header.b=KQR9Q4qF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=canonical.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v4si5750371ejv.670.2021.09.10.09.16.21; Fri, 10 Sep 2021 09:16:47 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@canonical.com header.s=20210705 header.b=KQR9Q4qF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=canonical.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232527AbhIJQP6 (ORCPT + 99 others); Fri, 10 Sep 2021 12:15:58 -0400 Received: from smtp-relay-canonical-0.canonical.com ([185.125.188.120]:47068 "EHLO smtp-relay-canonical-0.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231331AbhIJQPb (ORCPT ); Fri, 10 Sep 2021 12:15:31 -0400 Received: from localhost (1.general.cking.uk.vpn [10.172.193.212]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-canonical-0.canonical.com (Postfix) with ESMTPSA id 967A43F236; Fri, 10 Sep 2021 16:14:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1631290458; bh=+Q2vTAAq7QHzyF1atFoswScUho+hy4URUfVAKgzhNG0=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version:Content-Type; b=KQR9Q4qFS2yP4to8uPWyNIpCloyS5WrQq81a/D1CEl+vzqL77bGSIF4Xecl520BHu Exo30Opr387nVOkgBggz7MChTc8DOpdyGtSJ8qzpOSshY56H7/2+bS+O/3Xl6kiqWZ QBFPRWMQahGsAXLbjazl/SpREv71zDmVgD3e25q3SHRgCY6u8MxdpQAmI4UN49H/Df utE8p5Gx8PwYkLdoHCFf+KRN/e6EU0oGrwVSdu1xPsJStTCgl/2nN5RvH/oNntAaRa 9TZHqV2yQGVW0BtvUhfcKseAdnvc4iYWBzFWoN/RY37f2+XwTx2qddgDvf1VVCjYWC 8WeslW+HN1QAA== From: Colin King To: Bjorn Helgaas , linux-pci@vger.kernel.org Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] PCI: Remove redundant initialization of variable rc Date: Fri, 10 Sep 2021 17:14:17 +0100 Message-Id: <20210910161417.91001-1-colin.king@canonical.com> X-Mailer: git-send-email 2.32.0 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Colin Ian King The variable rc is being initialized with a value that is never read, it is being updated later on. The assignment is redundant and can be removed. Addresses-Coverity: ("Unused value") Signed-off-by: Colin Ian King --- drivers/pci/pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index ce2ab62b64cf..cd8cb94cc450 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c @@ -5288,7 +5288,7 @@ const struct attribute_group pci_dev_reset_method_attr_group = { */ int __pci_reset_function_locked(struct pci_dev *dev) { - int i, m, rc = -ENOTTY; + int i, m, rc; might_sleep(); -- 2.32.0