From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nick Piggin Subject: Re: [PATCH 4/4] remove inode_setattr Date: Tue, 1 Jun 2010 00:04:12 +1000 Message-ID: <20100531140412.GJ9453@laptop> References: <20100531093954.GA9946@lst.de> <20100531094030.GD10001@lst.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: viro@zeniv.linux.org.uk, jack@suse.cz, linux-fsdevel@vger.kernel.org To: Christoph Hellwig Return-path: Received: from cantor2.suse.de ([195.135.220.15]:40585 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755264Ab0EaOES (ORCPT ); Mon, 31 May 2010 10:04:18 -0400 Content-Disposition: inline In-Reply-To: <20100531094030.GD10001@lst.de> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Mon, May 31, 2010 at 11:40:30AM +0200, Christoph Hellwig wrote: > Replace inode_setattr with opencoded variants of it in all callers. This > moves the remaining call to vmtruncate into the filesystem methods where it > can be replaced with the proper truncate sequence. > > In a few cases it was obvious that we would never end up calling vmtruncate > so it was left out in the opencoded variant: > > spufs: explicitly checks for ATTR_SIZE earlier > btrfs,hugetlbfs,logfs,dlmfs: explicitly clears ATTR_SIZE earlier > ufs: contains an opencoded simple_seattr + truncate that sets the filesize just above > > In addition to that ncpfs called inode_setattr with handcrafted iattrs, > which allowed to trim down the opencoded variant. The series all looks pretty good, ends up being quite a lot cleaner in the core code. This last patch is a question of a bit of churn and duplicated code with the result of cleaner core code, and more explicitly putting vmtruncate in the hands of the fs maintainers. I have a bunch of fs conversions (several from you) I was going to send to maintainers, they'll clash a bit. I'll see what ends up being merged in 2.6.35 and try to fix up what I've got.