BLKREPORTZONE may fail because of a variety of reasons. Log both the return code and errno when this ioctl fails. Signed-off-by: Dmitry Fomichev <dmitry.fomichev@xxxxxxx> --- oslib/linux-blkzoned.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/oslib/linux-blkzoned.c b/oslib/linux-blkzoned.c index 2c3ecf33..1cc8d288 100644 --- a/oslib/linux-blkzoned.c +++ b/oslib/linux-blkzoned.c @@ -242,6 +242,8 @@ int blkzoned_report_zones(struct thread_data *td, struct fio_file *f, hdr->sector = offset >> 9; ret = ioctl(fd, BLKREPORTZONE, hdr); if (ret) { + log_err("%s: BLKREPORTZONE ioctl failed, ret=%d, err=%d.\n", + f->file_name, ret, -errno); ret = -errno; goto out; } -- 2.37.3