Direct IO write at end of file error
PATCH 1/1 Direct IO write at end of file error
Hi,
This patch fixes a problem whereby a direct_io write doesn't fall back to buffered write properly at end of file.
Regards,
Bob Peterson
--
fs/gfs2/ops_address.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
fs/gfs2/ops_address.c +1 -1
@@ -975,7 +975,7 @@ static int gfs2_ok_for_dio(struct gfs2_inode *ip, int rw, loff_t offset)if (gfs2_is_stuffed (ip))return 0 ; -if (offset >i_size_read (&ip->i_inode)) +if (offset >=i_size_read (&ip->i_inode))return 0 ;return 1 ; }
PATCH 1/1 Direct IO write at end of file error
Hi,
Well spotted. Applied, thanks,
Steve.
Quoted 26 lines · Bob Peterson
Hi,
This patch fixes a problem whereby a
direct_iowrite doesn't fall back to buffered write properly at end of file.Regards,
Bob Peterson
--fs/gfs2/ops_address.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)fs/gfs2/ops_address.c +1
-1@@ -975,7 +975,7 @@ static int gfs2_ok_for_dio(struct gfs2_inode *ip, int rw, loff_t offset)if (gfs2_is_stuffed (ip))return 0 ; -if (offset >i_size_read (&ip->i_inode)) +if (offset >=i_size_read (&ip->i_inode))return 0 ;return 1 ; }