Whamcloud - gitweb
LU-4388 io: pass fsync() range through RPC/IO stack 26/8626/15
authorAndreas Dilger <andreas.dilger@intel.com>
Thu, 19 Dec 2013 20:11:09 +0000 (13:11 -0700)
committerOleg Drokin <oleg.drokin@intel.com>
Thu, 24 Apr 2014 03:58:57 +0000 (03:58 +0000)
commit806bce67b7dcd9060620cfbcddfb6435a02ef42a
tree7d9c4ea845d412e1ad4876b895eedbfcebcc036c
parente81235969430cd05feb10eb59d00f93448c7c0d9
LU-4388 io: pass fsync() range through RPC/IO stack

The Linux VFS and Lustre OST_SYNC RPC are both capable of specifying
fsync() on a sub-extent of the file {start, end} instead of the full
file.  This allows less than the full amount of data to be flushed,
reducing or possibly eliminating the work needed before the syscall
can return.

However, the handling of sub-extent of the file for fsync was lost
with the move to CLIO on the client and OSD API on the server.  They
were ignoring the passed {start, end} and using {0, OBD_OBJECT_EOF}
instead.

Return the ability to pass a sub-extent for fsync() from the client,
to the specific stripes/OSTs that need the sync operation, and pass
it down to the OSD.  The ZFS OSD doesn't handle this yet, but there
is room for improvement in a separate patch.

Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: Id2c3ab7ab5283cdeece6b4986ab2dfbfb03ebbe5
Reviewed-on: http://review.whamcloud.com/8626
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
13 files changed:
libcfs/include/libcfs/darwin/darwin-fs.h
libcfs/include/libcfs/linux/linux-fs.h
libcfs/libcfs/tracefile.c
libcfs/libcfs/winnt/winnt-fs.c
lustre/include/dt_object.h
lustre/include/lu_target.h
lustre/llite/file.c
lustre/lod/lod_object.c
lustre/mdd/mdd_object.c
lustre/ofd/ofd_dev.c
lustre/osd-ldiskfs/osd_handler.c
lustre/osd-zfs/osd_object.c
lustre/target/tgt_handler.c