1. 12 12月, 2018 1 次提交
  2. 08 11月, 2018 2 次提交
  3. 24 10月, 2018 2 次提交
  4. 25 9月, 2018 2 次提交
  5. 30 8月, 2018 1 次提交
    • S
      spapr: Correct reference count on spapr-cpu-core · ecda255e
      Sam Bobroff 提交于
      spapr_init_cpus() currently creates spapr-cpu-core objects via
      object_new() and setting their realized property to true. This leaves
      their reference count at two, because object_new() adds an initial
      reference and the realization attaches them to a default parent object
      which also increments the reference count.
      
      This causes a problem if one of these cores is hot unplugged: no
      delete event is generated for it because it's reference count doesn't
      reach zero when it is detached from it's parent.
      
      Correct this by adding a call to object_unref() in spapr_init_cpus().
      Signed-off-by: NSam Bobroff <sbobroff@linux.ibm.com>
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      ecda255e
  6. 28 8月, 2018 1 次提交
  7. 24 8月, 2018 3 次提交
  8. 21 8月, 2018 3 次提交
  9. 17 8月, 2018 1 次提交
  10. 16 7月, 2018 1 次提交
  11. 03 7月, 2018 3 次提交
    • S
      ppc: Include vga cirrus card into the compiling process · 29f9cef3
      Sebastian Bauer 提交于
      Drivers for this card exists on PPC-based AmigaOS guests so it is useful to
      allow users to emulate the graphics card for PPC machines.
      
      As cirrus vga is currently preferred over std(vga) in absence of any user
      choice, this change also sets the default display of spapr machines to
      std as otherwise qemu refuses to start these machines. Not specifying an
      explicit graphics mode is for instance done by 'make check'.
      Signed-off-by: NSebastian Bauer <mail@sebastianbauer.info>
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      29f9cef3
    • G
      spapr: compute default value of "hpt-max-page-size" later · e8937295
      Greg Kurz 提交于
      It is currently not possible to run a pseries-2.12 or older machine
      with HV KVM. QEMU prints the following and exits right away.
      
      qemu-system-ppc64: KVM doesn't support for base page shift 34
      
      The "hpt-max-page-size" capability was recently added to spapr to hide
      host configuration details from HPT mode guests. Its default value for
      newer machine types is 64k.
      
      For backwards compatibility, pseries-2.12 and older machine types need
      a different value. This is handled as usual in a class init function.
      The default value is 16G, ie, all page sizes supported by POWER7 and
      newer CPUs, but HV KVM requires guest pages to be hpa contiguous as
      well as gpa contiguous. The default value is the page size used to
      back the guest RAM in this case.
      
      Unfortunately kvmppc_hpt_needs_host_contiguous_pages()->kvm_enabled() is
      called way before KVM init and returns false, even if the user requested
      KVM. We thus end up selecting 16G, which isn't supported by HV KVM. The
      default value must be set during machine init, because we can safely
      assume that KVM is initialized at this point.
      
      We fix this by moving the logic to default_caps_with_cpu(). Since the
      user cannot pass cap-hpt-max-page-size=0, we set the default to 0 in
      the pseries-2.12 class init function and use that as a flag to do the
      real work.
      Signed-off-by: NGreg Kurz <groug@kaod.org>
      Reviewed-by: NEduardo Habkost <ehabkost@redhat.com>
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      e8937295
    • C
      ppc/xics: rework the ICS classes inheritance tree · abe82ebb
      Cédric Le Goater 提交于
      With the previous changes, we can now let the ICS_KVM class inherit
      directly from ICS_BASE class and not from the intermediate ICS_SIMPLE.
      It makes the class hierarchy much cleaner.
      
      What is left in the top classes is the low level interface to access
      the KVM XICS device in ICS_KVM and the XICS emulating handlers in
      ICS_SIMPLE.
      
      This should not break migration compatibility.
      Signed-off-by: NCédric Le Goater <clg@kaod.org>
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      abe82ebb
  12. 02 7月, 2018 2 次提交
  13. 29 6月, 2018 2 次提交
  14. 22 6月, 2018 2 次提交
    • D
      spapr: Use maximum page size capability to simplify memory backend checking · 123eec65
      David Gibson 提交于
      The way we used to handle KVM allowable guest pagesizes for PAPR guests
      required some convoluted checking of memory attached to the guest.
      
      The allowable pagesizes advertised to the guest cpus depended on the memory
      which was attached at boot, but then we needed to ensure that any memory
      later hotplugged didn't change which pagesizes were allowed.
      
      Now that we have an explicit machine option to control the allowable
      maximum pagesize we can simplify this.  We just check all memory backends
      against that declared pagesize.  We check base and cold-plugged memory at
      reset time, and hotplugged memory at pre_plug() time.
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      Reviewed-by: NCédric Le Goater <clg@kaod.org>
      Reviewed-by: NGreg Kurz <groug@kaod.org>
      123eec65
    • D
      spapr: Maximum (HPT) pagesize property · 2309832a
      David Gibson 提交于
      The way the POWER Hash Page Table (HPT) MMU is virtualized by KVM HV means
      that every page that the guest puts in the pagetables must be truly
      physically contiguous, not just GPA-contiguous.  In effect this means that
      an HPT guest can't use any pagesizes greater than the host page size used
      to back its memory.
      
      At present we handle this by changing what we advertise to the guest based
      on the backing pagesizes.  This is pretty bad, because it means the guest
      sees a different environment depending on what should be host configuration
      details.
      
      As a start on fixing this, we add a new capability parameter to the
      pseries machine type which gives the maximum allowed pagesizes for an
      HPT guest.  For now we just create and validate the parameter without
      making it do anything.
      
      For backwards compatibility, on older machine types we set it to the max
      available page size for the host.  For the 3.0 machine type, we fix it to
      16, the intention being to only allow HPT pagesizes up to 64kiB by default
      in future.
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      Reviewed-by: NCédric Le Goater <clg@kaod.org>
      Reviewed-by: NGreg Kurz <groug@kaod.org>
      2309832a
  15. 21 6月, 2018 5 次提交
  16. 18 6月, 2018 1 次提交
    • G
      spapr: fix xics_system_init() error path · 844afc54
      Greg Kurz 提交于
      Commit 3d85885a tried to fix error handling, but it actually
      went into the wrong direction by dropping the local Error *.
      
      In the default KVM case, the rationale is to try the in-kernel XICS first,
      and if not possible, to fallback to userland XICS. Passing errp everywhere
      makes this fallback impossible if errp is &error_fatal (which happens to
      be the case). And anyway, if the caller would pass a regular &local_err,
      things would be worse: we could possibly pass an already set *errp to
      error_setg() and crash, or return an error even in case of success.
      
      So we definitely need a local Error * and only propagate it when we're
      done with the fallback logic. This is what this patch does.
      Signed-off-by: NGreg Kurz <groug@kaod.org>
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      844afc54
  17. 12 6月, 2018 6 次提交
  18. 01 6月, 2018 1 次提交
  19. 29 5月, 2018 1 次提交