From mboxrd@z Thu Jan 1 00:00:00 1970 From: npiggin@suse.de Subject: [patch 31/41] With reiserfs no longer using the weird generic_cont_expand, remove it completely. Date: Fri, 25 May 2007 22:22:15 +1000 Message-ID: <20070524053157.992309000@linux.local0.net> References: <20070524052844.860329000@suse.de> Cc: linux-fsdevel@vger.kernel.org, Mark Fasheh To: Andrew Morton Return-path: Received: from ns1.suse.de ([195.135.220.2]:40172 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755462AbXEYMhX (ORCPT ); Fri, 25 May 2007 08:37:23 -0400 Content-Disposition: inline; filename=fs-remove-generic_cont_expand.patch Sender: linux-fsdevel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org Signed-off-by: Nick Piggin --- fs/buffer.c | 20 -------------------- include/linux/buffer_head.h | 1 - 2 files changed, 21 deletions(-) Index: linux-2.6/fs/buffer.c =================================================================== --- linux-2.6.orig/fs/buffer.c +++ linux-2.6/fs/buffer.c @@ -2189,25 +2189,6 @@ out: return err; } -int generic_cont_expand(struct inode *inode, loff_t size) -{ - unsigned int offset; - - offset = (size & (PAGE_CACHE_SIZE - 1)); /* Within page */ - - /* ugh. in prepare/commit_write, if from==to==start of block, we - * skip the prepare. make sure we never send an offset for the start - * of a block. - * XXX: actually, this should be handled in those filesystems by - * checking for the AOP_FLAG_CONT_EXPAND flag. - */ - if ((offset & (inode->i_sb->s_blocksize - 1)) == 0) { - /* caller must handle this extra byte. */ - size++; - } - return generic_cont_expand_simple(inode, size); -} - int cont_expand_zero(struct file *file, struct address_space *mapping, loff_t pos, loff_t *bytes) { @@ -3135,7 +3116,6 @@ EXPORT_SYMBOL(file_fsync); EXPORT_SYMBOL(fsync_bdev); EXPORT_SYMBOL(generic_block_bmap); EXPORT_SYMBOL(generic_commit_write); -EXPORT_SYMBOL(generic_cont_expand); EXPORT_SYMBOL(generic_cont_expand_simple); EXPORT_SYMBOL(init_buffer); EXPORT_SYMBOL(invalidate_bdev); Index: linux-2.6/include/linux/buffer_head.h =================================================================== --- linux-2.6.orig/include/linux/buffer_head.h +++ linux-2.6/include/linux/buffer_head.h @@ -217,7 +217,6 @@ int block_prepare_write(struct page*, un int cont_write_begin(struct file *, struct address_space *, loff_t, unsigned, unsigned, struct page **, void **, get_block_t *, loff_t *); -int generic_cont_expand(struct inode *inode, loff_t size); int generic_cont_expand_simple(struct inode *inode, loff_t size); int block_commit_write(struct page *page, unsigned from, unsigned to); void block_sync_page(struct page *); --