Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp2828864rdh; Sun, 26 Nov 2023 22:50:15 -0800 (PST) X-Google-Smtp-Source: AGHT+IHjXb4haBS0Zs1r5L2x+DR9q/NlbgUSrqqHOP9cYI9RVAd68mQYIri2EtfBJWFIxiOJfkRq X-Received: by 2002:a05:6808:1645:b0:3b8:3e7c:f827 with SMTP id az5-20020a056808164500b003b83e7cf827mr12017497oib.14.1701067815237; Sun, 26 Nov 2023 22:50:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701067815; cv=none; d=google.com; s=arc-20160816; b=Y8+L9aIm/UtkhEmu73Z16+Q0B80M5XyxWfMjHPl02UBbMRN62KvKg5tvr6yXkaz0RC jH2/453DW0MDaxrrSMGk3//r8Do1nCfBNEH4jCiAWVQ0aLOVzH1PR8Shi46GVNj9nRaJ Jy9rtW7T8daJ1xDHlkJia+YDpoR0SevYyzHozK+uaoT2+M0thFLe97q3U+q/YCmur61O OehWIdAIoZ69PeqYM8qKra4/xug/fPHoxMpSpZPlYEwmLBcjkxM1M8tYyisBbGgiBcU2 PMz0YfwbbnCiXRMeF0bfVwcwglEyJQxdFcYp/YBsYpaM/KywhWIMqRYJzbb6aUJJmYjA dnoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:dkim-signature:date; bh=HkjYQiNIVrfX2OBhuLTiiwzS64/a/ylKVqG71mkDtoA=; fh=In/CFE+elj7llGuojDcpxuW7HoYiqu3GM430t9TMrTY=; b=CwemFFR75b2E6x2K8BNMIqwEceA+05h5uBkXx/NapkbQ7iLmLzb2nf0XaKKpjSZOZd EQulFyYraA8n+5r785HMOpANJqb4AQmIFUYTGIel2tXxox8uAjizXGNUWSYkrYD4WvnK s2OvolMxJ2ociwR6y8wju0ziUcJQQcsAjW1TeD/XitqdyPASUWUhp0wl4H2uG7n4ITc7 AlgqoYiWF4pEtx1bwZ3FMcH1CryOjeykgUw3dwk9twIM/H2Ez23t5TJHD8R+/Wubi3Kl 8AfQrpiA7zeONNixj7gTfY2p0IR+PDWE9U8ILAf8Y099DJOagV3JFtMvOPIyUIAvhPWd HiZw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b="DL1ZcP/K"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from morse.vger.email (morse.vger.email. [23.128.96.31]) by mx.google.com with ESMTPS id ef23-20020a056a002c9700b006cc05369349si4644891pfb.84.2023.11.26.22.50.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Nov 2023 22:50:15 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) client-ip=23.128.96.31; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b="DL1ZcP/K"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by morse.vger.email (Postfix) with ESMTP id EE67080A95BC; Sun, 26 Nov 2023 22:50:12 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229947AbjK0Gt7 (ORCPT + 99 others); Mon, 27 Nov 2023 01:49:59 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58000 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229527AbjK0Gt6 (ORCPT ); Mon, 27 Nov 2023 01:49:58 -0500 Received: from out-187.mta0.migadu.com (out-187.mta0.migadu.com [IPv6:2001:41d0:1004:224b::bb]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1AF0F134; Sun, 26 Nov 2023 22:50:04 -0800 (PST) Date: Mon, 27 Nov 2023 01:49:53 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1701067801; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=HkjYQiNIVrfX2OBhuLTiiwzS64/a/ylKVqG71mkDtoA=; b=DL1ZcP/KviDDoXIKv0QIFRLZT2BpMmMrebGvWHdGh9aTKtxpmaDswg71Y2nAKp49rM9zFi oCfHCq5KhNQGYzCFdxPL2IiRC5e4TQlt44fRgVAiZlc1g3fzyjxEcQWPI04lYpzGeBzudu z+mDuhqyi808TBjcj4dzEHnQIZ2UEX0= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Kent Overstreet To: Yu Kuai Cc: hch@infradead.org, ming.lei@redhat.com, axboe@kernel.dk, roger.pau@citrix.com, colyli@suse.de, kent.overstreet@gmail.com, joern@lazybastard.org, miquel.raynal@bootlin.com, richard@nod.at, vigneshr@ti.com, sth@linux.ibm.com, hoeppner@linux.ibm.com, hca@linux.ibm.com, gor@linux.ibm.com, agordeev@linux.ibm.com, jejb@linux.ibm.com, martin.petersen@oracle.com, clm@fb.com, josef@toxicpanda.com, dsterba@suse.com, viro@zeniv.linux.org.uk, brauner@kernel.org, nico@fluxnic.net, xiang@kernel.org, chao@kernel.org, tytso@mit.edu, adilger.kernel@dilger.ca, agruenba@redhat.com, jack@suse.com, konishi.ryusuke@gmail.com, dchinner@redhat.com, linux@weissschuh.net, min15.li@samsung.com, yukuai3@huawei.com, dlemoal@kernel.org, willy@infradead.org, akpm@linux-foundation.org, hare@suse.de, p.raghav@samsung.com, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, xen-devel@lists.xenproject.org, linux-bcache@vger.kernel.org, linux-mtd@lists.infradead.org, linux-s390@vger.kernel.org, linux-scsi@vger.kernel.org, linux-bcachefs@vger.kernel.org, linux-btrfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-erofs@lists.ozlabs.org, linux-ext4@vger.kernel.org, gfs2@lists.linux.dev, linux-nilfs@vger.kernel.org, yi.zhang@huawei.com, yangerkun@huawei.com Subject: Re: [PATCH block/for-next v2 07/16] bcachefs: use new helper to get inode from block_device Message-ID: <20231127064953.uo7bf2o62nroyjxs@moria.home.lan> References: <20231127062116.2355129-1-yukuai1@huaweicloud.com> <20231127062116.2355129-8-yukuai1@huaweicloud.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231127062116.2355129-8-yukuai1@huaweicloud.com> X-Migadu-Flow: FLOW_OUT X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on morse.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (morse.vger.email [0.0.0.0]); Sun, 26 Nov 2023 22:50:13 -0800 (PST) On Mon, Nov 27, 2023 at 02:21:07PM +0800, Yu Kuai wrote: > From: Yu Kuai > > Which is more efficiency, and also prepare to remove the field > 'bd_inode' from block_device. > > Signed-off-by: Yu Kuai Acked-by: Kent Overstreet > --- > fs/bcachefs/util.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/fs/bcachefs/util.h b/fs/bcachefs/util.h > index 2984b57b2958..fe7ccb3a3517 100644 > --- a/fs/bcachefs/util.h > +++ b/fs/bcachefs/util.h > @@ -518,7 +518,7 @@ int bch2_bio_alloc_pages(struct bio *, size_t, gfp_t); > > static inline sector_t bdev_sectors(struct block_device *bdev) > { > - return bdev->bd_inode->i_size >> 9; > + return bdev_inode(bdev)->i_size >> 9; > } > > #define closure_bio_submit(bio, cl) \ > -- > 2.39.2 >