aboutsummaryrefslogtreecommitdiff
path: root/hw/9pfs/cofs.c
diff options
context:
space:
mode:
authorVenkateswararao Jujjuri <jvrao@linux.vnet.ibm.com>2011-08-08 23:48:29 +0530
committerAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>2011-08-08 23:48:29 +0530
commitb4b1537b96fc57b50a676006868ab97093d040c8 (patch)
tree757d1e74bd4ba2d87636dd7f51f4eb1b454d20c2 /hw/9pfs/cofs.c
parente84861f75e3bb6473cd8576870f3f4cac334d423 (diff)
hw/9pfs: Add yield support for remove
Signed-off-by: Venkateswararao Jujjuri <jvrao@linux.vnet.ibm.com> Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Diffstat (limited to 'hw/9pfs/cofs.c')
-rw-r--r--hw/9pfs/cofs.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/hw/9pfs/cofs.c b/hw/9pfs/cofs.c
index 6fcedd8400..8fbfe7359f 100644
--- a/hw/9pfs/cofs.c
+++ b/hw/9pfs/cofs.c
@@ -141,3 +141,17 @@ int v9fs_co_mknod(V9fsState *s, V9fsString *path, uid_t uid,
});
return err;
}
+
+int v9fs_co_remove(V9fsState *s, V9fsString *path)
+{
+ int err;
+
+ v9fs_co_run_in_worker(
+ {
+ err = s->ops->remove(&s->ctx, path->data);
+ if (err < 0) {
+ err = -errno;
+ }
+ });
+ return err;
+}