1. 28 10月, 2009 3 次提交
  2. 16 9月, 2009 1 次提交
  3. 11 9月, 2009 3 次提交
  4. 04 9月, 2009 2 次提交
  5. 28 8月, 2009 9 次提交
  6. 26 8月, 2009 1 次提交
  7. 24 8月, 2009 1 次提交
  8. 14 8月, 2009 1 次提交
  9. 11 8月, 2009 1 次提交
    • G
      make windows notice media change · 93c8cfd9
      Gleb Natapov 提交于
      Windows seems to be very stupid about cdrom media change. It polls
      cdrom status and if status goes ready->media not present->ready
      it assumes that media was changed. If "media not present" step doesn't
      happen even if "medium may have changed" was seen it assumes media
      haven't changed. Fake "media not present" step.
      
      Filip Navara did a great job debugging this issue in Windows and this is
      what he found out:
      
      BINGO! ... The media present notifications were broken ever since
      Windows 2000 it seems. The media change is detected properly and it's
      passed to ClassSetMediaChangeState function which in turn calls
      ClasspInternalSetMediaChangeState. This function is responsible for
      changing some internal state of the device object and sending the PnP
      events which later result in application notifications. It has this
      tiny bit of code (not copied byte for byte):
      
      if (oldMediaState == NewState) {
        // Media is in the same state it was before.
        return;
      }
      
      so the end result is that for the case of UNIT NEEDS ATTENTION /
      MEDIUM MAY HAVE CHANGED without NOT READY in-between is really broken.
      It results in the internal media change counter incremented, so the
      media contents are re-read when necessary, instead of relying on the
      cache, but the notifications to applications are never sent.
      Signed-off-by: NGleb Natapov <gleb@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      Message-Id: 
      93c8cfd9
  10. 01 8月, 2009 1 次提交
  11. 30 7月, 2009 1 次提交
    • M
      Fix VM state change handlers running out of order · 213189ab
      Markus Armbruster 提交于
      When a VM state change handler changes VM state, other VM state change
      handlers can see the state transitions out of order.
      
      bmdma_map(), scsi_disk_init() and virtio_blk_init() install VM state
      change handlers to restart DMA.  These handlers can vm_stop() by
      running into a write error on a drive with werror=stop.  This throws
      the VM state change handler callback into disarray.  Here's an example
      case I observed:
      
      0. The virtual IDE drive goes south.  All future writes return errors.
      
      1. Something encounters a write error, and duly stops the VM with
         vm_stop().
      
      2. vm_stop() calls vm_state_notify(0).
      
      3. vm_state_notify() runs the callbacks in list vm_change_state_head.
         It contains ide_dma_restart_cb() installed by bmdma_map().  It also
         contains audio_vm_change_state_handler() installed by audio_init().
      
      4. audio_vm_change_state_handler() stops audio stuff.
      
      5. User continues VM with monitor command "c".  This runs vm_start().
      
      6. vm_start() calls vm_state_notify(1).
      
      7. vm_state_notify() runs the callbacks in vm_change_state_head.
      
      8. ide_dma_restart_cb() happens to come first.  It does its work, runs
         into a write error, and duly stops the VM with vm_stop().
      
      9. vm_stop() runs vm_state_notify(0).
      
      10. vm_state_notify() runs the callbacks in vm_change_state_head.
      
      11. audio_vm_change_state_handler() stops audio stuff.  Which isn't
         running.
      
      12. vm_stop() finishes, ide_dma_restart_cb() finishes, step 7's
         vm_state_notify() resumes running handlers.
      
      13. audio_vm_change_state_handler() starts audio stuff.  Oopsie.
      
      Fix this by moving the actual write from each VM state change handler
      into a new bottom half (suggested by Gleb Natapov).
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      213189ab
  12. 30 6月, 2009 1 次提交
  13. 17 6月, 2009 3 次提交
  14. 22 5月, 2009 1 次提交
    • J
      Introduce reset notifier order · 8217606e
      Jan Kiszka 提交于
      Add the parameter 'order' to qemu_register_reset and sort callbacks on
      registration. On system reset, callbacks with lower order will be
      invoked before those with higher order. Update all existing users to the
      standard order 0.
      
      Note: At least for x86, the existing users seem to assume that handlers
      are called in their registration order. Therefore, the patch preserves
      this property. If someone feels bored, (s)he could try to identify this
      dependency and express it properly on callback registration.
      Signed-off-by: NJan Kiszka <jan.kiszka@siemens.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      8217606e
  15. 10 5月, 2009 1 次提交
  16. 04 5月, 2009 1 次提交
  17. 23 4月, 2009 1 次提交
    • A
      implement qemu_blockalign (Stefano Stabellini) · e268ca52
      aliguori 提交于
      this patch adds a buffer_alignment field to BlockDriverState and
      implements a qemu_blockalign function that uses that field to allocate a
      memory aligned buffer to be used by the block driver.
      buffer_alignment is initialized to 512 but each block driver can set
      a different value (at the moment none of them do).
      This patch modifies ide.c, block-qcow.c, block-qcow2.c and block.c to
      use qemu_blockalign instead of qemu_memalign.
      There is only one place left that still uses qemu_memalign to allocate
      buffers used by block drivers that is posix-aio-compat:handle_aiocb_rw
      because it is not possible to get the BlockDriverState from that
      function. However I think it is not important because posix-aio-compat
      already deals with driver specific code so it is supposed to know its
      own needs.
      Signed-off-by: NStefano Stabellini <stefano.stabellini@eu.citrix.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      
      
      git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7229 c046a42c-6fe2-441c-8c8c-71466251a162
      e268ca52
  18. 14 4月, 2009 1 次提交
  19. 08 4月, 2009 1 次提交
  20. 07 3月, 2009 1 次提交
  21. 04 3月, 2009 1 次提交
  22. 03 3月, 2009 1 次提交
  23. 11 2月, 2009 1 次提交
  24. 06 2月, 2009 2 次提交