Re: [PATCH 6/7] x86, lib: Add wbinvd and wbnoinvd helpers to target multiple CPUs

Huang, Kai
2025-03-13T10:20:11Z

On Wed, 2025-02-26 at 17:48 -0800, Sean Christopherson wrote:
> From: Zheyun Shen <szy0127@sjtu.edu.cn>
>
> Extract KVM's open-coded calls to do writeback caches on multiple CPUs to
> common library helpers for both WBINVD and WBNOINVD (KVM will use both).
> Put the onus on the caller to check for a non-empty mask to simplify the
> SMP=n implementation, e.g. so that it doesn't need to check that the one
> and only CPU in the system is present in the mask.
>
> Signed-off-by: Zheyun Shen <szy0127@sjtu.edu.cn>
> Reviewed-by: Tom Lendacky <thomas.lendacky@amd.com>
> Link: https://lore.kernel.org/r/20250128015345.7929-2-szy0127@sjtu.edu.cn
> [sean: move to lib, add SMP=n helpers, clarify usage]
> Signed-off-by: Sean Christopherson <seanjc@google.com>

Assume the issue pointed by Zheyun will be addressed:

Acked-by: Kai Huang <kai.huang@intel.com>