From: Jens Axboe Date: Fri, 24 Sep 2010 17:36:34 +0000 (+0200) Subject: Don't add the file offset twice for trim X-Git-Tag: fio-1.44-rc1~1 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=c6404a44d139fb494202f9d968f7affe8c3d986f;p=fio.git Don't add the file offset twice for trim We added it when storing the io_piece, don't add it again when calling trim. Signed-off-by: Jens Axboe --- diff --git a/ioengines.c b/ioengines.c index 7df0abac..e0b0f22e 100644 --- a/ioengines.c +++ b/ioengines.c @@ -489,7 +489,7 @@ int do_io_u_trim(struct thread_data *td, struct io_u *io_u) struct fio_file *f = io_u->file; int ret; - ret = os_trim(f->fd, io_u->offset + f->file_offset, io_u->xfer_buflen); + ret = os_trim(f->fd, io_u->offset, io_u->xfer_buflen); if (!ret) return io_u->xfer_buflen;;