Make sure we do libaio engine compatability names
authorJens Axboe <axboe@kernel.dk>
Mon, 9 Nov 2020 18:47:50 +0000 (11:47 -0700)
committerJens Axboe <axboe@kernel.dk>
Mon, 9 Nov 2020 18:47:50 +0000 (11:47 -0700)
This goes for both the dynamic engines, and the builtin ones. If
'aio' or 'linuxaio' is used, we want 'libaio'.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
ioengines.c

index c688dd1d359238a4011e2979ba6ed08a24ad3234..5ac512ae05c6c07c1a4daacc126b7bc56ddb9280 100644 (file)
@@ -112,6 +112,10 @@ static struct ioengine_ops *dlopen_ioengine(struct thread_data *td,
        struct ioengine_ops *ops;
        void *dlhandle;
 
+       if (!strncmp(engine_lib, "linuxaio", 8) ||
+           !strncmp(engine_lib, "aio", 3))
+               engine_lib = "libaio";
+
        dprint(FD_IO, "dload engine %s\n", engine_lib);
 
        dlerror();
@@ -160,7 +164,7 @@ static struct ioengine_ops *__load_ioengine(const char *engine)
        /*
         * linux libaio has alias names, so convert to what we want
         */
-       if (!strncmp(engine, "linuxaio", 8)) {
+       if (!strncmp(engine, "linuxaio", 8) || !strncmp(engine, "aio", 3)) {
                dprint(FD_IO, "converting ioengine name: %s -> libaio\n",
                       engine);
                engine = "libaio";