Michael S. Tsirkin
2017-Apr-07 05:50 UTC
[PATCH 3/3] ptr_ring: support testing different batching sizes
Use the param flag for that. Signed-off-by: Michael S. Tsirkin <mst at redhat.com> --- tools/virtio/ringtest/ptr_ring.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/virtio/ringtest/ptr_ring.c b/tools/virtio/ringtest/ptr_ring.c index 635b07b..7b22f1b 100644 --- a/tools/virtio/ringtest/ptr_ring.c +++ b/tools/virtio/ringtest/ptr_ring.c @@ -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 */ -- MST