Re: [PATCH] direct-io: allow direct writes to empty inodes

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

 



On Fri, Oct 26, 2018 at 08:29:00AM -0600, Jens Axboe wrote:
> On 10/26/18 3:30 AM, Jan Kara wrote:
> > On Mon 08-10-18 20:58:23, Ernesto A. Fernández wrote:
> >> On a DIO_SKIP_HOLES filesystem, the ->get_block() method is currently
> >> not allowed to create blocks for an empty inode.  This confusion comes
> >> from trying to bit shift a negative number, so check the size of the
> >> inode first.
> >>
> >> The problem is most visible for hfsplus, because the fallback to
> >> buffered I/O doesn't happen and the write fails with EIO.  This is in
> >> part the fault of the module, because it gives a wrong return value on
> >> ->get_block(); that will be fixed in a separate patch.
> >>
> >> Signed-off-by: Ernesto A. Fernández <ernesto.mnd.fernandez@xxxxxxxxx>
> > 
> > Good catch. The patch looks good. You can add:
> > 
> > Reviewed-by: Jan Kara <jack@xxxxxxx>
> > 
> > Also Jens often picks up patches for direct IO code so added him to CC.
> > Jens?
> 
> Looks good to me. Ernesto, did you run this through xfstests as well?

I only ran the quick tests for ext2.  Also for hfsplus, but those are not
very meaningful because too many are failing.

> 
> -- 
> Jens Axboe
> 



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux