Re: ext2_discard_prealloc() called on each iput?

2007-05-30 Thread Jan Kara
On Tue 29-05-07 14:10:52, Mingming Cao wrote: > On Mon, 2007-05-28 at 18:04 +0200, Jan Kara wrote: > > On Wed 23-05-07 08:37:43, Theodore Tso wrote: > > > On Tue, May 22, 2007 at 06:11:27PM +0200, Jan Kara wrote: > > > > > > > > while fixing some problems with preallocation in UDF, I had a look

Re: ext2_discard_prealloc() called on each iput?

2007-05-29 Thread Mingming Cao
On Mon, 2007-05-28 at 18:04 +0200, Jan Kara wrote: > On Wed 23-05-07 08:37:43, Theodore Tso wrote: > > On Tue, May 22, 2007 at 06:11:27PM +0200, Jan Kara wrote: > > > > > > while fixing some problems with preallocation in UDF, I had a look how > > > ext2 solves similar problems. I found out that

Re: ext2_discard_prealloc() called on each iput?

2007-05-29 Thread Theodore Tso
On Tue, May 29, 2007 at 12:25:45PM +0200, Jan Kara wrote: > Fix a comment when ext2_release_file() is called. > > Signed-off-by: Jan Kara <[EMAIL PROTECTED]> Acked-by: "Theodore Ts'o" <[EMAIL PROTECTED]> > diff -rupX /home/jack/.kerndiffexclude linux-2.6.21/fs/ext2/file.c > linux-2.6.21-1-ext2_

Re: ext2_discard_prealloc() called on each iput?

2007-05-29 Thread Jan Kara
On Wed 23-05-07 08:37:43, Theodore Tso wrote: > > Also I found slightly misleading the comment at ext2_release_file(). > > As far as I understand the code it isn't when /all/ files are closed but > > rather when all fd's for given filp are closed. I.e. if you open the same > > file two times, ->r

Re: ext2_discard_prealloc() called on each iput?

2007-05-28 Thread Theodore Tso
On Mon, May 28, 2007 at 06:04:20PM +0200, Jan Kara wrote: > OK, but then you could move the code to drop_inode() which is called at > exactly that moment... I've been thinking more about it when fixing UDF. > Discarding prealloc at drop_inode() has the disadvantage that > symlinks/directories wil

Re: ext2_discard_prealloc() called on each iput?

2007-05-28 Thread Jan Kara
On Wed 23-05-07 08:37:43, Theodore Tso wrote: > On Tue, May 22, 2007 at 06:11:27PM +0200, Jan Kara wrote: > > > > while fixing some problems with preallocation in UDF, I had a look how > > ext2 solves similar problems. I found out that ext2_discard_prealloc() is > > called on every iput() from e

Re: ext2_discard_prealloc() called on each iput?

2007-05-23 Thread Theodore Tso
On Tue, May 22, 2007 at 06:11:27PM +0200, Jan Kara wrote: > > while fixing some problems with preallocation in UDF, I had a look how > ext2 solves similar problems. I found out that ext2_discard_prealloc() is > called on every iput() from ext2_put_inode(). Is it really appropriate? I > don't see

ext2_discard_prealloc() called on each iput?

2007-05-22 Thread Jan Kara
Hello, while fixing some problems with preallocation in UDF, I had a look how ext2 solves similar problems. I found out that ext2_discard_prealloc() is called on every iput() from ext2_put_inode(). Is it really appropriate? I don't see a reason for doing so... Also I found slightly misleadin