summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
b4ba5f3)
It was a little all-over-the-place, unify it - return -1 for error,
let the caller look at errno for the specific error.
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
ret = ioctl(f->fd, SG_IO, hdr);
if (ret < 0)
ret = ioctl(f->fd, SG_IO, hdr);
if (ret < 0)
return FIO_Q_COMPLETED;
}
return FIO_Q_COMPLETED;
}
ret = write(f->fd, hdr, sizeof(*hdr));
if (ret < 0)
ret = write(f->fd, hdr, sizeof(*hdr));
if (ret < 0)
if (sync) {
ret = read(f->fd, hdr, sizeof(*hdr));
if (ret < 0)
if (sync) {
ret = read(f->fd, hdr, sizeof(*hdr));
if (ret < 0)
return FIO_Q_COMPLETED;
}
return FIO_Q_COMPLETED;
}