1. 16 3月, 2010 1 次提交
  2. 09 3月, 2010 1 次提交
  3. 20 2月, 2010 1 次提交
  4. 11 2月, 2010 1 次提交
    • C
      block: add topology qdev properties · 428c149b
      Christoph Hellwig 提交于
      Add three new qdev properties to export block topology information to
      the guest.  This is needed to get optimal I/O alignment for RAID arrays
      or SSDs.
      
      The options are:
      
       - physical_block_size to specify the physical block size of the device,
         this is going to increase from 512 bytes to 4096 kilobytes for many
         modern storage devices
       - min_io_size to specify the minimal I/O size without performance impact,
         this is typically set to the RAID chunk size for arrays.
       - opt_io_size to specify the optimal sustained I/O size, this is
         typically the RAID stripe width for arrays.
      
      I decided to not auto-probe these values from blkid which might easily
      be possible as I don't know how to deal with these issues on migration.
      
      Note that we specificly only set the physical_block_size, and not the
      logial one which is the unit all I/O is described in.  The reason for
      that is that IDE does not support increasing the logical block size and
      at last for now I want to stick to one meachnisms in queue and allow
      for easy switching of transports for a given backing image which would
      not be possible if scsi and virtio use real 4k sectors, while ide only
      uses the physical block exponent.
      
      To make this more common for the different block drivers introduce a
      new BlockConf structure holding all common block properties and a
      DEFINE_BLOCK_PROPERTIES macro to add them all together, mirroring
      what is done for network drivers.  Also switch over all block drivers
      to use it, except for the floppy driver which has weird driveA/driveB
      properties and probably won't require any advanced block options ever.
      
      Example usage for a virtio device with 4k physical block size and
      8k optimal I/O size:
      
        -drive file=scratch.img,media=disk,cache=none,id=scratch \
        -device virtio-blk-pci,drive=scratch,physical_block_size=4096,opt_io_size=8192
      
      aliguori: updated patch to take into account BLOCK events
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      428c149b
  5. 20 1月, 2010 2 次提交
    • A
      virtio-serial: Use MSI vectors for port virtqueues · a1829205
      Amit Shah 提交于
      This commit enables the use of MSI interrupts for virtqueue
      notifications for ports. We use nr_ports + 1 (for control channel) msi
      entries for the ports, as only the in_vq operations need an interrupt on
      the guest.
      Signed-off-by: NAmit Shah <amit.shah@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      a1829205
    • A
      virtio-console: qdev conversion, new virtio-serial-bus · 98b19252
      Amit Shah 提交于
      This commit converts the virtio-console device to create a new
      virtio-serial bus that can host console and generic serial ports. The
      file hosting this code is now called virtio-serial-bus.c.
      
      The virtio console is now a very simple qdev device that sits on the
      virtio-serial-bus and communicates between the bus and qemu's chardevs.
      
      This commit also includes a few changes to the virtio backing code for
      pci and s390 to spawn the virtio-serial bus.
      
      As a result of the qdev conversion, we get rid of a lot of legacy code.
      The old-style way of instantiating a virtio console using
      
          -virtioconsole ...
      
      is maintained, but the new, preferred way is to use
      
          -device virtio-serial -device virtconsole,chardev=...
      
      With this commit, multiple devices as well as multiple ports with a
      single device can be supported.
      
      For multiple ports support, each port gets an IO vq pair. Since the
      guest needs to know in advance how many vqs a particular device will
      need, we have to set this number as a property of the virtio-serial
      device and also as a config option.
      
      In addition, we also spawn a pair of control IO vqs. This is an internal
      channel meant for guest-host communication for things like port
      open/close, sending port properties over to the guest, etc.
      
      This commit is a part of a series of other commits to get the full
      implementation of multiport support. Future commits will add other
      support as well as ride on the savevm version that we bump up here.
      Signed-off-by: NAmit Shah <amit.shah@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      98b19252
  6. 12 1月, 2010 3 次提交
  7. 19 12月, 2009 2 次提交
  8. 12 12月, 2009 1 次提交
  9. 01 12月, 2009 1 次提交
  10. 09 11月, 2009 2 次提交
  11. 28 10月, 2009 1 次提交
  12. 07 10月, 2009 1 次提交
  13. 05 10月, 2009 6 次提交
  14. 02 10月, 2009 2 次提交
  15. 20 9月, 2009 1 次提交
  16. 11 9月, 2009 1 次提交
    • Y
      VirtIO: Fix QEMU crash during Windows PNP tests · ed757e14
      Yan Vugenfirer 提交于
      Hello,
      
      In some cases bus driver can deassert "bus master" bit in PCI command
      register. The driver will no longer be able to update related registers in
      the device. Eventually it will cause QEMU to exit in "virtqueue_num_heads"
      function.
      
      Attached path that fixes the described issue.
      
      Best regards,
      Yan Vugenfirer.
      
      >From 3fdafbdfad676ec8479dc073cff70bf356868bfe Mon Sep 17 00:00:00 2001
      From: Yan Vugenfirer <yvugenfi@redhat.com>
      Date: Tue, 8 Sep 2009 10:08:14 -0400
      Subject: [PATCH] VirtIO: Fix QEMU crash during Windows PNP tests
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      ed757e14
  17. 28 8月, 2009 2 次提交
  18. 24 8月, 2009 1 次提交
  19. 11 8月, 2009 2 次提交
    • G
      qdev/prop: convert virtio-pci.c to helper macros. · 72c61d0b
      Gerd Hoffmann 提交于
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      Message-Id: 
      72c61d0b
    • G
      qdev-ify virtio-blk. · d176c495
      Gerd Hoffmann 提交于
      First user of the new drive property.  With this patch applied host
      and guest config can be specified separately, like this:
      
        -drive if=none,id=disk1,file=/path/to/disk.img
        -device virtio-blk-pci,drive=disk1
      
      You can set any property for virtio-blk-pci now.  You can set the pci
      address via addr=.  You can switch the device into 0.10 compat mode
      using class=0x0180.  As this is per device you can have one 0.10 and one
      0.11 virtio block device in a single virtual machine.
      
      Old syntax continues to work.  Internally it does the same as the two
      lines above though.  One side effect this has is a different
      initialization order, which might result in a different pci address
      being assigned by default.
      
      Long term plan here is to have this working for all block devices, i.e.
      once all scsi is properly qdev-ified you will be able to do something
      like this:
      
        -drive if=none,id=sda,file=/path/to/disk.img
        -device lsi,id=lsi,addr=<pciaddr>
        -device scsi-disk,drive=sda,bus=lsi.0,lun=<n>
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      Message-Id: 
      d176c495
  20. 30 7月, 2009 1 次提交
  21. 17 7月, 2009 4 次提交
  22. 16 7月, 2009 2 次提交
    • M
      Change default PCI class of virtio-console to PCI_CLASS_SERIAL_OTHER · 21d58b57
      Mark McLoughlin 提交于
      We're using PCI_CLASS_DISPLAY_OTHER now, but qemu-kvm.git is using
      PCI_CLASS_OTHERS because:
      
        "As a PCI_CLASS_DISPLAY_OTHER, it reduces primary display somehow on
         Windows XP (possibly Windows disables acceleration since it fails
         to find a driver)."
      
      While this is valid, many versions of X will get confused by it.
      Class major number of 0 gets treated as a possibly prehistoric VGA
      device, and then the autoconfig logic gets confused trying to figure
      out whether the virtio console or the pv vga device are the real VGA.
      
      We should really set a proper class ID. 0x0780 (serial / other) seems
      most appropriate. This shouldn't require any kernel changes, the
      modalias for virtio looks like:
      
        alias:          pci:v00001AF4d*sv*sd*bc*sc*i*
      
      so won't care what the base class or subclass are.
      
      It shows up in the guest as:
      
        00:05.0 Communication controller: Qumranet, Inc. Virtio console
      
      A new qdev type is introduced to allow devices using the old class
      to be created for compatibility with qemu-0.10.x.
      Reported-by: NAdam Jackson <ajax@redhat.com>
      Signed-off-by: NMark McLoughlin <markmc@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      21d58b57
    • M
      Change default PCI class of virtio-blk to PCI_CLASS_STORAGE_SCSI · 5c634ef3
      Mark McLoughlin 提交于
      Windows virtio driver cannot pass DTM (certification) tests while the
      storage class is PCI_CLASS_STORAGE_UNKNOWN.
      
      A new qdev type is introduced to allow devices using the old class
      to be created for compatibility with qemu-0.10.x.
      Reported-by: NDor Laor <dlaor@redhat.com>
      Signed-off-by: NMark McLoughlin <markmc@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      5c634ef3
  23. 11 7月, 2009 1 次提交