All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Darrick J. Wong" <darrick.wong@oracle.com>
To: sandeen@sandeen.net, darrick.wong@oracle.com
Cc: linux-xfs@vger.kernel.org, Christoph Hellwig <hch@lst.de>
Subject: [PATCH 25/26] libxfs: rename libxfs_getbuf_map to libxfs_buf_get_map
Date: Fri, 28 Feb 2020 15:38:57 -0800	[thread overview]
Message-ID: <158293313709.1549542.17829043819672414218.stgit@magnolia> (raw)
In-Reply-To: <158293297395.1549542.18143701542461010748.stgit@magnolia>

From: Darrick J. Wong <darrick.wong@oracle.com>

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>
---
 libxfs/libxfs_io.h |    8 ++++----
 libxfs/rdwr.c      |   18 +++++++++---------
 libxfs/trans.c     |    4 ++--
 repair/prefetch.c  |    2 +-
 4 files changed, 16 insertions(+), 16 deletions(-)


diff --git a/libxfs/libxfs_io.h b/libxfs/libxfs_io.h
index 62b09205..957f0396 100644
--- a/libxfs/libxfs_io.h
+++ b/libxfs/libxfs_io.h
@@ -141,7 +141,7 @@ extern struct cache_operations	libxfs_bcache_operations;
 #define libxfs_buf_get(dev, daddr, len) \
 	libxfs_trace_getbuf(__FUNCTION__, __FILE__, __LINE__, \
 			    (dev), (daddr), (len))
-#define libxfs_getbuf_map(dev, map, nmaps, flags) \
+#define libxfs_buf_get_map(dev, map, nmaps, flags) \
 	libxfs_trace_getbuf_map(__FUNCTION__, __FILE__, __LINE__, \
 			    (dev), (map), (nmaps), (flags))
 #define libxfs_buf_relse(buf) \
@@ -169,8 +169,8 @@ 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);
+struct xfs_buf *libxfs_buf_get_map(struct xfs_buftarg *btp,
+			struct xfs_buf_map *map, int nmaps, int flags);
 void	libxfs_buf_relse(struct xfs_buf *bp);
 
 static inline struct xfs_buf*
@@ -181,7 +181,7 @@ libxfs_buf_get(
 {
 	DEFINE_SINGLE_BUF_MAP(map, blkno, numblks);
 
-	return libxfs_getbuf_map(target, &map, 1, 0);
+	return libxfs_buf_get_map(target, &map, 1, 0);
 }
 
 static inline struct xfs_buf*
diff --git a/libxfs/rdwr.c b/libxfs/rdwr.c
index 2a96646b..79d74583 100644
--- a/libxfs/rdwr.c
+++ b/libxfs/rdwr.c
@@ -156,7 +156,7 @@ static char *next(
 
 #undef libxfs_buf_read_map
 #undef libxfs_writebuf
-#undef libxfs_getbuf_map
+#undef libxfs_buf_get_map
 
 struct xfs_buf	*libxfs_buf_read_map(struct xfs_buftarg *btp,
 			struct xfs_buf_map *map, int nmaps, int flags,
@@ -164,8 +164,8 @@ struct xfs_buf	*libxfs_buf_read_map(struct xfs_buftarg *btp,
 int		libxfs_writebuf(xfs_buf_t *, int);
 struct xfs_buf *libxfs_buf_get(struct xfs_buftarg *btp, xfs_daddr_t daddr,
 				size_t len);
-xfs_buf_t	*libxfs_getbuf_map(struct xfs_buftarg *, struct xfs_buf_map *,
-				int, int);
+struct xfs_buf	*libxfs_buf_get_map(struct xfs_buftarg *btp,
+			struct xfs_buf_map *map, int nmaps, int flags);
 void		libxfs_buf_relse(struct xfs_buf *bp);
 
 #define	__add_trace(bp, func, file, line)	\
@@ -219,7 +219,7 @@ libxfs_trace_getbuf(
 	struct xfs_buf		*bp;
 	DEFINE_SINGLE_BUF_MAP(map, blkno, numblks);
 
-	bp = libxfs_getbuf_map(target, &map, 1, 0);
+	bp = libxfs_buf_get_map(target, &map, 1, 0);
 	__add_trace(bp, func, file, line);
 	return bp;
 }
@@ -229,7 +229,7 @@ libxfs_trace_getbuf_map(const char *func, const char *file, int line,
 		struct xfs_buftarg *btp, struct xfs_buf_map *map, int nmaps,
 		int flags)
 {
-	xfs_buf_t	*bp = libxfs_getbuf_map(btp, map, nmaps, flags);
+	xfs_buf_t	*bp = libxfs_buf_get_map(btp, map, nmaps, flags);
 	__add_trace(bp, func, file, line);
 	return bp;
 }
@@ -575,7 +575,7 @@ reset_buf_state(
 }
 
 static struct xfs_buf *
-__libxfs_getbuf_map(struct xfs_buftarg *btp, struct xfs_buf_map *map,
+__libxfs_buf_get_map(struct xfs_buftarg *btp, struct xfs_buf_map *map,
 		    int nmaps, int flags)
 {
 	struct xfs_bufkey key = {NULL};
@@ -597,12 +597,12 @@ __libxfs_getbuf_map(struct xfs_buftarg *btp, struct xfs_buf_map *map,
 }
 
 struct xfs_buf *
-libxfs_getbuf_map(struct xfs_buftarg *btp, struct xfs_buf_map *map,
+libxfs_buf_get_map(struct xfs_buftarg *btp, struct xfs_buf_map *map,
 		  int nmaps, int flags)
 {
 	struct xfs_buf	*bp;
 
-	bp = __libxfs_getbuf_map(btp, map, nmaps, flags);
+	bp = __libxfs_buf_get_map(btp, map, nmaps, flags);
 	reset_buf_state(bp);
 	return bp;
 }
@@ -807,7 +807,7 @@ libxfs_buf_read_map(struct xfs_buftarg *btp, struct xfs_buf_map *map, int nmaps,
 		return libxfs_readbuf(btp, map[0].bm_bn, map[0].bm_len,
 					flags, ops);
 
-	bp = __libxfs_getbuf_map(btp, map, nmaps, 0);
+	bp = __libxfs_buf_get_map(btp, map, nmaps, 0);
 	if (!bp)
 		return NULL;
 
diff --git a/libxfs/trans.c b/libxfs/trans.c
index ebdc73d5..b78bca86 100644
--- a/libxfs/trans.c
+++ b/libxfs/trans.c
@@ -427,7 +427,7 @@ libxfs_trans_get_buf_map(
 	struct xfs_buf_log_item	*bip;
 
 	if (!tp)
-		return libxfs_getbuf_map(target, map, nmaps, 0);
+		return libxfs_buf_get_map(target, map, nmaps, 0);
 
 	/*
 	 * If we find the buffer in the cache with this transaction
@@ -445,7 +445,7 @@ libxfs_trans_get_buf_map(
 		return bp;
 	}
 
-	bp = libxfs_getbuf_map(target, map, nmaps, 0);
+	bp = libxfs_buf_get_map(target, map, nmaps, 0);
 	if (bp == NULL) {
 		return NULL;
 	}
diff --git a/repair/prefetch.c b/repair/prefetch.c
index a3858f9a..7f705cc0 100644
--- a/repair/prefetch.c
+++ b/repair/prefetch.c
@@ -120,7 +120,7 @@ pf_queue_io(
 	 * the lock holder is either reading it from disk himself or
 	 * completely overwriting it this behaviour is perfectly fine.
 	 */
-	bp = libxfs_getbuf_map(mp->m_dev, map, nmaps, LIBXFS_GETBUF_TRYLOCK);
+	bp = libxfs_buf_get_map(mp->m_dev, map, nmaps, LIBXFS_GETBUF_TRYLOCK);
 	if (!bp)
 		return;
 


  parent reply	other threads:[~2020-02-28 23:41 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-28 23:36 [PATCH v3 00/26] xfsprogs: refactor buffer function names Darrick J. Wong
2020-02-28 23:36 ` [PATCH 01/26] libxfs: open-code "exit on buffer read failure" in upper level callers Darrick J. Wong
2020-02-28 23:36 ` [PATCH 02/26] libxfs: remove LIBXFS_EXIT_ON_FAILURE Darrick J. Wong
2020-02-28 23:36 ` [PATCH 03/26] libxfs: remove LIBXFS_B_EXIT Darrick J. Wong
2020-02-28 23:36 ` [PATCH 04/26] libxfs: replace libxfs_putbuf with libxfs_buf_relse Darrick J. Wong
2020-02-28 23:36 ` [PATCH 05/26] libxfs: replace libxfs_getbuf with libxfs_buf_get Darrick J. Wong
2020-02-28 23:36 ` [PATCH 06/26] libxfs: replace libxfs_readbuf with libxfs_buf_read Darrick J. Wong
2020-02-28 23:37 ` [PATCH 07/26] libxfs: rename libxfs_writebufr to libxfs_bwrite Darrick J. Wong
2020-02-28 23:37 ` [PATCH 08/26] libxfs: make libxfs_readbuf_verify return an error code Darrick J. Wong
2020-02-28 23:37 ` [PATCH 09/26] libxfs: make libxfs_readbufr stash the error value in b_error Darrick J. Wong
2020-02-28 23:37 ` [PATCH 10/26] libxfs: introduce libxfs_buf_read_uncached Darrick J. Wong
2020-02-28 23:37 ` [PATCH 11/26] xfs_db: use uncached buffer reads to get the superblock Darrick J. Wong
2020-02-28 23:37 ` [PATCH 12/26] xfs_copy: " Darrick J. Wong
2020-02-28 23:37 ` [PATCH 13/26] libxfs: move log functions for convenience Darrick J. Wong
2020-02-29 22:35   ` Eric Sandeen
2020-02-28 23:37 ` [PATCH 14/26] libxfs: convert libxfs_log_clear to use uncached buffers Darrick J. Wong
2020-02-29 22:45   ` Eric Sandeen
2020-02-28 23:37 ` [PATCH 15/26] libxlog: use uncached buffers instead of open-coding them Darrick J. Wong
2020-02-28 23:38 ` [PATCH 16/26] libxfs: use uncached buffers for initial mkfs writes Darrick J. Wong
2020-02-28 23:38 ` [PATCH 17/26] libxfs: straighten out libxfs_writebuf naming confusion Darrick J. Wong
2020-02-28 23:38 ` [PATCH 18/26] libxfs: remove unused flags parameter to libxfs_buf_mark_dirty Darrick J. Wong
2020-02-28 23:38 ` [PATCH 19/26] libxfs: remove libxfs_writebuf_int Darrick J. Wong
2020-02-28 23:38 ` [PATCH 20/26] libxfs: remove dangerous casting between xfs_buf and cache_node Darrick J. Wong
2020-02-28 23:38 ` [PATCH 21/26] libxfs: remove dangerous casting between cache_node and xfs_buf Darrick J. Wong
2020-02-28 23:38 ` [PATCH 22/26] libxfs: remove the libxfs_{get,put}bufr APIs Darrick J. Wong
2020-02-28 23:38 ` [PATCH 23/26] libxfs: hide libxfs_getbuf_flags Darrick J. Wong
2020-02-28 23:38 ` [PATCH 24/26] libxfs: rename libxfs_readbuf_map to libxfs_buf_read_map Darrick J. Wong
2020-02-28 23:38 ` Darrick J. Wong [this message]
2020-02-28 23:39 ` [PATCH 26/26] libxfs: convert buffer priority get/set macros to functions Darrick J. Wong
2020-02-29 22:52   ` Eric Sandeen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=158293313709.1549542.17829043819672414218.stgit@magnolia \
    --to=darrick.wong@oracle.com \
    --cc=hch@lst.de \
    --cc=linux-xfs@vger.kernel.org \
    --cc=sandeen@sandeen.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.