mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 19:21:31 -04:00
[9p] Introduce client side TFSYNC/RFSYNC for dotl.
SYNOPSIS
size[4] Tfsync tag[2] fid[4]
size[4] Rfsync tag[2]
DESCRIPTION
The Tfsync transaction transfers ("flushes") all modified in-core data of
file identified by fid to the disk device (or other permanent storage
device) where that file resides.
Signed-off-by: Venkateswararao Jujjuri <[email protected]>
Signed-off-by: Eric Van Hensbergen <[email protected]>
This commit is contained in:
parent
b04faaf371
commit
920e65dc69
4 changed files with 44 additions and 2 deletions
|
|
@ -290,6 +290,20 @@ static int v9fs_file_fsync(struct file *filp, int datasync)
|
|||
return retval;
|
||||
}
|
||||
|
||||
static int v9fs_file_fsync_dotl(struct file *filp, int datasync)
|
||||
{
|
||||
struct p9_fid *fid;
|
||||
int retval;
|
||||
|
||||
P9_DPRINTK(P9_DEBUG_VFS, "v9fs_file_fsync_dotl: filp %p datasync %x\n",
|
||||
filp, datasync);
|
||||
|
||||
fid = filp->private_data;
|
||||
|
||||
retval = p9_client_fsync(fid);
|
||||
return retval;
|
||||
}
|
||||
|
||||
static const struct file_operations v9fs_cached_file_operations = {
|
||||
.llseek = generic_file_llseek,
|
||||
.read = do_sync_read,
|
||||
|
|
@ -311,7 +325,7 @@ static const struct file_operations v9fs_cached_file_operations_dotl = {
|
|||
.release = v9fs_dir_release,
|
||||
.lock = v9fs_file_lock,
|
||||
.mmap = generic_file_readonly_mmap,
|
||||
.fsync = v9fs_file_fsync,
|
||||
.fsync = v9fs_file_fsync_dotl,
|
||||
};
|
||||
|
||||
const struct file_operations v9fs_file_operations = {
|
||||
|
|
@ -333,5 +347,5 @@ const struct file_operations v9fs_file_operations_dotl = {
|
|||
.release = v9fs_dir_release,
|
||||
.lock = v9fs_file_lock,
|
||||
.mmap = generic_file_readonly_mmap,
|
||||
.fsync = v9fs_file_fsync,
|
||||
.fsync = v9fs_file_fsync_dotl,
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in a new issue