public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Sean Christopherson <seanjc@google.com>
To: Dan Wu <dan1.wu@intel.com>
Cc: pbonzini@redhat.com, kvm@vger.kernel.org, xiaoyao.li@intel.com
Subject: Re: [kvm-unit-tests PATCH v1 0/3] x86: fix async page fault issues
Date: Tue, 12 Dec 2023 07:17:16 -0800	[thread overview]
Message-ID: <ZXh5fJonSWLcHmkN@google.com> (raw)
In-Reply-To: <20231212062708.16509-1-dan1.wu@intel.com>

On Tue, Dec 12, 2023, Dan Wu wrote:
> When running asyncpf test, it gets skipped without a clear reason:
> 
>     ./asyncpf
> 
>     enabling apic
>     smp: waiting for 0 APs
>     paging enabled
>     cr0 = 80010011
>     cr3 = 107f000
>     cr4 = 20
>     install handler
>     enable async pf
>     alloc memory
>     start loop
>     end loop
>     start loop
>     end loop
>     SUMMARY: 0 tests
>     SKIP asyncpf (0 tests)
> 
> The reason is that KVM changed to use interrupt-based 'page-ready' notification
> and abandoned #PF-based 'page-ready' notification mechanism. Interrupt-based
> 'page-ready' notification requires KVM_ASYNC_PF_DELIVERY_AS_INT to be set as well
> in MSR_KVM_ASYNC_PF_EN to enable asyncpf.
> 
> This series tries to fix the problem by separating two testcases for different mechanisms.
> 
> - For old #PF-based notification, changes current asyncpf.c to add CPUID check
>   at the beginning. It checks (KVM_FEATURE_ASYNC_PF && !KVM_FEATURE_ASYNC_PF_INT),
>   otherwise it gets skipped.
> 
> - For new interrupt-based notification, add a new test, asyncpf-int.c, to check
>   (KVM_FEATURE_ASYNC_PF && KVM_FEATURE_ASYNC_PF_INT) and implement interrupt-based
>   'page-ready' handler.

Using #PF to deliver page-ready is completely dead, no?  Unless I'm mistaken, let's
just drop the existing support and replace it with the interrupted-based mechanism.
I see no reason to continue maintaining the old crud.  If someone wants to verify
an old, broken KVM, then they can use the old version of KUT.

  parent reply	other threads:[~2023-12-12 15:17 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-12  6:27 [kvm-unit-tests PATCH v1 0/3] x86: fix async page fault issues Dan Wu
2023-12-12  6:27 ` [kvm-unit-tests PATCH v1 1/3] x86: Add a common header asyncpf.h Dan Wu
2023-12-12  6:27 ` [kvm-unit-tests PATCH v1 2/3] x86: Add async page fault int test Dan Wu
2023-12-12  6:27 ` [kvm-unit-tests PATCH v1 3/3] x86/asyncpf: Add CPUID feature bits check to ensure feature is available Dan Wu
2023-12-12 15:17 ` Sean Christopherson [this message]
2023-12-13  1:36   ` [kvm-unit-tests PATCH v1 0/3] x86: fix async page fault issues Wu, Dan1
2023-12-13 18:20     ` Sean Christopherson
2023-12-14  2:32       ` Wu, Dan1

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=ZXh5fJonSWLcHmkN@google.com \
    --to=seanjc@google.com \
    --cc=dan1.wu@intel.com \
    --cc=kvm@vger.kernel.org \
    --cc=pbonzini@redhat.com \
    --cc=xiaoyao.li@intel.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