1. 04 2月, 2012 2 次提交
    • A
      qdev: kill off DeviceInfo · d307af79
      Anthony Liguori 提交于
      It is no longer used in the tree since everything is done natively through
      QEMU Object Model.
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      d307af79
    • A
      qdev: register all types natively through QEMU Object Model · 39bffca2
      Anthony Liguori 提交于
      This was done in a mostly automated fashion.  I did it in three steps and then
      rebased it into a single step which avoids repeatedly touching every file in
      the tree.
      
      The first step was a sed-based addition of the parent type to the subclass
      registration functions.
      
      The second step was another sed-based removal of subclass registration functions
      while also adding virtual functions from the base class into a class_init
      function as appropriate.
      
      Finally, a python script was used to convert the DeviceInfo structures and
      qdev_register_subclass functions to TypeInfo structures, class_init functions,
      and type_register_static calls.
      
      We are almost fully converted to QOM after this commit.
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      39bffca2
  2. 28 1月, 2012 2 次提交
  3. 14 1月, 2012 1 次提交
  4. 30 12月, 2011 1 次提交
    • C
      virtio-console: Fix failure on unconnected pty · ed8e5a85
      Christian Borntraeger 提交于
      when I tried qemu with -virtio-console pty the guest hangs and attaching
      on /dev/pts/<x> does not return anything if the attachment is too late.
      
      This results in pty_chr_write() returning 0, which causes the port to
      get throttled. This results in the guest getting frozen as the
      guest->host virtio_console writes don't return until the host releases
      the vq element back to the guest.
      
      For the virtio-serial use case we don't want to lose data but for the
      console case we better drop data instead of "killing" the guest
      console. If we get chardev->frontend notification and a better behaving
      virtio-console we can revert this fix.
      Signed-off-by: NChristian Borntraeger <borntraeger@de.ibm.com>
      Signed-off-by: NAmit Shah <amit.shah@redhat.com>
      ed8e5a85
  5. 22 12月, 2011 1 次提交
  6. 21 8月, 2011 1 次提交
  7. 24 7月, 2011 2 次提交
  8. 18 7月, 2011 3 次提交
  9. 27 6月, 2011 1 次提交
    • L
      virtio-serial: Fix segfault on guest boot · d2e4d08b
      Luiz Capitulino 提交于
      If I start qemu with:
      
        # qemu -hda disks/test.img -enable-kvm -m 1G -snapshot \
               -device virtio-serial \
               -chardev socket,host=localhost,port=1234,server,nowait,id=foo \
               -device virtserialport,chardev=foo,name=org.qemu.guest_agent
      
      I get a segfault when booting a Fedora 14 guest. The backtrace says:
      
        Program terminated with signal 11, Segmentation fault.
          #0  0x0000000000420850 in handle_control_message (vser=0x3732bd0, buf=0x2c173e0, len=8) at /home/lcapitulino/src/qmp-unstable/hw/virtio-serial-bus.c:335
          335     info = DO_UPCAST(VirtIOSerialPortInfo, qdev, port->dev.info);
      
      What's happening is VIRTIO_CONSOLE_DEVICE_READY is a message for the
      whole device, not for an individual port. So port is NULL. This bug was
      introduced by commit a15bb0d6.
      
      This commit fixes that by making the port returned by find_port_by_id()
      be used only by the VIRTIO_CONSOLE_PORT_READY and
      VIRTIO_CONSOLE_PORT_OPEN messages.
      Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
      Reviewed-by: NMarkus Armbruster <armbru@redhat.com>
      Signed-off-by: NAmit Shah <amit.shah@redhat.com>
      d2e4d08b
  10. 24 6月, 2011 1 次提交
  11. 27 5月, 2011 4 次提交
  12. 28 4月, 2011 1 次提交
  13. 29 3月, 2011 1 次提交
  14. 21 3月, 2011 2 次提交
  15. 25 2月, 2011 1 次提交
  16. 04 2月, 2011 1 次提交
  17. 20 1月, 2011 4 次提交
  18. 12 1月, 2011 1 次提交
  19. 23 8月, 2010 1 次提交
  20. 31 7月, 2010 1 次提交
  21. 13 7月, 2010 2 次提交
  22. 06 7月, 2010 1 次提交
  23. 01 7月, 2010 1 次提交
  24. 02 6月, 2010 1 次提交
  25. 04 5月, 2010 1 次提交
  26. 28 4月, 2010 2 次提交
    • A
      virtio-serial: Implement flow control for individual ports · 9ed7b059
      Amit Shah 提交于
      Individual ports can now signal to the virtio-serial core to stop
      sending data if the ports cannot immediately handle new data.  When a
      port later unthrottles, any data queued up in the virtqueue are sent to
      the port.
      
      Disable throttling once a port is closed (and we discard all the
      unconsumed buffers in the vq).
      
      The guest kernel can reclaim the buffers when it receives the port close
      event or when a port is being removed. Ensure we free up the buffers
      before we send out any events to the guest.
      Signed-off-by: NAmit Shah <amit.shah@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      9ed7b059
    • A
      virtio-serial: Discard data that guest sends us when ports aren't connected · a69c7600
      Amit Shah 提交于
      Before the earlier patch, we relied on incorrect virtio api usage to
      signal to the guest that a particular buffer wasn't consumed by the
      host.
      
      After fixing that, we now just discard the data the guest sends us while
      a host port is disconnected or doesn't have a handler registered for
      consuming data.
      
      This commit really doesn't change anything from the current behaviour,
      just makes the code slightly better by spinning off data handling to
      ports in another function.
      Signed-off-by: NAmit Shah <amit.shah@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      a69c7600