xfs: remove xfs_blkdev_issue_flush
authorDave Chinner <dchinner@redhat.com>
Fri, 18 Jun 2021 15:21:49 +0000 (08:21 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Mon, 21 Jun 2021 17:05:46 +0000 (10:05 -0700)
It's a one line wrapper around blkdev_issue_flush(). Just replace it
with direct calls to blkdev_issue_flush().

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Chandan Babu R <chandanrlinux@gmail.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Reviewed-by: Allison Henderson <allison.henderson@oracle.com>
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
fs/xfs/xfs_buf.c
fs/xfs/xfs_file.c
fs/xfs/xfs_log.c
fs/xfs/xfs_super.c
fs/xfs/xfs_super.h

index 11edd4ad815142f9ec391e91b85762a0ab9afd62..8ff42b3585e0fc9eb52d33e3371ef90e4df4d03d 100644 (file)
@@ -1889,7 +1889,7 @@ xfs_free_buftarg(
        percpu_counter_destroy(&btp->bt_io_count);
        list_lru_destroy(&btp->bt_lru);
 
-       xfs_blkdev_issue_flush(btp);
+       blkdev_issue_flush(btp->bt_bdev);
 
        kmem_free(btp);
 }
index 9fd5a82a814c0312d1e618cfabf520292e62d789..62262d69e39d12304803f724f9ba250c5e006b82 100644 (file)
@@ -197,9 +197,9 @@ xfs_file_fsync(
         * inode size in case of an extending write.
         */
        if (XFS_IS_REALTIME_INODE(ip))
-               xfs_blkdev_issue_flush(mp->m_rtdev_targp);
+               blkdev_issue_flush(mp->m_rtdev_targp->bt_bdev);
        else if (mp->m_logdev_targp != mp->m_ddev_targp)
-               xfs_blkdev_issue_flush(mp->m_ddev_targp);
+               blkdev_issue_flush(mp->m_ddev_targp->bt_bdev);
 
        /*
         * Any inode that has dirty modifications in the log is pinned.  The
@@ -219,7 +219,7 @@ xfs_file_fsync(
         */
        if (!log_flushed && !XFS_IS_REALTIME_INODE(ip) &&
            mp->m_logdev_targp == mp->m_ddev_targp)
-               xfs_blkdev_issue_flush(mp->m_ddev_targp);
+               blkdev_issue_flush(mp->m_ddev_targp->bt_bdev);
 
        return error;
 }
index 17ece07de439c0031645a1fed83a87da01221220..b7f858ade134da55ffcdcf3a2ef17d9734956988 100644 (file)
@@ -1964,7 +1964,7 @@ xlog_sync(
         * layer state machine for preflushes.
         */
        if (log->l_targ != log->l_mp->m_ddev_targp || split) {
-               xfs_blkdev_issue_flush(log->l_mp->m_ddev_targp);
+               blkdev_issue_flush(log->l_mp->m_ddev_targp->bt_bdev);
                need_flush = false;
        }
 
index 3a7fd4f02aa73910d33147deef7c1fef8c84159e..2c9e26a44546b8d6085ac92a1ae2c9fa43c58f47 100644 (file)
@@ -340,13 +340,6 @@ xfs_blkdev_put(
                blkdev_put(bdev, FMODE_READ|FMODE_WRITE|FMODE_EXCL);
 }
 
-void
-xfs_blkdev_issue_flush(
-       xfs_buftarg_t           *buftarg)
-{
-       blkdev_issue_flush(buftarg->bt_bdev);
-}
-
 STATIC void
 xfs_close_devices(
        struct xfs_mount        *mp)
index d2b40dc60dfc2e11b689440198bafd248f935b3c..167d23f92ffe5aff8c98e4a0012b09846140bc61 100644 (file)
@@ -87,7 +87,6 @@ struct xfs_buftarg;
 struct block_device;
 
 extern void xfs_flush_inodes(struct xfs_mount *mp);
-extern void xfs_blkdev_issue_flush(struct xfs_buftarg *);
 extern xfs_agnumber_t xfs_set_inode_alloc(struct xfs_mount *,
                                           xfs_agnumber_t agcount);