public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] fs: remove s_old_blocksize from struct super_block
@ 2005-12-02 21:20 Pekka Enberg
  2005-12-02 21:44 ` Pekka Enberg
  2005-12-03 11:02 ` Anton Altaparmakov
  0 siblings, 2 replies; 7+ messages in thread
From: Pekka Enberg @ 2005-12-02 21:20 UTC (permalink / raw)
  To: akpm; +Cc: linux-kernel

Hi,

The s_old_blocksize field of struct super_block is only used as a temporary
variable in get_sb_bdev(). This patch changes the function to use a local
variable instead so we can kill the field from struct super_block.

Signed-off-by: Pekka Enberg <penberg@cs.helsinki.fi>
---

 fs/super.c         |    5 +++--
 include/linux/fs.h |    1 -
 2 files changed, 3 insertions(+), 3 deletions(-)

Index: 2.6/fs/super.c
===================================================================
--- 2.6.orig/fs/super.c
+++ 2.6/fs/super.c
@@ -707,11 +707,12 @@ struct super_block *get_sb_bdev(struct f
 		goto out;
 	} else {
 		char b[BDEVNAME_SIZE];
+		unsigned long old_blocksize;
 
 		s->s_flags = flags;
 		strlcpy(s->s_id, bdevname(bdev, b), sizeof(s->s_id));
-		s->s_old_blocksize = block_size(bdev);
-		sb_set_blocksize(s, s->s_old_blocksize);
+		old_blocksize = block_size(bdev);
+		sb_set_blocksize(s, old_blocksize);
 		error = fill_super(s, data, flags & MS_VERBOSE ? 1 : 0);
 		if (error) {
 			up_write(&s->s_umount);
Index: 2.6/include/linux/fs.h
===================================================================
--- 2.6.orig/include/linux/fs.h
+++ 2.6/include/linux/fs.h
@@ -777,7 +777,6 @@ struct super_block {
 	struct list_head	s_list;		/* Keep this first */
 	dev_t			s_dev;		/* search index; _not_ kdev_t */
 	unsigned long		s_blocksize;
-	unsigned long		s_old_blocksize;
 	unsigned char		s_blocksize_bits;
 	unsigned char		s_dirt;
 	unsigned long long	s_maxbytes;	/* Max file size */



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

end of thread, other threads:[~2005-12-03 18:53 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-12-02 21:20 [PATCH] fs: remove s_old_blocksize from struct super_block Pekka Enberg
2005-12-02 21:44 ` Pekka Enberg
2005-12-03 11:02 ` Anton Altaparmakov
2005-12-03 11:34   ` Pekka Enberg
2005-12-03 14:34     ` Anton Altaparmakov
2005-12-03 17:42       ` Jeff Mahoney
2005-12-03 18:52       ` Linus Torvalds

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox