]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
xfs: move xfs_symlink_remote.c declarations to xfs_symlink_remote.h
authorDarrick J. Wong <djwong@kernel.org>
Thu, 22 Feb 2024 20:45:01 +0000 (12:45 -0800)
committerDarrick J. Wong <djwong@kernel.org>
Thu, 22 Feb 2024 20:45:01 +0000 (12:45 -0800)
Move declarations for libxfs symlink functions into a separate header
file like we do for most everything else.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
fs/xfs/libxfs/xfs_bmap.c
fs/xfs/libxfs/xfs_inode_fork.c
fs/xfs/libxfs/xfs_shared.h
fs/xfs/libxfs/xfs_symlink_remote.c
fs/xfs/libxfs/xfs_symlink_remote.h [new file with mode: 0644]
fs/xfs/scrub/inode_repair.c
fs/xfs/scrub/symlink.c
fs/xfs/xfs_symlink.c

index d78e02a3b4d62bd82fc8409ebf6caf8bd0f9886c..656c95a22f2e6deb40128fbe1aa8c1b62b1f64d2 100644 (file)
@@ -38,6 +38,7 @@
 #include "xfs_iomap.h"
 #include "xfs_health.h"
 #include "xfs_bmap_item.h"
+#include "xfs_symlink_remote.h"
 
 struct kmem_cache              *xfs_bmap_intent_cache;
 
index 3ab0ea1335571a4059f0c508ca480c1af5194f04..7d660a9739090ae0dca7658328412200157abc8a 100644 (file)
@@ -26,6 +26,7 @@
 #include "xfs_types.h"
 #include "xfs_errortag.h"
 #include "xfs_health.h"
+#include "xfs_symlink_remote.h"
 
 struct kmem_cache *xfs_ifork_cache;
 
index cab49e7116ec54a51ac2136314ac409e130e8136..dfd61fa8332e1ae9e47127fa71179ce1bfc15e3e 100644 (file)
@@ -182,19 +182,6 @@ void       xfs_log_get_max_trans_res(struct xfs_mount *mp,
 #define        XFS_ICHGTIME_CHG        0x2     /* inode field change timestamp */
 #define        XFS_ICHGTIME_CREATE     0x4     /* inode create timestamp */
 
-
-/*
- * Symlink decoding/encoding functions
- */
-int xfs_symlink_blocks(struct xfs_mount *mp, int pathlen);
-int xfs_symlink_hdr_set(struct xfs_mount *mp, xfs_ino_t ino, uint32_t offset,
-                       uint32_t size, struct xfs_buf *bp);
-bool xfs_symlink_hdr_ok(xfs_ino_t ino, uint32_t offset,
-                       uint32_t size, struct xfs_buf *bp);
-void xfs_symlink_local_to_remote(struct xfs_trans *tp, struct xfs_buf *bp,
-                                struct xfs_inode *ip, struct xfs_ifork *ifp);
-xfs_failaddr_t xfs_symlink_shortform_verify(void *sfp, int64_t size);
-
 /* Computed inode geometry for the filesystem. */
 struct xfs_ino_geometry {
        /* Maximum inode count in this filesystem. */
index 160aa20aa44139b026c4b0c8b662474082faca02..7c39cb0307d9bb61b0bfeb146bb383979be923b0 100644 (file)
@@ -16,7 +16,7 @@
 #include "xfs_trans.h"
 #include "xfs_buf_item.h"
 #include "xfs_log.h"
-
+#include "xfs_symlink_remote.h"
 
 /*
  * Each contiguous block has a header, so it is not just a simple pathlen
diff --git a/fs/xfs/libxfs/xfs_symlink_remote.h b/fs/xfs/libxfs/xfs_symlink_remote.h
new file mode 100644 (file)
index 0000000..c6f621a
--- /dev/null
@@ -0,0 +1,22 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Copyright (c) 2000-2005 Silicon Graphics, Inc.
+ * Copyright (c) 2013 Red Hat, Inc.
+ * All Rights Reserved.
+ */
+#ifndef __XFS_SYMLINK_REMOTE_H
+#define __XFS_SYMLINK_REMOTE_H
+
+/*
+ * Symlink decoding/encoding functions
+ */
+int xfs_symlink_blocks(struct xfs_mount *mp, int pathlen);
+int xfs_symlink_hdr_set(struct xfs_mount *mp, xfs_ino_t ino, uint32_t offset,
+                       uint32_t size, struct xfs_buf *bp);
+bool xfs_symlink_hdr_ok(xfs_ino_t ino, uint32_t offset,
+                       uint32_t size, struct xfs_buf *bp);
+void xfs_symlink_local_to_remote(struct xfs_trans *tp, struct xfs_buf *bp,
+                                struct xfs_inode *ip, struct xfs_ifork *ifp);
+xfs_failaddr_t xfs_symlink_shortform_verify(void *sfp, int64_t size);
+
+#endif /* __XFS_SYMLINK_REMOTE_H */
index 7e859c412a5b2e1df609840d46eb9226922909c0..eab380e95ef407748deb9202f973c1bf91c77ba0 100644 (file)
@@ -37,6 +37,7 @@
 #include "xfs_attr_leaf.h"
 #include "xfs_log_priv.h"
 #include "xfs_health.h"
+#include "xfs_symlink_remote.h"
 #include "scrub/xfs_scrub.h"
 #include "scrub/scrub.h"
 #include "scrub/common.h"
index ddff86713df3530eb86849921ca947f307fbb5b4..31df0866f2eea521b9b9c5fa68149213d412a9f1 100644 (file)
@@ -13,6 +13,7 @@
 #include "xfs_inode.h"
 #include "xfs_symlink.h"
 #include "xfs_health.h"
+#include "xfs_symlink_remote.h"
 #include "scrub/scrub.h"
 #include "scrub/common.h"
 #include "scrub/health.h"
index fb8c57b9d13d6b5c8ab5111c3ab444f2a5224adf..38f569d3f47ad21934697c06e3f38f052d30048a 100644 (file)
@@ -24,6 +24,7 @@
 #include "xfs_ialloc.h"
 #include "xfs_error.h"
 #include "xfs_health.h"
+#include "xfs_symlink_remote.h"
 
 /* ----- Kernel only functions below ----- */
 int