From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christoph Hellwig Subject: [PATCH 7/14] hfsplus: do not cache and write next_alloc Date: Fri, 1 Oct 2010 09:26:32 +0200 Message-ID: <20101001072632.GG27055@lst.de> References: <20101001072500.GA26972@lst.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: linux-fsdevel@vger.kernel.org To: viro@zeniv.linux.org.uk, zippel@linux-m68k.org Return-path: Received: from verein.lst.de ([213.95.11.210]:48977 "EHLO verein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750968Ab0JAH0u (ORCPT ); Fri, 1 Oct 2010 03:26:50 -0400 Content-Disposition: inline In-Reply-To: <20101001072500.GA26972@lst.de> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: We never look at it, nor change the next_alloc field in the superblock. So don't bother caching it or writing it out in hfsplus_sync_fs. Signed-off-by: Christoph Hellwig Index: linux-2.6/fs/hfsplus/hfsplus_fs.h =================================================================== --- linux-2.6.orig/fs/hfsplus/hfsplus_fs.h 2010-09-30 12:02:01.036782662 +0200 +++ linux-2.6/fs/hfsplus/hfsplus_fs.h 2010-09-30 12:07:31.414782662 +0200 @@ -129,7 +129,6 @@ struct hfsplus_sb_info { int alloc_blksz_shift; u32 total_blocks; u32 free_blocks; - u32 next_alloc; u32 next_cnid; u32 file_count; u32 folder_count; Index: linux-2.6/fs/hfsplus/super.c =================================================================== --- linux-2.6.orig/fs/hfsplus/super.c 2010-09-30 12:07:21.427782656 +0200 +++ linux-2.6/fs/hfsplus/super.c 2010-09-30 12:07:31.415782662 +0200 @@ -164,7 +164,6 @@ int hfsplus_sync_fs(struct super_block * sb->s_dirt = 0; vhdr->free_blocks = cpu_to_be32(sbi->free_blocks); - vhdr->next_alloc = cpu_to_be32(sbi->next_alloc); vhdr->next_cnid = cpu_to_be32(sbi->next_cnid); vhdr->folder_count = cpu_to_be32(sbi->folder_count); vhdr->file_count = cpu_to_be32(sbi->file_count); @@ -355,7 +354,6 @@ static int hfsplus_fill_super(struct sup } sbi->total_blocks = be32_to_cpu(vhdr->total_blocks); sbi->free_blocks = be32_to_cpu(vhdr->free_blocks); - sbi->next_alloc = be32_to_cpu(vhdr->next_alloc); sbi->next_cnid = be32_to_cpu(vhdr->next_cnid); sbi->file_count = be32_to_cpu(vhdr->file_count); sbi->folder_count = be32_to_cpu(vhdr->folder_count);