struct timespec *t)
{
struct libaio_data *ld = td->io_data;
- int r;
+ long r;
do {
r = io_getevents(ld->aio_ctx, min, max, ld->aio_events, t);
break;
} while (1);
- return r;
+ return (int) r;
}
static int fio_libaio_queue(struct thread_data *td, struct io_u *io_u)
{
struct libaio_data *ld = td->io_data;
struct iocb *iocb = &io_u->iocb;
- int ret;
+ long ret;
do {
ret = io_submit(ld->aio_ctx, 1, &iocb);
break;
} while (1);
- return ret;
+ return (int) ret;
}
int nr_blocks, lba;
if (io_u->buflen & (sd->bs - 1)) {
- fprintf(f_err, "read/write not sector aligned\n");
+ log_err("read/write not sector aligned\n");
return EINVAL;
}
if (ret)
return ret;
} else {
- fprintf(f_err, "ioengine sgio only works on block devices\n");
+ log_err("ioengine sgio only works on block devices\n");
return 1;
}