]> www.infradead.org Git - users/hch/xfsprogs.git/commitdiff
libxfs: rename libxfs_readbuf_map to libxfs_buf_read_map
authorDarrick J. Wong <darrick.wong@oracle.com>
Sun, 1 Mar 2020 17:34:11 +0000 (12:34 -0500)
committerEric Sandeen <sandeen@sandeen.net>
Sun, 1 Mar 2020 17:34:11 +0000 (12:34 -0500)
Rename this function to match the kernel function.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
db/io.c
libxfs/libxfs_io.h
libxfs/rdwr.c
libxfs/trans.c
repair/da_util.c

diff --git a/db/io.c b/db/io.c
index 7c7a46242fda55de2a706961221a1ea432bd7b45..b81e996963d4c10e596fc206cad3ce8167cb4f07 100644 (file)
--- a/db/io.c
+++ b/db/io.c
@@ -542,7 +542,7 @@ set_cur(
                if (!iocur_top->bbmap)
                        return;
                memcpy(iocur_top->bbmap, bbmap, sizeof(struct bbmap));
-               bp = libxfs_readbuf_map(mp->m_ddev_targp, bbmap->b,
+               bp = libxfs_buf_read_map(mp->m_ddev_targp, bbmap->b,
                                        bbmap->nmaps, 0, ops);
        } else {
                bp = libxfs_buf_read(mp->m_ddev_targp, blknum, len, 0, ops);
index 7f513d86212ba9b6ef891983ded66e3dd2df0ce5..62b09205c9c59af88606b12eb45710070aa8f45f 100644 (file)
@@ -132,7 +132,7 @@ extern struct cache_operations      libxfs_bcache_operations;
 #define libxfs_buf_read(dev, daddr, len, flags, ops) \
        libxfs_trace_readbuf(__FUNCTION__, __FILE__, __LINE__, \
                            (dev), (daddr), (len), (flags), (ops))
-#define libxfs_readbuf_map(dev, map, nmaps, flags, ops) \
+#define libxfs_buf_read_map(dev, map, nmaps, flags, ops) \
        libxfs_trace_readbuf_map(__FUNCTION__, __FILE__, __LINE__, \
                            (dev), (map), (nmaps), (flags), (ops))
 #define libxfs_buf_mark_dirty(buf) \
@@ -165,8 +165,9 @@ extern void libxfs_trace_putbuf (const char *, const char *, int,
 
 #else
 
-extern xfs_buf_t *libxfs_readbuf_map(struct xfs_buftarg *, struct xfs_buf_map *,
-                       int, int, const struct xfs_buf_ops *);
+struct xfs_buf *libxfs_buf_read_map(struct xfs_buftarg *btp,
+                       struct xfs_buf_map *map, int nmaps, int flags,
+                       const struct xfs_buf_ops *ops);
 void libxfs_buf_mark_dirty(struct xfs_buf *bp);
 extern xfs_buf_t *libxfs_getbuf_map(struct xfs_buftarg *,
                        struct xfs_buf_map *, int, int);
@@ -193,7 +194,7 @@ libxfs_buf_read(
 {
        DEFINE_SINGLE_BUF_MAP(map, blkno, numblks);
 
-       return libxfs_readbuf_map(target, &map, 1, flags, ops);
+       return libxfs_buf_read_map(target, &map, 1, flags, ops);
 }
 
 #endif /* XFS_BUF_TRACING */
index 549fe3c1f5f123554dfa4fc0074fad9b4651efe4..2a96646b939a548138b69c4be8012e59c5f221ff 100644 (file)
@@ -154,12 +154,13 @@ static char *next(
 
 #ifdef XFS_BUF_TRACING
 
-#undef libxfs_readbuf_map
+#undef libxfs_buf_read_map
 #undef libxfs_writebuf
 #undef libxfs_getbuf_map
 
-xfs_buf_t      *libxfs_readbuf_map(struct xfs_buftarg *, struct xfs_buf_map *,
-                               int, int, const struct xfs_buf_ops *);
+struct xfs_buf *libxfs_buf_read_map(struct xfs_buftarg *btp,
+                       struct xfs_buf_map *map, int nmaps, int flags,
+                       const struct xfs_buf_ops *ops);
 int            libxfs_writebuf(xfs_buf_t *, int);
 struct xfs_buf *libxfs_buf_get(struct xfs_buftarg *btp, xfs_daddr_t daddr,
                                size_t len);
@@ -190,7 +191,7 @@ libxfs_trace_readbuf(
        struct xfs_buf          *bp;
        DEFINE_SINGLE_BUF_MAP(map, blkno, numblks);
 
-       bp = libxfs_readbuf_map(btp, &map, 1, flags, ops);
+       bp = libxfs_buf_read_map(btp, &map, 1, flags, ops);
        __add_trace(bp, func, file, line);
        return bp;
 }
@@ -796,7 +797,7 @@ libxfs_readbufr_map(struct xfs_buftarg *btp, struct xfs_buf *bp, int flags)
 }
 
 struct xfs_buf *
-libxfs_readbuf_map(struct xfs_buftarg *btp, struct xfs_buf_map *map, int nmaps,
+libxfs_buf_read_map(struct xfs_buftarg *btp, struct xfs_buf_map *map, int nmaps,
                int flags, const struct xfs_buf_ops *ops)
 {
        struct xfs_buf  *bp;
index df1ec90b10a5a30773cd8c102df10052d035ce57..ebdc73d5dd02a1f1d81ed1bf8c37e8bddf384d53 100644 (file)
@@ -507,7 +507,7 @@ libxfs_trans_read_buf_map(
        *bpp = NULL;
 
        if (tp == NULL) {
-               bp = libxfs_readbuf_map(target, map, nmaps, flags, ops);
+               bp = libxfs_buf_read_map(target, map, nmaps, flags, ops);
                if (!bp) {
                        return (flags & XBF_TRYLOCK) ?  -EAGAIN : -ENOMEM;
                }
@@ -526,7 +526,7 @@ libxfs_trans_read_buf_map(
                goto done;
        }
 
-       bp = libxfs_readbuf_map(target, map, nmaps, flags, ops);
+       bp = libxfs_buf_read_map(target, map, nmaps, flags, ops);
        if (!bp) {
                return (flags & XBF_TRYLOCK) ?  -EAGAIN : -ENOMEM;
        }
index dc1e5bfeeb1d0b408a0f20e6a8b26860ec524bbc..e639ecdad71c1fdcc0f24590ab85b8f85a2bab14 100644 (file)
@@ -64,7 +64,7 @@ da_read_buf(
                map[i].bm_bn = XFS_FSB_TO_DADDR(mp, bmp[i].startblock);
                map[i].bm_len = XFS_FSB_TO_BB(mp, bmp[i].blockcount);
        }
-       bp = libxfs_readbuf_map(mp->m_dev, map, nex, 0, ops);
+       bp = libxfs_buf_read_map(mp->m_dev, map, nex, 0, ops);
        if (map != map_array)
                free(map);
        return bp;