summaryrefslogtreecommitdiff
path: root/source3/include/vfs.h
diff options
context:
space:
mode:
authorGerald Carter <jerry@samba.org>2002-09-25 15:19:00 +0000
committerGerald Carter <jerry@samba.org>2002-09-25 15:19:00 +0000
commita834a73e341059be154426390304a42e4a011f72 (patch)
tree7f53b0f7819238e0ee0396daccf5d924cb9b8d29 /source3/include/vfs.h
parent115a39775cb923d026dde58633b6ba6aef3a1943 (diff)
downloadsamba-a834a73e341059be154426390304a42e4a011f72.tar.gz
samba-a834a73e341059be154426390304a42e4a011f72.tar.bz2
samba-a834a73e341059be154426390304a42e4a011f72.zip
sync'ing up for 3.0alpha20 release
(This used to be commit 65e7b5273bb58802bf0c389b77f7fcae0a1f6139)
Diffstat (limited to 'source3/include/vfs.h')
-rw-r--r--source3/include/vfs.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/source3/include/vfs.h b/source3/include/vfs.h
index 1b1a13d7c1..9a06764371 100644
--- a/source3/include/vfs.h
+++ b/source3/include/vfs.h
@@ -44,17 +44,18 @@
/* Changed to version 2 for CIFS UNIX extensions (mknod and link added). JRA. */
/* Changed to version 3 for POSIX acl extensions. JRA. */
/* Changed to version 4 for cascaded VFS interface. Alexander Bokovoy. */
+/* Changed to version 5 for sendfile addition. JRA. */
#define SMB_VFS_INTERFACE_VERSION 5
/* Version of supported cascaded interface backward copmatibility.
- (version 4 corresponds to SMB_VFS_INTERFACE_VERSION 4)
+ (version 5 corresponds to SMB_VFS_INTERFACE_VERSION 5)
It is used in vfs_init_custom() to detect VFS modules which conform to cascaded
VFS interface but implement elder version than current version of Samba uses.
This allows to use old modules with new VFS interface as far as combined VFS operation
set is coherent (will be in most cases).
*/
-#define SMB_VFS_INTERFACE_CASCADED 4
+#define SMB_VFS_INTERFACE_CASCADED 5
/*
Each VFS module must provide following global functions:
@@ -116,6 +117,7 @@ struct vfs_ops {
ssize_t (*read)(struct files_struct *fsp, int fd, void *data, size_t n);
ssize_t (*write)(struct files_struct *fsp, int fd, const void *data, size_t n);
SMB_OFF_T (*lseek)(struct files_struct *fsp, int filedes, SMB_OFF_T offset, int whence);
+ ssize_t (*sendfile)(int tofd, files_struct *fsp, int fromfd, const DATA_BLOB *header, SMB_OFF_T offset, size_t count);
int (*rename)(struct connection_struct *conn, const char *old, const char *new);
int (*fsync)(struct files_struct *fsp, int fd);
int (*stat)(struct connection_struct *conn, const char *fname, SMB_STRUCT_STAT *sbuf);
@@ -210,6 +212,7 @@ typedef enum _vfs_op_type {
SMB_VFS_OP_READ,
SMB_VFS_OP_WRITE,
SMB_VFS_OP_LSEEK,
+ SMB_VFS_OP_SENDFILE,
SMB_VFS_OP_RENAME,
SMB_VFS_OP_FSYNC,
SMB_VFS_OP_STAT,