Tao Ma b80474b432 ocfs2: Use buffer IO if we are appending a file.
In ocfs2_file_aio_write, we will prevent direct io if
we find that we are appending(changing i_size) and call
generic_file_aio_write_nolock. But actually O_DIRECT flag
is there and this function will call generic_file_direct_write
eventually which will update i_size and leave di->i_size
alone. The bug is
http://oss.oracle.com/bugzilla/show_bug.cgi?id=1173.

So this patch let ocfs2_direct_IO returns 0 directly if we
are appending so that buffered write will be called and
di->i_size get updated successfully. And this is also
what we want in ocfs2_file_aio_write.

Signed-off-by: Tao Ma <tao.ma@oracle.com>
Signed-off-by: Joel Becker <joel.becker@oracle.com>
2009-09-23 01:54:49 -07:00
..
2009-03-31 23:00:26 -04:00
2009-01-05 08:34:20 -08:00
2009-09-22 20:09:36 -07:00
2009-09-22 20:09:36 -07:00
2009-07-21 15:47:55 -07:00
2009-04-03 11:39:16 -07:00
2009-09-23 01:54:47 -07:00
2009-04-21 16:31:20 -07:00
2009-09-22 20:09:37 -07:00
2009-09-22 20:09:51 -07:00
2009-01-22 13:15:54 +03:00
2008-10-13 13:57:57 -07:00
2008-10-13 13:57:57 -07:00
2009-09-22 20:09:26 -07:00
2009-09-22 20:09:51 -07:00
2009-09-22 20:09:51 -07:00
2009-09-22 20:09:51 -07:00
2009-05-09 10:49:40 -04:00
2009-09-22 20:09:49 -07:00
2009-09-22 20:09:49 -07:00