mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Sean Christopherson <seanjc@google.com>
To: Ritesh Harjani <ritesh.list@gmail.com>
Cc: kvm@vger.kernel.org, Paolo Bonzini <pbonzini@redhat.com>,
	linuxppc-dev@lists.ozlabs.org,
	 Michael Ellerman <mpe@ellerman.id.au>,
	Christophe Leroy <chleroy@kernel.org>,
	 Anushree Mathur <anushree.mathur@linux.ibm.com>,
	 Venkat Rao Bagalkote <venkat88@linux.ibm.com>,
	Harsh Prateek Bora <harshpb@linux.ibm.com>,
	 Madhavan Srinivasan <maddy@linux.ibm.com>,
	Shrikanth Hegde <sshegde@linux.ibm.com>,
	 linux-kernel@vger.kernel.org
Subject: Re: [PATCH v5 0/9] KVM: selftests: add powerpc support
Date: Sun, 4 Oct 2026 23:08:23 -0700	[thread overview]
Message-ID: <asM-1-ptu1b_URqR@google.com> (raw)
In-Reply-To: <fqykkc3j.ritesh.list@gmail.com>

On Mon, Oct 05, 2026, Ritesh Harjani wrote:
 > I think I'd even prefer to take on an #ifdef (to scope it to PPC if necessary)
> > over open coding TEST_GEN_PROGS_COMMON.
> 
> Sure, so will add this check for kvm_create_max_vcpus()
> 
> #ifdef __powerpc64__
>        TEST_REQUIRE(!is_pseries_lpar());
> #endif 

Or maybe to avoid too many ifdefs, something like:

  static inline kvm_is_ppc_pseries_lpar(void)
  {
          /*
           * Comment about how this setup has unique limitations and isn't
           * compatible with tests that create many VMs and/or vCPUs.
           */
  #ifdef __powerpc64___
          return !access("/proc/device-tree/rtas/ibm,hypertas-functions", F_OK);
  #else
          return false;
  #endif
  }

Probably redundant naming to some extent, but having "ppc" in there would make it
super obvious it's a PPC-only check.
 
> Actually I was thinking we may as well use the same check for now for
> skipping hardware_disable_test on pseries. Because there also we suffer
> from the same resource limitation. Let me know if that sounds ok to you
> or do you want us to skip kvm_create_max_vcpus() only for now, since it
> is part of TEST_GEN_PROGS_COMMON?
> 
> > LoongArch open coded its full test list
> > for some reason, and in less than a year it has started missing out on new common
> > tests.
> >
> >> (& maybe few others like vm_types_test) from that in v6.
> >
> > What's wrong with VM types test?  That one really should Just Work on all
> > architectures.  It doesn't run on LoongArch, but I assume that's
> > oversight?
> 
> So the test doesn't fail (it gets skipped). However this cap
> "KVM_CAP_VM_TYPES" is only supported on x86 and since I was planning to
> open code all common tests, hence I thought I may as well not add this
> in the first place.

/facepalm

I completely forgot KVM_CAP_VM_TYPES is x86-only.  FWIW, I'd still say use
TEST_GEN_PROGS_COMMON if possible.

> BTW, based on this discussion, I think I will re-arrange the patches in
> the following order and send a v7. (The Makefile.kvm changes will only
> get added after the main patch which adds powerpc support).
> 
> cfabdb049bd7 2026-10-05 [Ritesh Harjani (IBM)] (HEAD -> feat-ppc-kvm-selftests-new-sean-v7) KVM: selftests: Skip hardware_disable_test on pseries
> 2b51fab87b95 2026-09-22 [Ritesh Harjani (IBM)] KVM: PPC: selftests: Skip idle-page check when running nested on pseries LPAR
> f5d1de1be4e9 2026-10-05 [Ritesh Harjani (IBM)] KVM: selftests: Skip kvm_create_max_vcpus on pseries
> e45ba15cea25 2026-10-03 [Ritesh Harjani (IBM)] KVM: PPC: selftests: Add helper for checking if running nested

Doesn't this one need to come first?  Or is this different than pseries LPAR?

> 178c9bca0e20 2026-09-22 [Nicholas Piggin] KVM: PPC: selftests: add support for powerpc
> 22320662e776 2026-09-11 [Ritesh Harjani (IBM)] KVM: selftests: Fix kvm_create_max_vcpus test for powerpc

This should come before "add support for powerpc", and should have a shortlog
more like "Skip max vCPU IDs test on PPC with <whatever is a good description of the SMT cap>"

> 11b5712b213b 2026-09-22 [Ritesh Harjani (IBM)] KVM: selftests: Move memslot_perf_test off the 256M ELF load address
> 63c900860b5f 2026-09-22 [Ritesh Harjani (IBM)] KVM: selftests: Don't limit LE dirty-bitmap bitops to s390x
> 
> 
> Please let me know if this sounds ok?

Ya, works for me!

  reply	other threads:[~2026-10-05  6:08 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-22 18:28 Ritesh Harjani (IBM)
2026-09-22 18:28 ` [PATCH v5 1/9] KVM: PPC: selftests: add support for powerpc Ritesh Harjani (IBM)
2026-10-02 22:12   ` Sean Christopherson
2026-10-03  4:37     ` Ritesh Harjani
2026-09-22 18:28 ` [PATCH v5 2/9] KVM: selftests: Enable kvm_create_max_vcpus test " Ritesh Harjani (IBM)
2026-09-22 18:28 ` [PATCH v5 3/9] KVM: selftests: Don't limit LE dirty-bitmap bitops to s390x Ritesh Harjani (IBM)
2026-09-22 18:28 ` [PATCH v5 4/9] KVM: selftests: Split out a KVM_CREATE_VCPU helper that can fail Ritesh Harjani (IBM)
2026-09-22 18:28 ` [PATCH v5 5/9] KVM: selftests: Make kvm_create_max_vcpus tolerate ENOMEM Ritesh Harjani (IBM)
2026-10-02 22:16   ` Sean Christopherson
2026-10-03  5:45     ` Ritesh Harjani
2026-09-22 18:28 ` [PATCH v5 6/9] KVM: selftests: Limit the number of VM creates in hardware_disable_test Ritesh Harjani (IBM)
2026-10-02 22:19   ` Sean Christopherson
2026-10-03  6:01     ` Ritesh Harjani
2026-09-22 18:28 ` [PATCH v5 7/9] KVM: PPC: selftests: Make nested case on pseries LPARs as resource constrained Ritesh Harjani (IBM)
2026-09-22 18:28 ` [PATCH v5 8/9] KVM: PPC: selftests: Skip idle-page check when running nested on pseries LPAR Ritesh Harjani (IBM)
2026-09-22 18:28 ` [PATCH v5 9/9] KVM: selftests: Move memslot_perf_test off the 256M ELF load address Ritesh Harjani (IBM)
2026-10-02 22:28   ` Sean Christopherson
2026-09-29  1:35 ` [PATCH v5 0/9] KVM: selftests: add powerpc support Ritesh Harjani
2026-10-02 22:38   ` Sean Christopherson
2026-10-03  6:46     ` Ritesh Harjani
2026-10-05  2:39       ` Sean Christopherson
2026-10-05  4:25         ` Ritesh Harjani
2026-10-05  6:08           ` Sean Christopherson [this message]
2026-09-29  5:49 ` Anushree Mathur

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=asM-1-ptu1b_URqR@google.com \
    --to=seanjc@google.com \
    --cc=anushree.mathur@linux.ibm.com \
    --cc=chleroy@kernel.org \
    --cc=harshpb@linux.ibm.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=maddy@linux.ibm.com \
    --cc=mpe@ellerman.id.au \
    --cc=pbonzini@redhat.com \
    --cc=ritesh.list@gmail.com \
    --cc=sshegde@linux.ibm.com \
    --cc=venkat88@linux.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®