1. 07 11月, 2013 3 次提交
    • P
      timers: fix stop/cont with -icount · 5f3e3101
      Paolo Bonzini 提交于
      Stop/cont commands are broken with -icount due to a deadlock.  The
      real problem is that the computation of timers_state.cpu_ticks_offset
      makes no sense with -icount enabled: we set it to an icount clock value
      in cpu_disable_ticks, and subtract a TSC (or similar, whatever
      cpu_get_real_ticks happens to return) value in cpu_enable_ticks.
      
      The fix is simple.  timers_state.cpu_ticks_offset is only used
      together with cpu_get_real_ticks, so we can use cpu_get_real_ticks
      in cpu_disable_ticks.  There is no need to update cpu_ticks_prev
      at the time cpu_disable_ticks is called; instead, we can do it
      the next time cpu_get_ticks is called.
      
      The change to cpu_disable_ticks is the important part of the patch.
      The rest modifies the code to always check timers_state.cpu_ticks_prev,
      even when the ticks are not advancing (i.e. the VM is stopped).  It also
      makes a similar change to cpu_get_clock_locked, so that the code remains
      similar for cpu_get_ticks and cpu_get_clock_locked.
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      Message-id: 1382977938-13844-1-git-send-email-pbonzini@redhat.com
      Signed-off-by: NAnthony Liguori <aliguori@amazon.com>
      5f3e3101
    • A
      e1000/rtl8139: update HMP NIC when every bit is written · cd5be582
      Amos Kong 提交于
      We currently just update the HMP NIC info when the last bit of macaddr
      is written. This assumes that guest driver will write all the macaddr
      from bit 0 to bit 5 when it changes the macaddr, this is the current
      behavior of linux driver (e1000/rtl8139cp), but we can't do this
      assumption.
      
      The macaddr that is used for rx-filter will be updated when every bit
      is changed. This patch updates the e1000/rtl8139 nic to update HMP NIC
      info when every bit is changed. It will be same as virtio-net.
      Signed-off-by: NAmos Kong <akong@redhat.com>
      Reviewed-by: NAlex Williamson <alex.williamson@redhat.com>
      Message-id: 1383650238-16015-1-git-send-email-akong@redhat.com
      Signed-off-by: NAnthony Liguori <aliguori@amazon.com>
      cd5be582
    • J
      virtio-net: only delete bh that existed · fe2dafa0
      Jason Wang 提交于
      We delete without check whether it existed during exit. This will lead NULL
      pointer deference since it was created conditionally depends on guest driver
      status and features. So add a check of existence before trying to delete it.
      
      Cc: qemu-stable@nongnu.org
      Signed-off-by: NJason Wang <jasowang@redhat.com>
      Reviewed-by: NMichael S. Tsirkin <mst@redhat.com>
      Message-id: 1383728288-28469-1-git-send-email-jasowang@redhat.com
      Signed-off-by: NAnthony Liguori <aliguori@amazon.com>
      fe2dafa0
  2. 06 11月, 2013 37 次提交