Re: [PATCH] Make non-journal fsync work properly.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2009-09-08 at 18:05 -0400, Theodore Tso wrote:
> On Tue, Sep 08, 2009 at 08:41:05AM -0700, Frank Mayhar wrote:
> > I needed to doublecheck before answering but I think I've covered that
> > angle.  Specifically, in ext4_write_inode the patch only calls
> > ext4_do_update_inode() if s_journal is NULL, otherwise it takes the
> > current path.
> > 
> > So I think your concern is covered by the current patch.  Can you take
> > another look and let me know if you agree?  Thanks.
> 
> It wasn't obvious from reading the diff, but after I applied the patch
> and looked more closely, you're right.  I'm still worried though that
> the code is a bit fragile.  At the very *least* the restriction that
> ext4_do_update_inode's do_sync flag should only be called when there
> is no journal needs to be explicitly documented.  Possibly we should
> have a BUG() check to enforce this restriction; although a comment
> before ext4_do_update_inode() is probably enough.

I agree that the code as-is is a bit fragile.  Commentary is good but it
would probably be better to enforce the journal/no journal distinction
in ext4_do_update_inode() itself.
-- 
Frank Mayhar <fmayhar@xxxxxxxxxx>
Google, Inc.

--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux