ioengines: improve "is this the same IO engine" check
authorJens Axboe <axboe@kernel.dk>
Fri, 15 Dec 2017 16:08:26 +0000 (09:08 -0700)
committerJens Axboe <axboe@kernel.dk>
Fri, 15 Dec 2017 16:08:26 +0000 (09:08 -0700)
commit3e262e2fc8e73bae1340aef23a78195b5de82387
treeed6f3de73db02b235c056427a8c58b829addd48c
parentc26438ad4a14ece7784c6952694d8984ce32bc1c
ioengines: improve "is this the same IO engine" check

We can't just compare the name, that assumes that name and filename
match for an IO engine. While that's generally the case for the
engines that fio ships with, it's not a requirement, and it's
definitely not true for external engines.

Fixup the check by re-loading the engine and checking the OPS
instead. That should be bullet proof.

Fixes: 800334d ("Correctly detect whether ioengine_load can exit early")
Signed-off-by: Jens Axboe <axboe@kernel.dk>
init.c