aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/linux-2.6/xfs_trace.h
diff options
context:
space:
mode:
authorDave Chinner <dchinner@redhat.com>2010-12-20 20:28:39 -0500
committerDave Chinner <david@fromorbit.com>2010-12-20 20:28:39 -0500
commit1c3cb9ec07fabf0c0970adc46fd2a1f09c1186dd (patch)
treeb8b6bf968f663723b06aa68ec499e49f3cdfbad0 /fs/xfs/linux-2.6/xfs_trace.h
parent84f3c683c4d3f36d3c3ed320babd960a332ac458 (diff)
xfs: convert l_tail_lsn to an atomic variable.
log->l_tail_lsn is currently protected by the log grant lock. The lock is only needed for serialising readers against writers, so we don't really need the lock if we make the l_tail_lsn variable an atomic. Converting the l_tail_lsn variable to an atomic64_t means we can start to peel back the grant lock from various operations. Also, provide functions to safely crack an atomic LSN variable into it's component pieces and to recombined the components into an atomic variable. Use them where appropriate. This also removes the need for explicitly holding a spinlock to read the l_tail_lsn on 32 bit platforms. Signed-off-by: Dave Chinner <dchinner@redhat.com>
Diffstat (limited to 'fs/xfs/linux-2.6/xfs_trace.h')
-rw-r--r--fs/xfs/linux-2.6/xfs_trace.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/xfs/linux-2.6/xfs_trace.h b/fs/xfs/linux-2.6/xfs_trace.h
index 3ff6b35f9207..b180e1bf8257 100644
--- a/fs/xfs/linux-2.6/xfs_trace.h
+++ b/fs/xfs/linux-2.6/xfs_trace.h
@@ -794,7 +794,7 @@ DECLARE_EVENT_CLASS(xfs_loggrant_class,
794 &__entry->grant_write_bytes); 794 &__entry->grant_write_bytes);
795 __entry->curr_cycle = log->l_curr_cycle; 795 __entry->curr_cycle = log->l_curr_cycle;
796 __entry->curr_block = log->l_curr_block; 796 __entry->curr_block = log->l_curr_block;
797 __entry->tail_lsn = log->l_tail_lsn; 797 __entry->tail_lsn = atomic64_read(&log->l_tail_lsn);
798 ), 798 ),
799 TP_printk("dev %d:%d type %s t_ocnt %u t_cnt %u t_curr_res %u " 799 TP_printk("dev %d:%d type %s t_ocnt %u t_cnt %u t_curr_res %u "
800 "t_unit_res %u t_flags %s reserveq %s " 800 "t_unit_res %u t_flags %s reserveq %s "