aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_trans_ail.c
diff options
context:
space:
mode:
authorDave Chinner <dchinner@redhat.com>2013-11-01 00:27:18 -0400
committerBen Myers <bpm@sgi.com>2013-11-06 13:41:51 -0500
commit750b9c90668b173a92b20e747b9736b8537eda5a (patch)
tree2927a0bd0072fc35c2436e62d4f720ea381bc5fa /fs/xfs/xfs_trans_ail.c
parent273203699f82667296e1f14344c5a5a6c4600470 (diff)
xfs: trace AIL manipulations
I debugging a log tail issue on a RHEL6 kernel, I added these trace points to trace log items being added, moved and removed in the AIL and how that affected the log tail LSN that was written to the log. They were very helpful in that they immediately identified the cause of the problem being seen. Hence I'd like to always have them available for use. Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Ben Myers <bpm@sgi.com>
Diffstat (limited to 'fs/xfs/xfs_trans_ail.c')
-rw-r--r--fs/xfs/xfs_trans_ail.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/xfs/xfs_trans_ail.c b/fs/xfs/xfs_trans_ail.c
index 4b47cfebd25b..a7287354e535 100644
--- a/fs/xfs/xfs_trans_ail.c
+++ b/fs/xfs/xfs_trans_ail.c
@@ -659,11 +659,13 @@ xfs_trans_ail_update_bulk(
659 if (XFS_LSN_CMP(lsn, lip->li_lsn) <= 0) 659 if (XFS_LSN_CMP(lsn, lip->li_lsn) <= 0)
660 continue; 660 continue;
661 661
662 trace_xfs_ail_move(lip, lip->li_lsn, lsn);
662 xfs_ail_delete(ailp, lip); 663 xfs_ail_delete(ailp, lip);
663 if (mlip == lip) 664 if (mlip == lip)
664 mlip_changed = 1; 665 mlip_changed = 1;
665 } else { 666 } else {
666 lip->li_flags |= XFS_LI_IN_AIL; 667 lip->li_flags |= XFS_LI_IN_AIL;
668 trace_xfs_ail_insert(lip, 0, lsn);
667 } 669 }
668 lip->li_lsn = lsn; 670 lip->li_lsn = lsn;
669 list_add(&lip->li_ail, &tmp); 671 list_add(&lip->li_ail, &tmp);
@@ -732,6 +734,7 @@ xfs_trans_ail_delete_bulk(
732 return; 734 return;
733 } 735 }
734 736
737 trace_xfs_ail_delete(lip, mlip->li_lsn, lip->li_lsn);
735 xfs_ail_delete(ailp, lip); 738 xfs_ail_delete(ailp, lip);
736 lip->li_flags &= ~XFS_LI_IN_AIL; 739 lip->li_flags &= ~XFS_LI_IN_AIL;
737 lip->li_lsn = 0; 740 lip->li_lsn = 0;