qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 22/28] virtio-serial: convert to QEMU Object Mod


From: Anthony Liguori
Subject: Re: [Qemu-devel] [PATCH 22/28] virtio-serial: convert to QEMU Object Model
Date: Tue, 24 Jan 2012 14:13:18 -0600
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.23) Gecko/20110922 Lightning/1.0b2 Thunderbird/3.1.15

On 01/24/2012 01:59 PM, Amit Shah wrote:
On (Tue) 24 Jan 2012 [13:33:14], Anthony Liguori wrote:

diff --git a/hw/virtio-serial-bus.c b/hw/virtio-serial-bus.c
index 982ffbf..edf54d7 100644
--- a/hw/virtio-serial-bus.c
+++ b/hw/virtio-serial-bus.c


@@ -157,7 +157,7 @@ static void do_flush_queued_data(VirtIOSerialPort *port, 
VirtQueue *vq,
              ssize_t ret;

              buf_size = port->elem.out_sg[i].iov_len - port->iov_offset;
-            ret = info->have_data(port,
+            ret = vsc->have_data(port,
                                    port->elem.out_sg[i].iov_base
                                    + port->iov_offset,
                                    buf_size);

Would be nice if everything was re-indented.

That'll need to be a follow-on.  This was mostly scripted.


@@ -176,7 +176,7 @@ static void do_flush_queued_data(VirtIOSerialPort *port, 
VirtQueue *vq,
                   * 1: chardevs can notify frondends
                   * 2: the guest driver does not spin in these cases
                   */
-                if (!info->is_console) {
+                if (vsc->is_console) {
                      virtio_serial_throttle_port(port, true);
                  }
                  port->iov_idx = i;

This change is wrong, reverses the if condition.  Was this done
manually or via a script?  If the latter, it would be worthwhile to
check all the conversions.

This was a manual rebase conflict resolution change on my part.  I'll fix.


-void virtio_serial_port_qdev_register(VirtIOSerialPortInfo *info)
+void virtio_serial_port_qdev_register(DeviceInfo *info)

Should the fn be renamed (replace qdev)?

It'll go away entirely in 3/3 which I'll post in a couple days.

Regards,

Anthony Liguori


                Amit





reply via email to

[Prev in Thread] Current Thread [Next in Thread]