[SRU][N][PATCH 0/2] KOP L2 guest fails to boot with 1 core - SMT8 topology (LP: 2070329)

frank.heimes at canonical.com frank.heimes at canonical.com
Mon Sep 2 08:34:42 UTC 2024


BugLink: https://bugs.launchpad.net/bugs/2070329

SRU Justification:

[ Impact ]

 * On a P10 system with SMT-8 configured
   a level 2 guest (VM) fails to boot in case
   it only has one core assigned.

[ Test Plan ]

 * Setup an IBM Power 10 system - that support up to SMT-8
   and with firmware 1060, that offers support for KVM -
   using Ubuntu Server 24.04 for ppc64el.

 * Setup qemu/KVM on this system.

 * Configure a KVM guest (e.g. using virtinst or
   qemu-system-ppc64 directly) now with smt-8,
   but only one virtual CPU.

 * Try to boot this specific guest:
   qemu-system-ppc64 \
   -drive file=rhel.qcow2,format=qcow2 \
   -m 20G \
   -smp 8,cores=1,threads=8 \
   -cpu host \
   -nographic \
   -machine pseries,ic-mode=xics -accel kvm

 * It will fail to boot with a kernel that does not
   have the two patches in place.

 * Since this setup requires a special firmware level,
   the verification will be done by the IBM Power team.

[ Where problems could occur ]

 * Primarily support for using DPDES (register) is required,
   since its needed for enabling usage of doorbells in L2 gusts.
   This is mainly done by adding DEFINEs, stubs and case.
   If the definitions are not correct or if the code executed by
   the new case (KVMPPC_GSID_DPDES) is done wrong,
   the guest state could be incorrect, harming the L2 guest doorbell.
   (DPDES is to provide the means for the hypervisor to save a
    [sub-]processor's Directed Privileged Doorbell exception state
    when the set of programs running on the [sub-]processor is
    swapped out or moved from one [sub-]processor to another.)

 * The missing Doorbell emulation got added by a 4 line if statement
   in powerpc/kvm/book3s_hv.c, which is relatively traceable.

 * The main issue I can think of is that kvmppc_set_dpdes is called
   with wrong arguments.

 * And kvmppc_set_dpdes will not work (at all) if the above DPDES
   support (and commit/patch) is missing.

[ Other Info ]

 * Since (nested) KVM support is new on P10,
   this does not affect older Power generation
   (P9 is the only other hw generation that is supported by 24.04,
   but it only supports native virtualization).

 * Both patches are upstream accepted since v6.11(-rc1),
   hence will be in oracular
   and are also upstream tagged as stable updates.

 * Since the required firmware FW1060 is relatively new,
   we can assume that not many user ran into this issue yet.

Gautam Menghani (2):
  KVM: PPC: Book3S HV nestedv2: Add DPDES support in helper library for
    Guest state buffer
  KVM: PPC: Book3S HV nestedv2: Fix doorbell emulation

 Documentation/arch/powerpc/kvm-nested.rst     | 4 +++-
 arch/powerpc/include/asm/guest-state-buffer.h | 3 ++-
 arch/powerpc/include/asm/kvm_book3s.h         | 1 +
 arch/powerpc/kvm/book3s_hv.c                  | 5 +++++
 arch/powerpc/kvm/book3s_hv_nestedv2.c         | 7 +++++++
 arch/powerpc/kvm/test-guest-state-buffer.c    | 2 +-
 6 files changed, 19 insertions(+), 3 deletions(-)

-- 
2.34.1




More information about the kernel-team mailing list