[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <AANLkTikduxunBSq0z6BuXJVHXJMzeTUfexz2H71_J6BR@mail.gmail.com>
Date: Tue, 1 Mar 2011 15:52:15 +0200
From: Amir Goldstein <amir73il@...il.com>
To: Theodore Tso <tytso@....edu>
Cc: Ext4 Developers List <linux-ext4@...r.kernel.org>
Subject: [PATCH 1/2] add the b_cow_tid field to journal_head struct
The field is used by ext4 snapshots code to store the transaction id
in which the buffer was last cowed.
Merging this patch to kernel 2.6.39, will allow users to test ext4
snapshots as a standalone module, without the need to patch and
install a development kernel.
On a 64bit machine the field is using an aliged memory padding space
and does not increase the size of the struct.
On a 32bit machine this patch increases the size of the struct from
60 to 64 bytes:
Before:
jbd2_journal_head 57 126 60 63 1 : tunables 120 60
0 : slabdata 2 2 0
After:
jbd2_journal_head 61 118 64 59 1 : tunables 120 60
0 : slabdata 2 2 0
Signed-off-by: Amir Goldstein <amir73il@...rs.sf.net>
---
include/linux/journal-head.h | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/include/linux/journal-head.h b/include/linux/journal-head.h
index 525aac3..44e95d0 100644
--- a/include/linux/journal-head.h
+++ b/include/linux/journal-head.h
@@ -41,6 +41,13 @@ struct journal_head {
unsigned b_modified;
/*
+ * This feild tracks the last transaction id in which this buffer
+ * has been cowed
+ * [jbd_lock_bh_state()]
+ */
+ unsigned b_cow_tid;
+
+ /*
* Copy of the buffer data frozen for writing to the log.
* [jbd_lock_bh_state()]
*/
--
1.7.0.4
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists