From: mlarkin Date: Tue, 30 May 2017 13:13:47 +0000 (+0000) Subject: increase vmd(8) virtio queue size from 64 to 128. Also fix an old X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=4fedf95290225263d6e73550d54e403ec80e094d;p=openbsd increase vmd(8) virtio queue size from 64 to 128. Also fix an old copypaste bug that didn't hurt us as long as all the queue sizes were the same, which was the case up to now. suggested by sf@, ok krw@ --- diff --git a/usr.sbin/vmd/virtio.c b/usr.sbin/vmd/virtio.c index 14525cf2c45..38469c49ddc 100644 --- a/usr.sbin/vmd/virtio.c +++ b/usr.sbin/vmd/virtio.c @@ -1,4 +1,4 @@ -/* $OpenBSD: virtio.c,v 1.47 2017/05/27 23:58:16 tedu Exp $ */ +/* $OpenBSD: virtio.c,v 1.48 2017/05/30 13:13:47 mlarkin Exp $ */ /* * Copyright (c) 2015 Mike Larkin @@ -1668,7 +1668,7 @@ virtio_init(struct vmd_vm *vm, int *child_disks, int *child_taps) } vioblk[i].vq[0].qs = VIOBLK_QUEUE_SIZE; vioblk[i].vq[0].vq_availoffset = - sizeof(struct vring_desc) * VIORND_QUEUE_SIZE; + sizeof(struct vring_desc) * VIOBLK_QUEUE_SIZE; vioblk[i].vq[0].vq_usedoffset = VIRTQUEUE_ALIGN( sizeof(struct vring_desc) * VIOBLK_QUEUE_SIZE + sizeof(uint16_t) * (2 + VIOBLK_QUEUE_SIZE)); diff --git a/usr.sbin/vmd/virtio.h b/usr.sbin/vmd/virtio.h index d996bc38d03..cc31e28a432 100644 --- a/usr.sbin/vmd/virtio.h +++ b/usr.sbin/vmd/virtio.h @@ -1,4 +1,4 @@ -/* $OpenBSD: virtio.h,v 1.17 2017/05/08 09:08:40 reyk Exp $ */ +/* $OpenBSD: virtio.h,v 1.18 2017/05/30 13:13:47 mlarkin Exp $ */ /* * Copyright (c) 2015 Mike Larkin @@ -25,10 +25,10 @@ #define VIORND_QUEUE_SIZE 64 #define VIORND_QUEUE_MASK (VIORND_QUEUE_SIZE - 1) -#define VIOBLK_QUEUE_SIZE 64 +#define VIOBLK_QUEUE_SIZE 128 #define VIOBLK_QUEUE_MASK (VIOBLK_QUEUE_SIZE - 1) -#define VIONET_QUEUE_SIZE 64 +#define VIONET_QUEUE_SIZE 128 #define VIONET_QUEUE_MASK (VIONET_QUEUE_SIZE - 1) /* VMM Control Interface shutdown timeout (in seconds) */