diff options
author | Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> | 2011-08-02 11:36:17 +0530 |
---|---|---|
committer | Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> | 2011-09-22 21:38:52 +0530 |
commit | bccacf6c7920ee46ec4063c4bd9469eb3ec4e253 (patch) | |
tree | 928b32819cdf3dcb69afab2ad602dfbbeaa186ea /hw/9pfs/coxattr.c | |
parent | ce421a19612aaf0d25dede4bad3ea205587c9dae (diff) | |
download | qemu-bccacf6c7920ee46ec4063c4bd9469eb3ec4e253.zip qemu-bccacf6c7920ee46ec4063c4bd9469eb3ec4e253.tar.gz qemu-bccacf6c7920ee46ec4063c4bd9469eb3ec4e253.tar.bz2 |
hw/9pfs: Implement TFLUSH operation
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Diffstat (limited to 'hw/9pfs/coxattr.c')
-rw-r--r-- | hw/9pfs/coxattr.c | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/hw/9pfs/coxattr.c b/hw/9pfs/coxattr.c index dd2e4a5..8a48228 100644 --- a/hw/9pfs/coxattr.c +++ b/hw/9pfs/coxattr.c @@ -17,10 +17,14 @@ #include "qemu-coroutine.h" #include "virtio-9p-coth.h" -int v9fs_co_llistxattr(V9fsState *s, V9fsPath *path, void *value, size_t size) +int v9fs_co_llistxattr(V9fsPDU *pdu, V9fsPath *path, void *value, size_t size) { int err; + V9fsState *s = pdu->s; + if (v9fs_request_cancelled(pdu)) { + return -EINTR; + } v9fs_path_read_lock(s); v9fs_co_run_in_worker( { @@ -33,12 +37,16 @@ int v9fs_co_llistxattr(V9fsState *s, V9fsPath *path, void *value, size_t size) return err; } -int v9fs_co_lgetxattr(V9fsState *s, V9fsPath *path, +int v9fs_co_lgetxattr(V9fsPDU *pdu, V9fsPath *path, V9fsString *xattr_name, void *value, size_t size) { int err; + V9fsState *s = pdu->s; + if (v9fs_request_cancelled(pdu)) { + return -EINTR; + } v9fs_path_read_lock(s); v9fs_co_run_in_worker( { @@ -53,12 +61,16 @@ int v9fs_co_lgetxattr(V9fsState *s, V9fsPath *path, return err; } -int v9fs_co_lsetxattr(V9fsState *s, V9fsPath *path, +int v9fs_co_lsetxattr(V9fsPDU *pdu, V9fsPath *path, V9fsString *xattr_name, void *value, size_t size, int flags) { int err; + V9fsState *s = pdu->s; + if (v9fs_request_cancelled(pdu)) { + return -EINTR; + } v9fs_path_read_lock(s); v9fs_co_run_in_worker( { @@ -73,11 +85,15 @@ int v9fs_co_lsetxattr(V9fsState *s, V9fsPath *path, return err; } -int v9fs_co_lremovexattr(V9fsState *s, V9fsPath *path, +int v9fs_co_lremovexattr(V9fsPDU *pdu, V9fsPath *path, V9fsString *xattr_name) { int err; + V9fsState *s = pdu->s; + if (v9fs_request_cancelled(pdu)) { + return -EINTR; + } v9fs_path_read_lock(s); v9fs_co_run_in_worker( { |