Skip to content

Commit

Permalink
ptr_ring: support testing different batching sizes
Browse files Browse the repository at this point in the history
Use the param flag for that.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
  • Loading branch information
Michael S. Tsirkin committed May 9, 2017
1 parent a497950 commit 3008a20
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tools/virtio/ringtest/ptr_ring.c
Original file line number Diff line number Diff line change
@@ -97,6 +97,9 @@ void alloc_ring(void)
{
int ret = ptr_ring_init(&array, ring_size, 0);
assert(!ret);
/* Hacky way to poke at ring internals. Useful for testing though. */
if (param)
array.batch = param;
}

/* guest side */

0 comments on commit 3008a20

Please sign in to comment.