summaryrefslogtreecommitdiffstats
path: root/fs/hostfs/hostfs_user.c
diff options
context:
space:
mode:
authorJeff Garzik <jgarzik@pobox.com>2005-08-17 00:51:31 -0400
committerJeff Garzik <jgarzik@pobox.com>2005-08-17 00:51:31 -0400
commita2e30e529a48ef4e106e405f91cf4ae525bb01c4 (patch)
tree2def96ef17c0672c30f1a10287552978bf1d0b1c /fs/hostfs/hostfs_user.c
parentedb3366703224d5d8df573ae698ccd6b488dc743 (diff)
parent2ad56496627630ebc99f06af5f81ca23e17e014e (diff)
downloadtalos-op-linux-a2e30e529a48ef4e106e405f91cf4ae525bb01c4.tar.gz
talos-op-linux-a2e30e529a48ef4e106e405f91cf4ae525bb01c4.zip
Merge /spare/repo/linux-2.6/
Diffstat (limited to 'fs/hostfs/hostfs_user.c')
-rw-r--r--fs/hostfs/hostfs_user.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/fs/hostfs/hostfs_user.c b/fs/hostfs/hostfs_user.c
index 4796e8490f7d..b97809deba66 100644
--- a/fs/hostfs/hostfs_user.c
+++ b/fs/hostfs/hostfs_user.c
@@ -153,10 +153,24 @@ int lseek_file(int fd, long long offset, int whence)
int ret;
ret = lseek64(fd, offset, whence);
- if(ret < 0) return(-errno);
+ if(ret < 0)
+ return(-errno);
return(0);
}
+int fsync_file(int fd, int datasync)
+{
+ int ret;
+ if (datasync)
+ ret = fdatasync(fd);
+ else
+ ret = fsync(fd);
+
+ if (ret < 0)
+ return -errno;
+ return 0;
+}
+
void close_file(void *stream)
{
close(*((int *) stream));
OpenPOWER on IntegriCloud