]> www.infradead.org Git - users/hch/xfsprogs.git/commitdiff
libxfs: turn the xfs_buf_incore stub into an inline function
authorChristoph Hellwig <hch@lst.de>
Wed, 8 Apr 2020 13:48:15 +0000 (09:48 -0400)
committerEric Sandeen <sandeen@sandeen.net>
Wed, 8 Apr 2020 13:48:15 +0000 (09:48 -0400)
Replace the macro with an inline function to avoid compiler warnings with new
backports of kernel code.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
libxfs/libxfs_priv.h

index 6d5e47608b6bd281db04b74a44d94a4f2a216e80..3cd2be5bd066d6c334aaa7a73c0dad0d0c9cd579 100644 (file)
@@ -371,8 +371,12 @@ roundup_64(uint64_t x, uint32_t y)
 #define XFS_BUF_UNDELAYWRITE(bp)       ((bp)->b_flags &= ~LIBXFS_B_DIRTY)
 #define XFS_BUF_SET_BDSTRAT_FUNC(a,b)  ((void) 0)
 
-/* avoid gcc warning */
-#define xfs_buf_incore(bt,blkno,len,lockit)    NULL
+static inline struct xfs_buf *xfs_buf_incore(struct xfs_buftarg *target,
+               xfs_daddr_t blkno, size_t numblks, xfs_buf_flags_t flags)
+{
+       return NULL;
+}
+
 #define xfs_buf_oneshot(bp)            ((void) 0)
 
 #define XBRW_READ                      LIBXFS_BREAD