From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NiahO-0004nr-FN for qemu-devel@nongnu.org; Fri, 19 Feb 2010 16:47:46 -0500 Received: from [199.232.76.173] (port=43096 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NiahN-0004mi-LL for qemu-devel@nongnu.org; Fri, 19 Feb 2010 16:47:45 -0500 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NiahM-0007DJ-0E for qemu-devel@nongnu.org; Fri, 19 Feb 2010 16:47:45 -0500 Received: from mail-gx0-f213.google.com ([209.85.217.213]:53831) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NiahL-0007DB-Nd for qemu-devel@nongnu.org; Fri, 19 Feb 2010 16:47:43 -0500 Received: by gxk5 with SMTP id 5so327314gxk.16 for ; Fri, 19 Feb 2010 13:47:43 -0800 (PST) Message-ID: <4B7F06FD.4090403@codemonkey.ws> Date: Fri, 19 Feb 2010 15:47:41 -0600 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH] virtio-serial: pci: Allow MSI to be disabled References: <1265980958-28265-1-git-send-email-amit.shah@redhat.com> In-Reply-To: <1265980958-28265-1-git-send-email-amit.shah@redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Amit Shah Cc: qemu-devel@nongnu.org, "Michael S. Tsirkin" On 02/12/2010 07:22 AM, Amit Shah wrote: > Michael noted we don't allow disabling of MSI for the virtio-serial-pci > device. Fix that. > > Signed-off-by: Amit Shah > CC: "Michael S. Tsirkin" > Applied. Thanks. Regards, Anthony Liguori > --- > hw/virtio-pci.c | 6 +++--- > 1 files changed, 3 insertions(+), 3 deletions(-) > > diff --git a/hw/virtio-pci.c b/hw/virtio-pci.c > index f3373ae..bcd40f7 100644 > --- a/hw/virtio-pci.c > +++ b/hw/virtio-pci.c > @@ -500,8 +500,8 @@ static int virtio_serial_init_pci(PCIDevice *pci_dev) > if (!vdev) { > return -1; > } > - vdev->nvectors = proxy->nvectors ? proxy->nvectors > - : proxy->max_virtserial_ports + 1; > + vdev->nvectors = proxy->nvectors == -1 ? proxy->max_virtserial_ports + 1 > + : proxy->nvectors; > virtio_init_pci(proxy, vdev, > PCI_VENDOR_ID_REDHAT_QUMRANET, > PCI_DEVICE_ID_VIRTIO_CONSOLE, > @@ -585,7 +585,7 @@ static PCIDeviceInfo virtio_info[] = { > .init = virtio_serial_init_pci, > .exit = virtio_exit_pci, > .qdev.props = (Property[]) { > - DEFINE_PROP_UINT32("vectors", VirtIOPCIProxy, nvectors, 0), > + DEFINE_PROP_UINT32("vectors", VirtIOPCIProxy, nvectors, -1), > DEFINE_PROP_HEX32("class", VirtIOPCIProxy, class_code, 0), > DEFINE_VIRTIO_COMMON_FEATURES(VirtIOPCIProxy, host_features), > DEFINE_PROP_UINT32("max_ports", VirtIOPCIProxy, max_virtserial_ports, >