Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp5822301pxu; Wed, 23 Dec 2020 06:25:08 -0800 (PST) X-Google-Smtp-Source: ABdhPJyEWbqpe4VgUi8ahMAxM7AkmMgmluW9cOfRow8uHXMRZJHwXtbTlQMJ7+nIEbNlHrXO8U9d X-Received: by 2002:a50:9991:: with SMTP id m17mr24723615edb.48.1608733508236; Wed, 23 Dec 2020 06:25:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1608733508; cv=none; d=google.com; s=arc-20160816; b=KzSegaR2vIrcS81JpEUM5uX+8SwQUjmmuOdTr7xguVl3ZSjbXxkGdn4LM04inS6hrQ mrPv1/ILMWzc8Yutv+v5Cd2pUXKuR8ZgHA8iCEwjqAITXF735WLChXWkyeoa8jcfenWW rsnGWGLOaWHG44jPYUhxMy2dInm7gi7Gpt8YafOxDm9mLu6U7SMcO3nq1W8Las3JzZYX P+IX9Ha35kaSRnAoDzaJTiwoP+GlUZx5g3B6K5tiCACyBWyfUvPTzqawurbQyt2QDCZy SFz4svueZiQTAlNQ2LNucT9o1xPWuGJzpLBj0M0oVAyA+k5DlJNnfqADpOfmSwKfec7F CTrA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :to:subject; bh=Mt89HRXS84I9LnNYs8+PeBR9WBsx0k2wRlsTL+g6Jjc=; b=vo8vSiwYgrIOPkaoeOu4Lu1MWdQ6BfFv8TfunqsxDvr1ksNWQ89FOcaOwnS33GdQo4 y30NcfVUpGR+3eCP8ONgb4K1Sj9FOkM1YMYpUAERZkiF5t+g6d9FQX+dnVObSodh+TR6 Cw0MsrnVvbTUetgS0wVJtLlCI+xbkXJ9X2nDOa3xm4n6fLr7msRoskRGMo0k0mCDYt9r yUtu83jemNrPiaU+fp1Woc9qHh12fCfNmWHrqhmDlQaxO52zpIlR9nkRwcAnckH+4GaL E8MxNtTXd4rOe/nhGTuCVyJ+dCm0xWta2pe/uyiGLzT09KNLm7r9zwvel8A/y/fuWQUf 2FIQ== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id jg40si12135594ejc.197.2020.12.23.06.24.45; Wed, 23 Dec 2020 06:25:08 -0800 (PST) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727431AbgLWOXV (ORCPT + 99 others); Wed, 23 Dec 2020 09:23:21 -0500 Received: from mx2.suse.de ([195.135.220.15]:41198 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726766AbgLWOXV (ORCPT ); Wed, 23 Dec 2020 09:23:21 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id C32C1ACF1; Wed, 23 Dec 2020 14:22:39 +0000 (UTC) Subject: Re: [PATCH -next] md: bcache: use DEFINE_MUTEX (and mutex_init() had been too late) To: Zheng Yongjun , kent.overstreet@gmail.com, linux-bcache@vger.kernel.org, linux-kernel@vger.kernel.org References: <20201223141215.32727-1-zhengyongjun3@huawei.com> From: Coly Li Message-ID: Date: Wed, 23 Dec 2020 22:22:33 +0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:78.0) Gecko/20100101 Thunderbird/78.6.0 MIME-Version: 1.0 In-Reply-To: <20201223141215.32727-1-zhengyongjun3@huawei.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 12/23/20 10:12 PM, Zheng Yongjun wrote: > Signed-off-by: Zheng Yongjun NACK. The commit log is necessary to explain why it is too late, IMHO I don't find the implicit reason from the patch. Coly Li > --- > drivers/md/bcache/super.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c > index 46a00134a36a..963d62a15f37 100644 > --- a/drivers/md/bcache/super.c > +++ b/drivers/md/bcache/super.c > @@ -40,7 +40,7 @@ static const char invalid_uuid[] = { > }; > > static struct kobject *bcache_kobj; > -struct mutex bch_register_lock; > +DEFINE_MUTEX(bch_register_lock); > bool bcache_is_reboot; > LIST_HEAD(bch_cache_sets); > static LIST_HEAD(uncached_devices); > @@ -2832,7 +2832,6 @@ static int __init bcache_init(void) > > check_module_parameters(); > > - mutex_init(&bch_register_lock); > init_waitqueue_head(&unregister_wait); > register_reboot_notifier(&reboot); > >