Skip to content

Commit

Permalink
fio: enable dataplacement(fdp) while replaying I/Os
Browse files Browse the repository at this point in the history
Add initialization and dataplacement logic to enable
dataplacement(fdp) while fio replays I/Os with read_iolog.

Signed-off-by: Hyunwoo Park <dshw.park@samsung.com>
  • Loading branch information
parkvibes committed May 23, 2024
1 parent d3bcdd3 commit 7456a87
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion iolog.c
Original file line number Diff line number Diff line change
Expand Up @@ -140,8 +140,13 @@ static int ipo_special(struct thread_data *td, struct io_piece *ipo)
break;
}
ret = td_io_open_file(td, f);
if (!ret)
if (!ret){
if (td->o.dp_type != FIO_DP_NONE) {
if (dp_init(td))
return false;
}
break;
}
td_verror(td, ret, "iolog open file");
return -1;
case FIO_LOG_CLOSE_FILE:
Expand Down Expand Up @@ -233,6 +238,9 @@ int read_iolog_get(struct thread_data *td, struct io_u *io_u)
usec_sleep(td, (ipo->delay - elapsed) * 1000);
}

if (td->o.dp_type != FIO_DP_NONE)
dp_fill_dspec_data(td, io_u);

free(ipo);

if (io_u->ddir != DDIR_WAIT)
Expand Down

0 comments on commit 7456a87

Please sign in to comment.