[PATCH block/for-next v2 02/16] xen/blkback: use new helper to get inode from block_device
Yu Kuai
yukuai1 at huaweicloud.com
Mon Nov 27 17:21:02 AEDT 2023
From: Yu Kuai <yukuai3 at huawei.com>
Which is more efficiency, and also prepare to remove the field
'bd_inode' from block_device.
Signed-off-by: Yu Kuai <yukuai3 at huawei.com>
---
drivers/block/xen-blkback/xenbus.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/block/xen-blkback/xenbus.c b/drivers/block/xen-blkback/xenbus.c
index e34219ea2b05..e11f8123d213 100644
--- a/drivers/block/xen-blkback/xenbus.c
+++ b/drivers/block/xen-blkback/xenbus.c
@@ -105,7 +105,7 @@ static void xen_update_blkif_status(struct xen_blkif *blkif)
return;
}
invalidate_inode_pages2(
- blkif->vbd.bdev_handle->bdev->bd_inode->i_mapping);
+ bdev_inode(blkif->vbd.bdev_handle->bdev)->i_mapping);
for (i = 0; i < blkif->nr_rings; i++) {
ring = &blkif->rings[i];
--
2.39.2
More information about the Linux-erofs
mailing list