cluster-devel.redhat.com archive mirror
 help / color / mirror / Atom feed
* [Cluster-devel] [GFS2 PATCH] GFS2: eliminate i_generation from memory
@ 2011-03-23 13:37 Bob Peterson
  2011-03-23 13:50 ` Steven Whitehouse
  0 siblings, 1 reply; 4+ messages in thread
From: Bob Peterson @ 2011-03-23 13:37 UTC (permalink / raw)
  To: cluster-devel.redhat.com

Hi,

Since GFS2 doesn't rely upon generation numbers like GFS1, we do not
need to copy the generation number into memory and out of memory.
This patch eliminates the variable from the in-core structure and
will reduce the memory requirements of GFS2.

Regards,

Bob Peterson
Red Hat File Systems

Signed-off-by: Bob Peterson <rpeterso@redhat.com> 
--
diff --git a/fs/gfs2/incore.h b/fs/gfs2/incore.h
index 870a89d..2329296 100644
--- a/fs/gfs2/incore.h
+++ b/fs/gfs2/incore.h
@@ -272,7 +272,6 @@ struct gfs2_inode {
 	struct inode i_inode;
 	u64 i_no_addr;
 	u64 i_no_formal_ino;
-	u64 i_generation;
 	u64 i_eattr;
 	unsigned long i_flags;		/* GIF_... */
 	struct gfs2_glock *i_gl; /* Move into i_gh? */
diff --git a/fs/gfs2/inode.c b/fs/gfs2/inode.c
index 97d54a2..b4e416a 100644
--- a/fs/gfs2/inode.c
+++ b/fs/gfs2/inode.c
@@ -261,7 +261,6 @@ static int gfs2_dinode_in(struct gfs2_inode *ip, const void *buf)
 	ip->i_inode.i_ctime.tv_nsec = be32_to_cpu(str->di_ctime_nsec);
 
 	ip->i_goal = be64_to_cpu(str->di_goal_meta);
-	ip->i_generation = be64_to_cpu(str->di_generation);
 
 	ip->i_diskflags = be32_to_cpu(str->di_flags);
 	gfs2_set_inode_flags(&ip->i_inode);
@@ -626,7 +625,6 @@ static void init_dinode(struct gfs2_inode *dip, struct gfs2_glock *gl,
 	di->di_major = cpu_to_be32(MAJOR(dev));
 	di->di_minor = cpu_to_be32(MINOR(dev));
 	di->di_goal_meta = di->di_goal_data = cpu_to_be64(inum->no_addr);
-	di->di_generation = cpu_to_be64(*generation);
 	di->di_flags = 0;
 
 	if (S_ISREG(mode)) {
@@ -944,7 +942,6 @@ void gfs2_dinode_out(const struct gfs2_inode *ip, void *buf)
 
 	str->di_goal_meta = cpu_to_be64(ip->i_goal);
 	str->di_goal_data = cpu_to_be64(ip->i_goal);
-	str->di_generation = cpu_to_be64(ip->i_generation);
 
 	str->di_flags = cpu_to_be32(ip->i_diskflags);
 	str->di_height = cpu_to_be16(ip->i_height);



^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-03-23 14:04 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-23 13:37 [Cluster-devel] [GFS2 PATCH] GFS2: eliminate i_generation from memory Bob Peterson
2011-03-23 13:50 ` Steven Whitehouse
2011-03-23 13:55   ` Bob Peterson
2011-03-23 14:04     ` Steven Whitehouse

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).