1. 27 Feb, 2013 5 commits
  2. 22 Feb, 2013 2 commits
  3. 20 Feb, 2013 1 commit
  4. 19 Feb, 2013 1 commit
  5. 15 Feb, 2013 1 commit
  6. 14 Feb, 2013 1 commit
  7. 13 Feb, 2013 6 commits
  8. 11 Feb, 2013 3 commits
  9. 07 Feb, 2013 5 commits
  10. 06 Feb, 2013 4 commits
  11. 05 Feb, 2013 7 commits
  12. 30 Jan, 2013 3 commits
    • Christian Borntraeger's avatar
      s390/kvm: Fix instruction decoding · 0c29b229
      Christian Borntraeger authored
      Instructions with long displacement have a signed displacement.
      Currently the sign bit is interpreted as 2^20: Lets fix it by doing the
      sign extension from 20bit to 32bit and then use it as a signed variable
      in the addition (see kvm_s390_get_base_disp_rsy).
      
      Furthermore, there are lots of "int" in that code. This is problematic,
      because shifting on a signed integer is undefined/implementation defined
      if the bit value happens to be negative.
      Fortunately the promotion rules will make the right hand side unsigned
      anyway, so there is no real problem right now.
      Let's convert them anyway to unsigned where appropriate to avoid
      problems if the code is changed or copy/pasted later on.
      Signed-off-by: default avatarChristian Borntraeger <borntraeger@de.ibm.com>
      Reviewed-by: default avatarCornelia Huck <cornelia.huck@de.ibm.com>
      Signed-off-by: default avatarGleb Natapov <gleb@redhat.com>
      0c29b229
    • Cornelia Huck's avatar
      s390/virtio-ccw: Fix setup_vq error handling. · c98d3683
      Cornelia Huck authored
      virtio_ccw_setup_vq() failed to unwind correctly on errors. In
      particular, it failed to delete the virtqueue on errors, leading to
      list corruption when virtio_ccw_del_vqs() iterated over a virtqueue
      that had not been added to the vcdev's list.
      
      Fix this with redoing the error unwinding in virtio_ccw_setup_vq(),
      using a single path for all errors.
      Signed-off-by: default avatarCornelia Huck <cornelia.huck@de.ibm.com>
      Reviewed-by: default avatarChristian Borntraeger <borntraeger@de.ibm.com>
      Signed-off-by: default avatarChristian Borntraeger <borntraeger@de.ibm.com>
      Signed-off-by: default avatarGleb Natapov <gleb@redhat.com>
      c98d3683
    • Christian Borntraeger's avatar
      s390/kvm: Fix store status for ACRS/FPRS · 15bc8d84
      Christian Borntraeger authored
      On store status we need to copy the current state of registers
      into a save area. Currently we might save stale versions:
      The sie state descriptor doesnt have fields for guest ACRS,FPRS,
      those registers are simply stored in the host registers. The host
      program must copy these away if needed. We do that in vcpu_put/load.
      
      If we now do a store status in KVM code between vcpu_put/load, the
      saved values are not up-to-date. Lets collect the ACRS/FPRS before
      saving them.
      
      This also fixes some strange problems with hotplug and virtio-ccw,
      since the low level machine check handler (on hotplug a machine check
      will happen) will revalidate all registers with the content of the
      save area.
      Signed-off-by: default avatarChristian Borntraeger <borntraeger@de.ibm.com>
      CC: stable@vger.kernel.org
      Signed-off-by: default avatarGleb Natapov <gleb@redhat.com>
      15bc8d84
  13. 29 Jan, 2013 1 commit
    • Raghavendra K T's avatar
      kvm: Handle yield_to failure return code for potential undercommit case · c45c528e
      Raghavendra K T authored
      yield_to returns -ESRCH, When source and target of yield_to
      run queue length is one. When we see three successive failures of
      yield_to we assume we are in potential undercommit case and abort
      from PLE handler.
      The assumption is backed by low probability of wrong decision
      for even worst case scenarios such as average runqueue length
      between 1 and 2.
      
      More detail on rationale behind using three tries:
      if p is the probability of finding rq length one on a particular cpu,
      and if we do n tries, then probability of exiting ple handler is:
      
       p^(n+1) [ because we would have come across one source with rq length
      1 and n target cpu rqs  with length 1 ]
      
      so
      num tries:         probability of aborting ple handler (1.5x overcommit)
       1                 1/4
       2                 1/8
       3                 1/16
      
      We can increase this probability with more tries, but the problem is
      the overhead.
      Also, If we have tried three times that means we would have iterated
      over 3 good eligible vcpus along with many non-eligible candidates. In
      worst case if we iterate all the vcpus, we reduce 1x performance and
      overcommit performance get hit.
      
      note that we do not update last boosted vcpu in failure cases.
      Thank Avi for raising question on aborting after first fail from yield_to.
      Reviewed-by: default avatarSrikar Dronamraju <srikar@linux.vnet.ibm.com>
      Signed-off-by: default avatarRaghavendra K T <raghavendra.kt@linux.vnet.ibm.com>
      Tested-by: default avatarChegu Vinod <chegu_vinod@hp.com>
      Signed-off-by: default avatarGleb Natapov <gleb@redhat.com>
      c45c528e