Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2828113imu; Sun, 23 Dec 2018 08:41:45 -0800 (PST) X-Google-Smtp-Source: ALg8bN7eVDPHyxbe2C/ffLuXqufSCuDXhkd1TdOXta0e1n3s4xKX54CMy2qsfiXsSr/kK+dNClkv X-Received: by 2002:a17:902:7005:: with SMTP id y5mr10212490plk.7.1545583305378; Sun, 23 Dec 2018 08:41:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1545583305; cv=none; d=google.com; s=arc-20160816; b=cutZRgAlXxELVrXHYBIrc/1eFZ8h1iT7fShfJ9Qabm8bNBXz+j8brbB59pfkTW0t9T +H3rl5vydwE4eFUkkTTtKavEoY21l9tL0ibpwaaJQW30RT22e4iJ34uI9eIvEJqjaMch 6tS1S2XNpzYSlPAmoh0nRV0h5MESr08k0zPebGFkozUIYcN/lAEpKTbWEyHxKhOyDs2u Mfefz6OdaIOvUxa5vkxpPgwDZiv6YKFgpKhjyL2q2szuvj+lMjbRX6y5xqTQxW+n9IXR 6xxa+kjiM4mAwn3PBeCq44VYoSnm8CtTJ6hn7iX1lo03sFGFZZn/9IpLP57FkEhEBao+ lLoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=l+LrGrkY3lU581dOQ/BQSfkbWckfykxvOCPaERmdSEk=; b=R2LhaoiEB8t0lyYOpwbrD+ssG8B6NO+2OSwqqRlFy5zrDica7CDZAZV2jatfC26XG1 Yaw4Cww/TgLr13RtMqf2HsvLlshhHo8EA8LSBQsrgzx7+RBCXbEl5xduSZok+1HLMJG2 1OtxqUb4aypAlmq2AsMWleZwcN0PhAZ/+HAKzq/BajgTbFCvMFXEv9wUrsy+qVdAYwO+ rvIJrnYiDWdL+SV19nJBniCtbUKGljUJhXKsumJIXggB0/Kc0nM2vAxJuwvkObXd7jRu vttZVG6PlUlEw3QYBUHCW7qYr8QOcgY9kXWFTjwVJEXRn65s867JA1LyE9yJZ49QXNW9 +ZLg== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d8si27136658pln.128.2018.12.23.08.41.30; Sun, 23 Dec 2018 08:41:45 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727729AbeLWJgB (ORCPT + 99 others); Sun, 23 Dec 2018 04:36:01 -0500 Received: from mail3-relais-sop.national.inria.fr ([192.134.164.104]:44319 "EHLO mail3-relais-sop.national.inria.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727198AbeLWJd5 (ORCPT ); Sun, 23 Dec 2018 04:33:57 -0500 X-IronPort-AV: E=Sophos;i="5.56,386,1539640800"; d="scan'208";a="289991765" Received: from palace.lip6.fr ([132.227.105.202]) by mail3-relais-sop.national.inria.fr with ESMTP/TLS/AES128-SHA256; 23 Dec 2018 10:33:52 +0100 From: Julia Lawall To: James Smart Cc: kernel-janitors@vger.kernel.org, Dick Kennedy , "James E.J. Bottomley" , "Martin K. Petersen" , linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 03/20] scsi: lpfc: lpfc_nvme: drop useless LIST_HEAD Date: Sun, 23 Dec 2018 09:56:58 +0100 Message-Id: <1545555435-24576-4-git-send-email-Julia.Lawall@lip6.fr> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1545555435-24576-1-git-send-email-Julia.Lawall@lip6.fr> References: <1545555435-24576-1-git-send-email-Julia.Lawall@lip6.fr> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Drop LIST_HEAD where the variable it declares is never used. These were introduced with the file, but were not even used at that time. The semantic patch that fixes this problem is as follows: (http://coccinelle.lip6.fr/) // @@ identifier x; @@ - LIST_HEAD(x); ... when != x // Fixes: 01649561a8b4b ("scsi: lpfc: NVME Initiator: bind to nvme_fc api") Signed-off-by: Julia Lawall --- Successfully 0-day tested on 151 configurations. drivers/scsi/lpfc/lpfc_nvme.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/scsi/lpfc/lpfc_nvme.c b/drivers/scsi/lpfc/lpfc_nvme.c index 4c66b19e6199..2119f36213e4 100644 --- a/drivers/scsi/lpfc/lpfc_nvme.c +++ b/drivers/scsi/lpfc/lpfc_nvme.c @@ -2234,9 +2234,7 @@ lpfc_new_nvme_buf(struct lpfc_vport *vport, int num_to_alloc) dma_addr_t pdma_phys_sgl; uint16_t iotag, lxri = 0; int bcnt, num_posted; - LIST_HEAD(prep_nblist); LIST_HEAD(post_nblist); - LIST_HEAD(nvme_nblist); for (bcnt = 0; bcnt < num_to_alloc; bcnt++) { lpfc_ncmd = kzalloc(sizeof(struct lpfc_nvme_buf), GFP_KERNEL);