diff options
author | Christoph Hellwig <hch@lst.de> | 2023-12-11 17:37:28 +0100 |
---|---|---|
committer | Carlos Maiolino <cem@kernel.org> | 2023-12-18 14:57:48 +0100 |
commit | cf9162582c9e1abacb1cc24a10a9b8bd166d0a0c (patch) | |
tree | c5dcdbdd519a5186ae84044371a2bd48de638773 | |
parent | c42edb2e8d23e8ab491a15a5aa991f6c952ce474 (diff) | |
download | xfsprogs-dev-cf9162582c9e1abacb1cc24a10a9b8bd166d0a0c.tar.gz |
libxlog: remove the global libxfs_xinit x structure
There is no need to export a libxfs_xinit with the somewhat unsuitable
name x from libxlog. Move it into the tools linking against libxlog
that actually need it.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Carlos Maiolino <cmaiolino@redhat.com>
Signed-off-by: Carlos Maiolino <cem@kernel.org>
-rw-r--r-- | db/init.c | 1 | ||||
-rw-r--r-- | include/libxlog.h | 3 | ||||
-rw-r--r-- | libxlog/util.c | 1 | ||||
-rw-r--r-- | logprint/logprint.c | 1 | ||||
-rw-r--r-- | repair/globals.h | 2 | ||||
-rw-r--r-- | repair/init.c | 2 |
6 files changed, 6 insertions, 4 deletions
@@ -27,6 +27,7 @@ static struct xfs_mount xmount; struct xfs_mount *mp; static struct xlog xlog; xfs_agnumber_t cur_agno = NULLAGNUMBER; +libxfs_init_t x; static void usage(void) diff --git a/include/libxlog.h b/include/libxlog.h index 57f39e4e82..3948c0b8d1 100644 --- a/include/libxlog.h +++ b/include/libxlog.h @@ -68,9 +68,6 @@ extern int print_exit; extern int print_skip_uuid; extern int print_record_header; -/* libxfs parameters */ -extern libxfs_init_t x; - void xlog_init(struct xfs_mount *mp, struct xlog *log); int xlog_is_dirty(struct xfs_mount *mp, struct xlog *log); diff --git a/libxlog/util.c b/libxlog/util.c index d1377c2e2b..6e21f1a895 100644 --- a/libxlog/util.c +++ b/libxlog/util.c @@ -10,7 +10,6 @@ int print_exit; int print_skip_uuid; int print_record_header; -libxfs_init_t x; void xlog_init( diff --git a/logprint/logprint.c b/logprint/logprint.c index bcdb6b359a..1a096fa799 100644 --- a/logprint/logprint.c +++ b/logprint/logprint.c @@ -25,6 +25,7 @@ int print_overwrite; int print_no_data; int print_no_print; static int print_operation = OP_PRINT; +static struct libxfs_xinit x; static void usage(void) diff --git a/repair/globals.h b/repair/globals.h index b65e4a2d09..f2952d8b47 100644 --- a/repair/globals.h +++ b/repair/globals.h @@ -169,4 +169,6 @@ extern int thread_count; /* If nonzero, simulate failure after this phase. */ extern int fail_after_phase; +extern libxfs_init_t x; + #endif /* _XFS_REPAIR_GLOBAL_H */ diff --git a/repair/init.c b/repair/init.c index 6d019b393f..6e3548b32e 100644 --- a/repair/init.c +++ b/repair/init.c @@ -18,6 +18,8 @@ #include "libfrog/dahashselftest.h" #include <sys/resource.h> +struct libxfs_xinit x; + static void ts_create(void) { |