From patchwork Thu May 30 19:04:38 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin King X-Patchwork-Id: 10969181 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 79B3F15E6 for ; Thu, 30 May 2019 19:07:05 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 66A5428683 for ; Thu, 30 May 2019 19:07:05 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 53A93288E8; Thu, 30 May 2019 19:07:05 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id E733628683 for ; Thu, 30 May 2019 19:07:04 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1hWQM1-0001uS-NU; Thu, 30 May 2019 19:04:45 +0000 Received: from us1-rack-dfw2.inumbo.com ([104.130.134.6]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1hWQM0-0001uN-Sp for xen-devel@lists.xenproject.org; Thu, 30 May 2019 19:04:44 +0000 X-Inumbo-ID: c852a1fc-830d-11e9-8980-bc764e045a96 Received: from youngberry.canonical.com (unknown [91.189.89.112]) by us1-rack-dfw2.inumbo.com (Halon) with ESMTP id c852a1fc-830d-11e9-8980-bc764e045a96; Thu, 30 May 2019 19:04:43 +0000 (UTC) Received: from 1.general.cking.uk.vpn ([10.172.193.212] helo=localhost) by youngberry.canonical.com with esmtpsa (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.76) (envelope-from ) id 1hWQLu-0004Od-Lv; Thu, 30 May 2019 19:04:38 +0000 From: Colin King To: Wei Liu , Paul Durrant , "David S . Miller" , xen-devel@lists.xenproject.org, netdev@vger.kernel.org Date: Thu, 30 May 2019 20:04:38 +0100 Message-Id: <20190530190438.9571-1-colin.king@canonical.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Subject: [Xen-devel] [PATCH] xen-netback: remove redundant assignment to err X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Colin Ian King The variable err is assigned with the value -ENOMEM that is never read and it is re-assigned a new value later on. The assignment is redundant and can be removed. Addresses-Coverity: ("Unused value") Signed-off-by: Colin Ian King Acked-by: Wei Liu --- drivers/net/xen-netback/interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/xen-netback/interface.c b/drivers/net/xen-netback/interface.c index 783198844dd7..240f762b3749 100644 --- a/drivers/net/xen-netback/interface.c +++ b/drivers/net/xen-netback/interface.c @@ -633,7 +633,7 @@ int xenvif_connect_data(struct xenvif_queue *queue, unsigned int rx_evtchn) { struct task_struct *task; - int err = -ENOMEM; + int err; BUG_ON(queue->tx_irq); BUG_ON(queue->task);