+static void store_ipo(struct thread_data *td, unsigned long long offset,
+ unsigned int bytes, int rw)
+{
+ struct io_piece *ipo = malloc(sizeof(*ipo));
+
+ memset(ipo, 0, sizeof(*ipo));
+ INIT_LIST_HEAD(&ipo->list);
+ ipo->offset = offset;
+ ipo->len = bytes;
+ if (rw)
+ ipo->ddir = DDIR_WRITE;
+ else
+ ipo->ddir = DDIR_READ;
+
+ list_add_tail(&ipo->list, &td->io_log_list);
+}
+