linux-user: fix ppc target_stat64 st_blocks layout
[qemu] / block / cow.c
index 41d292a..a70854e 100644 (file)
@@ -258,12 +258,20 @@ static int cow_create(const char *filename, QEMUOptionParameter *options)
 static void cow_flush(BlockDriverState *bs)
 {
     BDRVCowState *s = bs->opaque;
-    fsync(s->fd);
+    qemu_fdatasync(s->fd);
 }
 
 static QEMUOptionParameter cow_create_options[] = {
-    { BLOCK_OPT_SIZE,           OPT_SIZE },
-    { BLOCK_OPT_BACKING_FILE,   OPT_STRING },
+    {
+        .name = BLOCK_OPT_SIZE,
+        .type = OPT_SIZE,
+        .help = "Virtual disk size"
+    },
+    {
+        .name = BLOCK_OPT_BACKING_FILE,
+        .type = OPT_STRING,
+        .help = "File name of a base image"
+    },
     { NULL }
 };