From 079e8efb3ef7e5491cd28b10857dd14b58b380d6 Mon Sep 17 00:00:00 2001 From: "Darrick J. Wong" Date: Mon, 26 Feb 2018 22:43:17 -0600 Subject: [PATCH] xfs: trace log reservations at mount time Source kernel commit: b872af2c8700e9d64af8e13811b7679ede26ca00 At each mount, emit the transaction reservation type information via tracepoints. This makes it easier to compare the log reservation info calculated by the kernel and xfsprogs so that we can more easily diagnose minimum log size failures on freshly formatted filesystems. Signed-off-by: Darrick J. Wong Reviewed-by: Brian Foster Signed-off-by: Eric Sandeen --- libxfs/xfs_log_rlimit.c | 2 +- libxfs/xfs_shared.h | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/libxfs/xfs_log_rlimit.c b/libxfs/xfs_log_rlimit.c index 9264afa92..be1e98953 100644 --- a/libxfs/xfs_log_rlimit.c +++ b/libxfs/xfs_log_rlimit.c @@ -55,7 +55,7 @@ xfs_log_calc_max_attrsetm_res( * the maximum one in terms of the pre-calculated values which were done * at mount time. */ -STATIC void +void xfs_log_get_max_trans_res( struct xfs_mount *mp, struct xfs_trans_res *max_resp) diff --git a/libxfs/xfs_shared.h b/libxfs/xfs_shared.h index 67ccb1ab4..d0b84da0c 100644 --- a/libxfs/xfs_shared.h +++ b/libxfs/xfs_shared.h @@ -76,6 +76,9 @@ struct xfs_log_item_desc { int xfs_log_calc_unit_res(struct xfs_mount *mp, int unit_bytes); int xfs_log_calc_minimum_size(struct xfs_mount *); +struct xfs_trans_res; +void xfs_log_get_max_trans_res(struct xfs_mount *mp, + struct xfs_trans_res *max_resp); /* * Values for t_flags. -- 2.47.2