[PATCH v2] fuse: Allow page aligned writes

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

 



Read/writes IOs should be page aligned as fuse server
might need to copy data to another buffer otherwise in
order to fulfill network or device storage requirements.

Simple reproducer is with libfuse, example/passthrough*
and opening a file with O_DIRECT - without this change
writing to that file failed with -EINVAL if the underlying
file system was requiring alignment.

Required server side changes:
Server needs to seek to the next page, without splice that is
just page size buffer alignment, with splice another splice
syscall is needed to seek over the unaligned area.

Signed-off-by: Bernd Schubert <bschubert@xxxxxxx>

---

Changes since v1:
- Fuse client does not send the alignment offset anymore in the write
  header.
- Use FOPEN_ALIGNED_WRITES to be filled in by FUSE_OPEN and FUSE_CREATE
  instead of a FUSE_INIT flag to allow control per file and to safe
  init flags.
- Instead of seeking a fixed offset, fuse_copy_align() just seeks to the
  next page.
- Added sanity checks in fuse_copy_align().

libfuse patch:
https://github.com/libfuse/libfuse/pull/983


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

  Powered by Linux