[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH block/for-next v2 02/16] xen/blkback: use new helper to get inode from block_device



From: Yu Kuai <yukuai3@xxxxxxxxxx>

Which is more efficiency, and also prepare to remove the field
'bd_inode' from block_device.

Signed-off-by: Yu Kuai <yukuai3@xxxxxxxxxx>
---
 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




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.