[Cluster-devel] [PATCH 33/66] libgfs2: Mark buffer modified adding a new GFS1 block

rpeterso at redhat.com rpeterso at redhat.com
Fri Jan 20 15:10:14 UTC 2012


From: Bob Peterson <rpeterso at redhat.com>

When adding new blocks to the file system for GFS1, function
gfs1_lookup_block was not marking the buffer and dinode buffer
as modified like gfs2_lookup_block does.  This patch fixes that.

rhbz#675723
---
 gfs2/libgfs2/gfs1.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/gfs2/libgfs2/gfs1.c b/gfs2/libgfs2/gfs1.c
index 2bdf57f..59eaa8d 100644
--- a/gfs2/libgfs2/gfs1.c
+++ b/gfs2/libgfs2/gfs1.c
@@ -54,7 +54,9 @@ void gfs1_lookup_block(struct gfs2_inode *ip, struct gfs2_buffer_head *bh,
 		*block = meta_alloc(ip);
 
 	*ptr = cpu_to_be64(*block);
+	bmodified(bh);
 	ip->i_di.di_blocks++;
+	bmodified(ip->i_bh);
 
 	*new = 1;
 }
-- 
1.7.7.5




More information about the Cluster-devel mailing list