Message ID | 20231205123728.1866699-1-yukuai1@huaweicloud.com |
---|---|
Headers | show
Return-Path: <linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=YHBWsWBX; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.infradead.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=patchwork.ozlabs.org) Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Sl0Tv55CPz23mj for <incoming@patchwork.ozlabs.org>; Tue, 5 Dec 2023 23:39:31 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=kUPB2zBcpFNdBGSwEhgSDyVqiTbqmhqlZXfR2088D2o=; b=YHBWsWBXprtE14 9t+ywg/AzMUhDlgamuS02qt9j1qM2WHRa321uFrGCvGU30TrPi+dpggPPSII5VgEY2f7ALsIRZpw6 KIQB0+IKehWN5jRWQlbkp490S5LisdL801G8AVndt3b5X4QEqrcTHThK9i4VFTmj5NJCx0Izdr7TO DKntgfoBstLzHXV7CCTwQOpuPpo35agHXHFdOUZ+F5kebtyCrJGExPkfpPW9p/f7rZ/9WaovRuGXH 7eqLxZWYvfB+CYK1kyhlUbHG0SGuuBXu7rtHzsawEBk+6CczfkLPvNVUjMts7o3yTmOtVmo0r95yw 34iskclUpb2RW0OqPALQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1rAUhU-007Ot0-1j; Tue, 05 Dec 2023 12:38:56 +0000 Received: from dggsgout11.his.huawei.com ([45.249.212.51]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1rAUhL-007Ohz-0L for linux-mtd@lists.infradead.org; Tue, 05 Dec 2023 12:38:52 +0000 Received: from mail.maildlp.com (unknown [172.19.93.142]) by dggsgout11.his.huawei.com (SkyGuard) with ESMTP id 4Sl0Sl5M3pz4f3jZd for <linux-mtd@lists.infradead.org>; Tue, 5 Dec 2023 20:38:31 +0800 (CST) Received: from mail02.huawei.com (unknown [10.116.40.112]) by mail.maildlp.com (Postfix) with ESMTP id C136A1A0199 for <linux-mtd@lists.infradead.org>; Tue, 5 Dec 2023 20:38:32 +0800 (CST) Received: from huaweicloud.com (unknown [10.175.104.67]) by APP1 (Coremail) with SMTP id cCh0CgDnNw7GGW9lr8E8Cw--.35507S4; Tue, 05 Dec 2023 20:38:32 +0800 (CST) From: Yu Kuai <yukuai1@huaweicloud.com> To: 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, 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, willy@infradead.org, akpm@linux-foundation.org, hare@suse.de, p.raghav@samsung.com Cc: 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-erofs@lists.ozlabs.org, linux-ext4@vger.kernel.org, gfs2@lists.linux.dev, linux-nilfs@vger.kernel.org, yukuai3@huawei.com, yukuai1@huaweicloud.com, yi.zhang@huawei.com, yangerkun@huawei.com Subject: [PATCH -next RFC 00/14] block: don't access bd_inode directly from other modules Date: Tue, 5 Dec 2023 20:37:14 +0800 Message-Id: <20231205123728.1866699-1-yukuai1@huaweicloud.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-CM-TRANSID: cCh0CgDnNw7GGW9lr8E8Cw--.35507S4 X-Coremail-Antispam: 1UD129KBjvJXoW7Kw4Utry8XFW7Zr18Jr43Wrg_yoW8WF1kpr y3KF1fGr1Uu347Zaya9an7tryrJw4kGay7GF17t34rZr13JryfAr4ktrW8Ja48Jr9rXr4k Xw1DtryFgr10gaDanT9S1TB71UUUUUUqnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDU0xBIdaVrnRJUUUvF14x267AKxVWrJVCq3wAFc2x0x2IEx4CE42xK8VAvwI8IcIk0 rVWrJVCq3wAFIxvE14AKwVWUJVWUGwA2ocxC64kIII0Yj41l84x0c7CEw4AK67xGY2AK02 1l84ACjcxK6xIIjxv20xvE14v26F1j6w1UM28EF7xvwVC0I7IYx2IY6xkF7I0E14v26r4U JVWxJr1l84ACjcxK6I8E87Iv67AKxVW0oVCq3wA2z4x0Y4vEx4A2jsIEc7CjxVAFwI0_Gc CE3s1le2I262IYc4CY6c8Ij28IcVAaY2xG8wAqx4xG64xvF2IEw4CE5I8CrVC2j2WlYx0E 2Ix0cI8IcVAFwI0_Jrv_JF1lYx0Ex4A2jsIE14v26r1j6r4UMcvjeVCFs4IE7xkEbVWUJV W8JwACjcxG0xvY0x0EwIxGrwACjI8F5VA0II8E6IAqYI8I648v4I1lFIxGxcIEc7CjxVA2 Y2ka0xkIwI1l42xK82IYc2Ij64vIr41l4I8I3I0E4IkC6x0Yz7v_Jr0_Gr1lx2IqxVAqx4 xG67AKxVWUJVWUGwC20s026x8GjcxK67AKxVWUGVWUWwC2zVAF1VAY17CE14v26rWY6r4U JwCIc40Y0x0EwIxGrwCI42IY6xIIjxv20xvE14v26r1j6r1xMIIF0xvE2Ix0cI8IcVCY1x 0267AKxVW8JVWxJwCI42IY6xAIw20EY4v20xvaj40_WFyUJVCq3wCI42IY6I8E87Iv67AK xVWUJVW8JwCI42IY6I8E87Iv6xkF7I0E14v26r4j6r4UJbIYCTnIWIevJa73UjIFyTuYvj fUoL0eDUUUU X-CM-SenderInfo: 51xn3trlr6x35dzhxuhorxvhhfrp/ X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231205_043847_538967_C7534BB0 X-CRM114-Status: UNSURE ( 5.73 ) X-CRM114-Notice: Please train this message. X-Spam-Score: 0.0 (/) X-Spam-Report: Spam detection software, running on the system "bombadil.infradead.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: From: Yu Kuai <yukuai3@huawei.com> Patch 1 add some bdev apis, then follow up patches will use these apis to avoid access bd_inode directly, and hopefully the field bd_inode can be removed eventually(after figure out a way for fs/buffe [...] Content analysis details: (0.0 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [45.249.212.51 listed in wl.mailspike.net] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.0 SPF_NONE SPF: sender does not publish an SPF Record X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux MTD discussion mailing list <linux-mtd.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-mtd>, <mailto:linux-mtd-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-mtd/> List-Post: <mailto:linux-mtd@lists.infradead.org> List-Help: <mailto:linux-mtd-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-mtd>, <mailto:linux-mtd-request@lists.infradead.org?subject=subscribe> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-mtd" <linux-mtd-bounces@lists.infradead.org> Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org |
Series |
block: don't access bd_inode directly from other modules
|
expand
|
On Tue, Dec 05, 2023 at 08:37:14PM +0800, Yu Kuai wrote: > From: Yu Kuai <yukuai3@huawei.com> > > Patch 1 add some bdev apis, then follow up patches will use these apis > to avoid access bd_inode directly, and hopefully the field bd_inode can > be removed eventually(after figure out a way for fs/buffer.c). What tree is this against? It fails to apply to either Jens' for-6.8/block or Linus tree in the very first patch.
Hi, 在 2023/12/06 13:54, Christoph Hellwig 写道: > On Tue, Dec 05, 2023 at 08:37:14PM +0800, Yu Kuai wrote: >> From: Yu Kuai <yukuai3@huawei.com> >> >> Patch 1 add some bdev apis, then follow up patches will use these apis >> to avoid access bd_inode directly, and hopefully the field bd_inode can >> be removed eventually(after figure out a way for fs/buffer.c). > > What tree is this against? It fails to apply to either Jens' > for-6.8/block or Linus tree in the very first patch. It was against linux-next branch, for the tag next-20231201, because I'm not sure yet if this patchset should be applied to Jans' tree. Please let me know if I should swith wo Jens' tree for v2. Thanks, Kuai > > . >
From: Yu Kuai <yukuai3@huawei.com> Patch 1 add some bdev apis, then follow up patches will use these apis to avoid access bd_inode directly, and hopefully the field bd_inode can be removed eventually(after figure out a way for fs/buffer.c). Yu Kuai (14): block: add some bdev apis xen/blkback: use bdev api in xen_update_blkif_status() bcache: use bdev api in read_super() mtd: block2mtd: use bdev apis s390/dasd: use bdev api in dasd_format() scsicam: use bdev api in scsi_bios_ptable() bcachefs: remove dead function bdev_sectors() btrfs: use bdev apis cramfs: use bdev apis in cramfs_blkdev_read() erofs: use bdev api ext4: use bdev apis jbd2: use bdev apis gfs2: use bdev api nilfs2: use bdev api in nilfs_attach_log_writer() block/bdev.c | 116 +++++++++++++++++++++++++++++ block/bio.c | 1 + block/blk.h | 2 - drivers/block/xen-blkback/xenbus.c | 3 +- drivers/md/bcache/super.c | 11 ++- drivers/mtd/devices/block2mtd.c | 80 +++++++++----------- drivers/s390/block/dasd_ioctl.c | 5 +- drivers/scsi/scsicam.c | 3 +- fs/bcachefs/util.h | 5 -- fs/btrfs/disk-io.c | 68 ++++++++--------- fs/btrfs/volumes.c | 17 ++--- fs/btrfs/zoned.c | 12 ++- fs/cramfs/inode.c | 35 +++------ fs/erofs/data.c | 17 +++-- fs/erofs/internal.h | 1 + fs/ext4/dir.c | 6 +- fs/ext4/ext4_jbd2.c | 6 +- fs/ext4/super.c | 27 +------ fs/gfs2/glock.c | 2 +- fs/gfs2/ops_fstype.c | 2 +- fs/jbd2/journal.c | 3 +- fs/jbd2/recovery.c | 6 +- fs/nilfs2/segment.c | 2 +- include/linux/blkdev.h | 27 +++++++ include/linux/buffer_head.h | 5 +- 25 files changed, 273 insertions(+), 189 deletions(-)