From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.2 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7FB17C63798 for ; Thu, 19 Nov 2020 08:25:10 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id BCC5F246CE for ; Thu, 19 Nov 2020 08:25:09 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org BCC5F246CE Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id A63676B005C; Thu, 19 Nov 2020 03:25:08 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 9E8816B005D; Thu, 19 Nov 2020 03:25:08 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 8B1286B0068; Thu, 19 Nov 2020 03:25:08 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0107.hostedemail.com [216.40.44.107]) by kanga.kvack.org (Postfix) with ESMTP id 5F9836B005C for ; Thu, 19 Nov 2020 03:25:08 -0500 (EST) Received: from smtpin30.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay05.hostedemail.com (Postfix) with ESMTP id F3A62181AEF23 for ; Thu, 19 Nov 2020 08:25:07 +0000 (UTC) X-FDA: 77500482696.30.noise99_0a04af227341 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin30.hostedemail.com (Postfix) with ESMTP id CF826180B3C85 for ; Thu, 19 Nov 2020 08:25:07 +0000 (UTC) X-HE-Tag: noise99_0a04af227341 X-Filterd-Recvd-Size: 2725 Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by imf49.hostedemail.com (Postfix) with ESMTP for ; Thu, 19 Nov 2020 08:25:07 +0000 (UTC) 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 1FC9DAD2F; Thu, 19 Nov 2020 08:25:06 +0000 (UTC) Received: by quack2.suse.cz (Postfix, from userid 1000) id C74001E1303; Thu, 19 Nov 2020 09:25:05 +0100 (CET) Date: Thu, 19 Nov 2020 09:25:05 +0100 From: Jan Kara To: Christoph Hellwig Cc: Jan Kara , Jens Axboe , Tejun Heo , Josef Bacik , Konrad Rzeszutek Wilk , Coly Li , Mike Snitzer , dm-devel@redhat.com, Richard Weinberger , Jan Kara , linux-block@vger.kernel.org, xen-devel@lists.xenproject.org, linux-bcache@vger.kernel.org, linux-mtd@lists.infradead.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH 07/20] init: refactor name_to_dev_t Message-ID: <20201119082505.GS1981@quack2.suse.cz> References: <20201118084800.2339180-1-hch@lst.de> <20201118084800.2339180-8-hch@lst.de> <20201118143747.GL1981@quack2.suse.cz> <20201119075225.GA15815@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201119075225.GA15815@lst.de> User-Agent: Mutt/1.10.1 (2018-07-13) X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Thu 19-11-20 08:52:25, Christoph Hellwig wrote: > On Wed, Nov 18, 2020 at 03:37:47PM +0100, Jan Kara wrote: > > > -static inline dev_t blk_lookup_devt(const char *name, int partno) > > > -{ > > > - dev_t devt = MKDEV(0, 0); > > > - return devt; > > > -} > > > #endif /* CONFIG_BLOCK */ > > > > This hunk looks unrelated to the change? Also why you move the declaration > > outside the CONFIG_BLOCK ifdef? AFAICS blk_lookup_devt() still exists only > > when CONFIG_BLOCK is defined? Otherwise the patch looks good to me. > > blk_lookup_devt is a hack only for name_to_dev_t only referenced from > code under CONFIG_BLOCK now, as it didn't do anything before when > blk_lookup_devt returned 0. I guess I'll need to update the commit log > a little to mention this. OK, understood. Still it would seem more logical to leave blk_lookup_devt() declaration inside #ifdef CONFIG_BLOCK and just delete the !CONFIG_BLOCK definition (to make it clear we ever expect only users compiled when CONFIG_BLOCK is defined). But whatever... Feel free to add: Reviewed-by: Jan Kara Honza -- Jan Kara SUSE Labs, CR