summaryrefslogtreecommitdiffstats
path: root/fs/xfs/libxfs/xfs_ag.h
diff options
context:
space:
mode:
authorDave Chinner <dchinner@redhat.com>2018-05-13 23:10:08 -0700
committerDarrick J. Wong <darrick.wong@oracle.com>2018-05-15 18:12:51 -0700
commitb16817b66b6c97d2a812d663d26faed40079892a (patch)
tree6198b72f72902e2db460aecad7a7bf404462f357 /fs/xfs/libxfs/xfs_ag.h
parent8125147288db7008c872a946210028bbf6c0af86 (diff)
downloadlinux-b16817b66b6c97d2a812d663d26faed40079892a.tar.gz
linux-b16817b66b6c97d2a812d663d26faed40079892a.tar.bz2
linux-b16817b66b6c97d2a812d663d26faed40079892a.zip
xfs: move growfs core to libxfs
So it can be shared with userspace (e.g. mkfs) easily. Signed-Off-By: Dave Chinner <dchinner@redhat.com> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Diffstat (limited to 'fs/xfs/libxfs/xfs_ag.h')
-rw-r--r--fs/xfs/libxfs/xfs_ag.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/fs/xfs/libxfs/xfs_ag.h b/fs/xfs/libxfs/xfs_ag.h
new file mode 100644
index 000000000000..69f2fd4be0ea
--- /dev/null
+++ b/fs/xfs/libxfs/xfs_ag.h
@@ -0,0 +1,25 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+/*
+ * Copyright (c) 2018 Red Hat, Inc.
+ * All rights reserved.
+ */
+
+#ifndef __LIBXFS_AG_H
+#define __LIBXFS_AG_H 1
+
+struct aghdr_init_data {
+ /* per ag data */
+ xfs_agblock_t agno; /* ag to init */
+ xfs_extlen_t agsize; /* new AG size */
+ struct list_head buffer_list; /* buffer writeback list */
+ xfs_rfsblock_t nfree; /* cumulative new free space */
+
+ /* per header data */
+ xfs_daddr_t daddr; /* header location */
+ size_t numblks; /* size of header */
+ xfs_btnum_t type; /* type of btree root block */
+};
+
+int xfs_ag_init_headers( struct xfs_mount *mp, struct aghdr_init_data *id);
+
+#endif /* __LIBXFS_AG_H */