From patchwork Thu Feb 27 21:16:39 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Simmons X-Patchwork-Id: 11410787 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 89EB31580 for ; Thu, 27 Feb 2020 21:46:50 +0000 (UTC) Received: from pdx1-mailman02.dreamhost.com (pdx1-mailman02.dreamhost.com [64.90.62.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 72E34246A1 for ; Thu, 27 Feb 2020 21:46:50 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 72E34246A1 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lustre-devel-bounces@lists.lustre.org Received: from pdx1-mailman02.dreamhost.com (localhost [IPv6:::1]) by pdx1-mailman02.dreamhost.com (Postfix) with ESMTP id 3C65334B307; Thu, 27 Feb 2020 13:37:05 -0800 (PST) X-Original-To: lustre-devel@lists.lustre.org Delivered-To: lustre-devel-lustre.org@pdx1-mailman02.dreamhost.com Received: from smtp3.ccs.ornl.gov (smtp3.ccs.ornl.gov [160.91.203.39]) by pdx1-mailman02.dreamhost.com (Postfix) with ESMTP id D35973488E5 for ; Thu, 27 Feb 2020 13:21:03 -0800 (PST) Received: from star.ccs.ornl.gov (star.ccs.ornl.gov [160.91.202.134]) by smtp3.ccs.ornl.gov (Postfix) with ESMTP id 7DF4891AD; Thu, 27 Feb 2020 16:18:19 -0500 (EST) Received: by star.ccs.ornl.gov (Postfix, from userid 2004) id 7CFCA468; Thu, 27 Feb 2020 16:18:19 -0500 (EST) From: James Simmons To: Andreas Dilger , Oleg Drokin , NeilBrown Date: Thu, 27 Feb 2020 16:16:39 -0500 Message-Id: <1582838290-17243-532-git-send-email-jsimmons@infradead.org> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1582838290-17243-1-git-send-email-jsimmons@infradead.org> References: <1582838290-17243-1-git-send-email-jsimmons@infradead.org> Subject: [lustre-devel] [PATCH 531/622] lustre: modules: Use LIST_HEAD for declaring list_heads X-BeenThere: lustre-devel@lists.lustre.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "For discussing Lustre software development." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Lustre Development List MIME-Version: 1.0 Errors-To: lustre-devel-bounces@lists.lustre.org Sender: "lustre-devel" From: Mr NeilBrown Rather than struct list_head foo = LIST_HEAD_INIT(foo); use LIST_HEAD(foo); This is shorter and more in-keeping with upstream style. WC-bug-id: https://jira.whamcloud.com/browse/LU-9679 Lustre-commit: 546993d587c5 ("LU-9679 modules: Use LIST_HEAD for declaring list_heads") Signed-off-by: Mr NeilBrown Reviewed-on: https://review.whamcloud.com/36669 Reviewed-by: James Simmons Reviewed-by: Ben Evans Reviewed-by: Shaun Tancheff Reviewed-by: Oleg Drokin Signed-off-by: James Simmons --- fs/lustre/mdc/mdc_locks.c | 2 +- fs/lustre/mdc/mdc_reint.c | 2 +- fs/lustre/osc/osc_request.c | 2 +- fs/lustre/ptlrpc/pinger.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/fs/lustre/mdc/mdc_locks.c b/fs/lustre/mdc/mdc_locks.c index b91c162..4d40087 100644 --- a/fs/lustre/mdc/mdc_locks.c +++ b/fs/lustre/mdc/mdc_locks.c @@ -581,7 +581,7 @@ static struct ptlrpc_request *mdc_intent_layout_pack(struct obd_export *exp, struct md_op_data *op_data) { struct obd_device *obd = class_exp2obd(exp); - struct list_head cancels = LIST_HEAD_INIT(cancels); + LIST_HEAD(cancels); struct ptlrpc_request *req; struct ldlm_intent *lit; struct layout_intent *layout; diff --git a/fs/lustre/mdc/mdc_reint.c b/fs/lustre/mdc/mdc_reint.c index d26e27d..0dc0de4 100644 --- a/fs/lustre/mdc/mdc_reint.c +++ b/fs/lustre/mdc/mdc_reint.c @@ -470,7 +470,7 @@ int mdc_rename(struct obd_export *exp, struct md_op_data *op_data, int mdc_file_resync(struct obd_export *exp, struct md_op_data *op_data) { - struct list_head cancels = LIST_HEAD_INIT(cancels); + LIST_HEAD(cancels); struct ptlrpc_request *req; struct ldlm_lock *lock; struct mdt_rec_resync *rec; diff --git a/fs/lustre/osc/osc_request.c b/fs/lustre/osc/osc_request.c index 39cac7d..d6761dd 100644 --- a/fs/lustre/osc/osc_request.c +++ b/fs/lustre/osc/osc_request.c @@ -3382,7 +3382,7 @@ int osc_cleanup_common(struct obd_device *obd) .quotactl = osc_quotactl, }; -struct list_head osc_shrink_list = LIST_HEAD_INIT(osc_shrink_list); +LIST_HEAD(osc_shrink_list); DEFINE_SPINLOCK(osc_shrink_lock); static struct shrinker osc_cache_shrinker = { diff --git a/fs/lustre/ptlrpc/pinger.c b/fs/lustre/ptlrpc/pinger.c index f584fc6..d8f57bb 100644 --- a/fs/lustre/ptlrpc/pinger.c +++ b/fs/lustre/ptlrpc/pinger.c @@ -43,7 +43,7 @@ struct mutex pinger_mutex; static LIST_HEAD(pinger_imports); -static struct list_head timeout_list = LIST_HEAD_INIT(timeout_list); +static LIST_HEAD(timeout_list); struct ptlrpc_request * ptlrpc_prep_ping(struct obd_import *imp)