From patchwork Fri Aug 27 22:37:45 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Williamson X-Patchwork-Id: 139001 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id o7RMbrKo006618 for ; Fri, 27 Aug 2010 22:37:53 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753796Ab0H0Whv (ORCPT ); Fri, 27 Aug 2010 18:37:51 -0400 Received: from mx1.redhat.com ([209.132.183.28]:25012 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753773Ab0H0Whv (ORCPT ); Fri, 27 Aug 2010 18:37:51 -0400 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o7RMbncx032502 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 27 Aug 2010 18:37:49 -0400 Received: from s20.home (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o7RMbkLw031129; Fri, 27 Aug 2010 18:37:47 -0400 From: Alex Williamson Subject: [PATCH 5/5] virtio-net: Switch default to new bottom half TX handler for iothread To: qemu-devel@nongnu.org Cc: kvm@vger.kernel.org, anthony@codemonkey.ws, jes.sorensen@redhat.com, alex.williamson@redhat.com Date: Fri, 27 Aug 2010 16:37:45 -0600 Message-ID: <20100827223745.2696.18845.stgit@s20.home> In-Reply-To: <20100827223659.2696.3589.stgit@s20.home> References: <20100827223659.2696.3589.stgit@s20.home> User-Agent: StGIT/0.14.3 MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.67 on 10.5.11.12 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Fri, 27 Aug 2010 22:37:53 +0000 (UTC) diff --git a/hw/s390-virtio-bus.c b/hw/s390-virtio-bus.c index 1483362..985f99a 100644 --- a/hw/s390-virtio-bus.c +++ b/hw/s390-virtio-bus.c @@ -328,7 +328,8 @@ static VirtIOS390DeviceInfo s390_virtio_net = { .qdev.size = sizeof(VirtIOS390Device), .qdev.props = (Property[]) { DEFINE_NIC_PROPERTIES(VirtIOS390Device, nic), - DEFINE_PROP_UINT32("txtimer", VirtIOS390Device, txtimer, 1), + DEFINE_PROP_UINT32("txtimer", VirtIOS390Device, txtimer, + TXTIMER_DEFAULT), DEFINE_PROP_INT32("txburst", VirtIOS390Device, txburst, 256), DEFINE_PROP_END_OF_LIST(), }, diff --git a/hw/syborg_virtio.c b/hw/syborg_virtio.c index 7b76972..ee5746d 100644 --- a/hw/syborg_virtio.c +++ b/hw/syborg_virtio.c @@ -300,7 +300,8 @@ static SysBusDeviceInfo syborg_virtio_net_info = { .qdev.props = (Property[]) { DEFINE_NIC_PROPERTIES(SyborgVirtIOProxy, nic), DEFINE_VIRTIO_NET_FEATURES(SyborgVirtIOProxy, host_features), - DEFINE_PROP_UINT32("txtimer", SyborgVirtIOProxy, txtimer, 1), + DEFINE_PROP_UINT32("txtimer", SyborgVirtIOProxy, txtimer, + TXTIMER_DEFAULT), DEFINE_PROP_INT32("txburst", SyborgVirtIOProxy, txburst, 256), DEFINE_PROP_END_OF_LIST(), } diff --git a/hw/virtio-pci.c b/hw/virtio-pci.c index e025c09..9740f57 100644 --- a/hw/virtio-pci.c +++ b/hw/virtio-pci.c @@ -695,7 +695,8 @@ static PCIDeviceInfo virtio_info[] = { DEFINE_PROP_UINT32("vectors", VirtIOPCIProxy, nvectors, 3), DEFINE_VIRTIO_NET_FEATURES(VirtIOPCIProxy, host_features), DEFINE_NIC_PROPERTIES(VirtIOPCIProxy, nic), - DEFINE_PROP_UINT32("txtimer", VirtIOPCIProxy, txtimer, 1), + DEFINE_PROP_UINT32("txtimer", VirtIOPCIProxy, txtimer, + TXTIMER_DEFAULT), DEFINE_PROP_INT32("txburst", VirtIOPCIProxy, txburst, 256), DEFINE_PROP_END_OF_LIST(), }, diff --git a/hw/virtio.h b/hw/virtio.h index 4051889..a1a17a2 100644 --- a/hw/virtio.h +++ b/hw/virtio.h @@ -183,6 +183,12 @@ void virtio_update_irq(VirtIODevice *vdev); void virtio_bind_device(VirtIODevice *vdev, const VirtIOBindings *binding, void *opaque); +#ifdef CONFIG_IOTHREAD + #define TXTIMER_DEFAULT 0 +#else + #define TXTIMER_DEFAULT 1 +#endif + /* Base devices. */ VirtIODevice *virtio_blk_init(DeviceState *dev, BlockConf *conf); VirtIODevice *virtio_net_init(DeviceState *dev, NICConf *conf,