* [PATCH] reiser4: don't capture superblock at sync_fs()
@ 2016-08-08 19:34 Edward Shishkin
0 siblings, 0 replies; only message in thread
From: Edward Shishkin @ 2016-08-08 19:34 UTC (permalink / raw)
To: ReiserFS development mailing list
[-- Attachment #1: Type: text/plain, Size: 1 bytes --]
[-- Attachment #2: reiser4-dont-capture-superblock.patch --]
[-- Type: text/x-patch, Size: 1349 bytes --]
Don't capture superblock at ->sync_fs().
Signed-off-by: Edward Shishkin <edward.shishkin@gmail.com>
---
fs/reiser4/super_ops.c | 15 +++++++--------
1 file changed, 7 insertions(+), 8 deletions(-)
--- a/fs/reiser4/super_ops.c
+++ b/fs/reiser4/super_ops.c
@@ -401,7 +401,6 @@ static long reiser4_writeback_inodes(str
/* ->sync_fs() of super operations */
static int reiser4_sync_fs(struct super_block *super, int wait)
{
- int ret;
reiser4_context *ctx;
struct bdi_writeback *wb;
struct wb_writeback_work work = {
@@ -424,14 +423,14 @@ static int reiser4_sync_fs(struct super_
return PTR_ERR(ctx);
}
/*
- * Capture znode associated with super block
+ * We don't capture superblock here.
+ * Superblock is captured only by operations, which change
+ * its fields different from free_blocks, nr_files, next_oid.
+ * After system crash the mentioned fields are recovered from
+ * journal records, see reiser4_journal_recover_sb_data().
+ * Also superblock is captured at final commit when releasing
+ * disk format.
*/
- ret = reiser4_capture_super_block(super);
- if (ret != 0)
- warning("vs-1701",
- "reiser4_capture_super_block failed in write_super: %d",
- ret);
-
wb = &inode_to_bdi(reiser4_get_super_fake(super))->wb;
spin_lock(&wb->list_lock);
generic_writeback_sb_inodes(super, wb, &wbc, &work, true);
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2016-08-08 19:34 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-08 19:34 [PATCH] reiser4: don't capture superblock at sync_fs() Edward Shishkin
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.