Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 180379
b: refs/heads/master
c: 7a4439c
h: refs/heads/master
i:
  180377: 5bc8bd9
  180375: 87345c3
v: v3
  • Loading branch information
M. Mohan Kumar authored and Eric Van Hensbergen committed Feb 8, 2010
1 parent 9be313e commit 7bedfb9
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 9d6939dac77102b09396ee0b89392ec7639612a7
refs/heads/master: 7a4439c406c21b1e900ed497cec1a79d05b38c07
1 change: 1 addition & 0 deletions trunk/fs/9p/v9fs_vfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,3 +60,4 @@ void v9fs_dentry_release(struct dentry *);
int v9fs_uflags2omode(int uflags, int extended);

ssize_t v9fs_file_readn(struct file *, char *, char __user *, u32, u64);
void v9fs_blank_wstat(struct p9_wstat *wstat);
19 changes: 19 additions & 0 deletions trunk/fs/9p/vfs_file.c
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,23 @@ v9fs_file_write(struct file *filp, const char __user * data,
return total;
}

static int v9fs_file_fsync(struct file *filp, struct dentry *dentry,
int datasync)
{
struct p9_fid *fid;
struct p9_wstat wstat;
int retval;

P9_DPRINTK(P9_DEBUG_VFS, "filp %p dentry %p datasync %x\n", filp,
dentry, datasync);

fid = filp->private_data;
v9fs_blank_wstat(&wstat);

retval = p9_client_wstat(fid, &wstat);
return retval;
}

static const struct file_operations v9fs_cached_file_operations = {
.llseek = generic_file_llseek,
.read = do_sync_read,
Expand All @@ -266,6 +283,7 @@ static const struct file_operations v9fs_cached_file_operations = {
.release = v9fs_dir_release,
.lock = v9fs_file_lock,
.mmap = generic_file_readonly_mmap,
.fsync = v9fs_file_fsync,
};

const struct file_operations v9fs_file_operations = {
Expand All @@ -276,4 +294,5 @@ const struct file_operations v9fs_file_operations = {
.release = v9fs_dir_release,
.lock = v9fs_file_lock,
.mmap = generic_file_readonly_mmap,
.fsync = v9fs_file_fsync,
};
2 changes: 1 addition & 1 deletion trunk/fs/9p/vfs_inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ int v9fs_uflags2omode(int uflags, int extended)
*
*/

static void
void
v9fs_blank_wstat(struct p9_wstat *wstat)
{
wstat->type = ~0;
Expand Down

0 comments on commit 7bedfb9

Please sign in to comment.