From acf8cc3a2283d209337ba9f5da6b03396daac359 Mon Sep 17 00:00:00 2001 From: Sunil Kumar Acharya Date: Wed, 17 May 2017 14:35:41 +0530 Subject: cluster/ec: Implement FALLOCATE FOP for EC FALLOCATE file operations is not implemented in the existing EC code. This change set implements it for EC. BUG: 1448293 Change-Id: Id9ed914db984c327c16878a5b2304a0ea461b623 Signed-off-by: Sunil Kumar Acharya Reviewed-on: https://review.gluster.org/15200 Smoke: Gluster Build System NetBSD-regression: NetBSD Build System Reviewed-by: Pranith Kumar Karampuri CentOS-regression: Gluster Build System --- libglusterfs/src/compat.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'libglusterfs') diff --git a/libglusterfs/src/compat.h b/libglusterfs/src/compat.h index fbaac76b9ee..f4da4b2a0de 100644 --- a/libglusterfs/src/compat.h +++ b/libglusterfs/src/compat.h @@ -59,6 +59,12 @@ #ifndef FALLOC_FL_ZERO_RANGE #define FALLOC_FL_ZERO_RANGE 0x10 /* zeroes out range */ #endif +#ifndef FALLOC_FL_COLLAPSE_RANGE +#define FALLOC_FL_COLLAPSE_RANGE 0x08 /* reduces the size */ +#endif +#ifndef FALLOC_FL_INSERT_RANGE +#define FALLOC_FL_INSERT_RANGE 0x20 /* expands the size */ +#endif #ifndef HAVE_LLISTXATTR @@ -177,6 +183,8 @@ enum { #define FALLOC_FL_KEEP_SIZE 0x01 /* default is extend size */ #define FALLOC_FL_PUNCH_HOLE 0x02 /* de-allocates range */ #define FALLOC_FL_ZERO_RANGE 0x10 /* zeroes out range */ +#define FALLOC_FL_INSERT_RANGE 0x20 /* Expands the size */ +#define FALLOC_FL_COLLAPSE_RANGE 0x08 /* Reduces the size */ #ifndef _PATH_UMOUNT #define _PATH_UMOUNT "/sbin/umount" -- cgit