aboutsummaryrefslogtreecommitdiff
path: root/qemu-img.c
diff options
context:
space:
mode:
Diffstat (limited to 'qemu-img.c')
-rw-r--r--qemu-img.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/qemu-img.c b/qemu-img.c
index 6233b8ca56..2b4562b9d9 100644
--- a/qemu-img.c
+++ b/qemu-img.c
@@ -4187,7 +4187,8 @@ static int img_bench(int argc, char **argv)
{"force-share", no_argument, 0, 'U'},
{0, 0, 0, 0}
};
- c = getopt_long(argc, argv, ":hc:d:f:no:qs:S:t:wU", long_options, NULL);
+ c = getopt_long(argc, argv, ":hc:d:f:ni:o:qs:S:t:wU", long_options,
+ NULL);
if (c == -1) {
break;
}
@@ -4230,6 +4231,14 @@ static int img_bench(int argc, char **argv)
case 'n':
flags |= BDRV_O_NATIVE_AIO;
break;
+ case 'i':
+ ret = bdrv_parse_aio(optarg, &flags);
+ if (ret < 0) {
+ error_report("Invalid aio option: %s", optarg);
+ ret = -1;
+ goto out;
+ }
+ break;
case 'o':
{
offset = cvtnum(optarg);