X-Git-Url: https://git.kernel.dk/?p=fio.git;a=blobdiff_plain;f=engines%2Fnull.c;h=e7df6a134d479c5ab370f496044619b18f6b15d2;hp=9f9d8500b0516d393b756a10d1be5f9f19f00c59;hb=5c57c084346fbfe6f3f45236c151ad1c83b6b398;hpb=46a674786944e964517dd652fbf41807c9395cc4 diff --git a/engines/null.c b/engines/null.c index 9f9d8500..e7df6a13 100644 --- a/engines/null.c +++ b/engines/null.c @@ -119,7 +119,7 @@ static struct ioengine_ops ioengine = { .init = fio_null_init, .cleanup = fio_null_cleanup, .open_file = fio_null_open, - .flags = FIO_DISKLESSIO, + .flags = FIO_DISKLESSIO | FIO_FAKEIO, }; static void fio_init fio_null_register(void) @@ -136,8 +136,10 @@ static void fio_exit fio_null_unregister(void) #ifdef FIO_EXTERNAL_ENGINE extern "C" { -void get_ioengine(struct ioengine_ops **ioengine_ptr) { +void get_ioengine(struct ioengine_ops **ioengine_ptr) +{ struct ioengine_ops *ioengine; + *ioengine_ptr = (struct ioengine_ops *) malloc(sizeof(struct ioengine_ops)); ioengine = *ioengine_ptr; @@ -150,7 +152,7 @@ void get_ioengine(struct ioengine_ops **ioengine_ptr) { ioengine->init = fio_null_init; ioengine->cleanup = fio_null_cleanup; ioengine->open_file = fio_null_open; - ioengine->flags = FIO_DISKLESSIO; + ioengine->flags = FIO_DISKLESSIO | FIO_FAKEIO; } } #endif /* FIO_EXTERNAL_ENGINE */