Skip to content
Snippets Groups Projects
  1. Sep 12, 2014
  2. Sep 05, 2014
  3. Aug 26, 2014
  4. Aug 25, 2014
    • Alex Williamson's avatar
      x86: Clear MTRRs on vCPU reset · 9db2efd9
      Alex Williamson authored
      
      The SDM specifies (June 2014 Vol3 11.11.5):
      
          On a hardware reset, the P6 and more recent processors clear the
          valid flags in variable-range MTRRs and clear the E flag in the
          IA32_MTRR_DEF_TYPE MSR to disable all MTRRs. All other bits in the
          MTRRs are undefined.
      
      We currently do none of that, so whatever MTRR settings you had prior
      to reset is what you have after reset.  Usually this doesn't matter
      because KVM often ignores the guest mappings and uses write-back
      anyway.  However, if you have an assigned device and an IOMMU that
      allows NoSnoop for that device, KVM defers to the guest memory
      mappings which are now stale after reset.  The result is that OVMF
      rebooting on such a configuration takes a full minute to LZMA
      decompress the firmware volume, a process that is nearly instant on
      the initial boot.
      
      Signed-off-by: default avatarAlex Williamson <alex.williamson@redhat.com>
      Reviewed-by: default avatarLaszlo Ersek <lersek@redhat.com>
      Cc: qemu-stable@nongnu.org
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      9db2efd9
    • Alex Williamson's avatar
      x86: kvm: Add MTRR support for kvm_get|put_msrs() · d1ae67f6
      Alex Williamson authored
      
      The MTRR state in KVM currently runs completely independent of the
      QEMU state in CPUX86State.mtrr_*.  This means that on migration, the
      target loses MTRR state from the source.  Generally that's ok though
      because KVM ignores it and maps everything as write-back anyway.  The
      exception to this rule is when we have an assigned device and an IOMMU
      that doesn't promote NoSnoop transactions from that device to be cache
      coherent.  In that case KVM trusts the guest mapping of memory as
      configured in the MTRR.
      
      This patch updates kvm_get|put_msrs() so that we retrieve the actual
      vCPU MTRR settings and therefore keep CPUX86State synchronized for
      migration.  kvm_put_msrs() is also used on vCPU reset and therefore
      allows future modificaitons of MTRR state at reset to be realized.
      
      Note that the entries array used by both functions was already
      slightly undersized for holding every possible MSR, so this patch
      increases it beyond the 28 new entries necessary for MTRR state.
      
      Signed-off-by: default avatarAlex Williamson <alex.williamson@redhat.com>
      Reviewed-by: default avatarLaszlo Ersek <lersek@redhat.com>
      Cc: qemu-stable@nongnu.org
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      d1ae67f6
    • Alex Williamson's avatar
      x86: Use common variable range MTRR counts · d8b5c67b
      Alex Williamson authored
      
      We currently define the number of variable range MTRR registers as 8
      in the CPUX86State structure and vmstate, but use MSR_MTRRcap_VCNT
      (also 8) to report to guests the number available.  Change this to
      use MSR_MTRRcap_VCNT consistently.
      
      Signed-off-by: default avatarAlex Williamson <alex.williamson@redhat.com>
      Reviewed-by: default avatarLaszlo Ersek <lersek@redhat.com>
      Cc: qemu-stable@nongnu.org
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      d8b5c67b
    • William Grant's avatar
      target-i386: Don't forbid NX bit on PAE PDEs and PTEs · 1844e68e
      William Grant authored
      
      Commit e8f6d00c ("target-i386: raise
      page fault for reserved physical address bits") added a check that the
      NX bit is not set on PAE PDPEs, but it also added it to rsvd_mask for
      the rest of the function. This caused any PDEs or PTEs with NX set to be
      erroneously rejected, making PAE guests with NX support unusable.
      
      Signed-off-by: default avatarWilliam Grant <wgrant@ubuntu.com>
      Cc: qemu-stable@nongnu.org
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      1844e68e
  5. Aug 22, 2014
  6. Aug 12, 2014
  7. Aug 08, 2014
  8. Jul 15, 2014
  9. Jul 10, 2014
  10. Jun 25, 2014
  11. Jun 16, 2014
  12. Jun 10, 2014
  13. Jun 05, 2014
Loading