* [PATCH v1] KVM: arm64: Use the known cpu id instead of smp_processor_id()
@ 2023-07-27 9:07 Shaoqin Huang
2023-07-28 11:04 ` Marc Zyngier
0 siblings, 1 reply; 2+ messages in thread
From: Shaoqin Huang @ 2023-07-27 9:07 UTC (permalink / raw)
To: kvmarm
Cc: Shaoqin Huang, Marc Zyngier, Oliver Upton, James Morse,
Suzuki K Poulose, Zenghui Yu, Catalin Marinas, Will Deacon,
linux-arm-kernel, linux-kernel
In kvm_arch_vcpu_load(), it has the parameter cpu which is the value of
smp_processor_id(), so no need to get it again. Simply replace it.
Signed-off-by: Shaoqin Huang <shahuang@redhat.com>
---
arch/arm64/kvm/arm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm64/kvm/arm.c b/arch/arm64/kvm/arm.c
index c2c14059f6a8..2e5d8f4b902b 100644
--- a/arch/arm64/kvm/arm.c
+++ b/arch/arm64/kvm/arm.c
@@ -457,7 +457,7 @@ void kvm_arch_vcpu_load(struct kvm_vcpu *vcpu, int cpu)
vcpu_ptrauth_disable(vcpu);
kvm_arch_vcpu_load_debug_state_flags(vcpu);
- if (!cpumask_test_cpu(smp_processor_id(), vcpu->kvm->arch.supported_cpus))
+ if (!cpumask_test_cpu(cpu, vcpu->kvm->arch.supported_cpus))
vcpu_set_on_unsupported_cpu(vcpu);
}
--
2.39.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH v1] KVM: arm64: Use the known cpu id instead of smp_processor_id()
2023-07-27 9:07 [PATCH v1] KVM: arm64: Use the known cpu id instead of smp_processor_id() Shaoqin Huang
@ 2023-07-28 11:04 ` Marc Zyngier
0 siblings, 0 replies; 2+ messages in thread
From: Marc Zyngier @ 2023-07-28 11:04 UTC (permalink / raw)
To: kvmarm, Shaoqin Huang
Cc: Will Deacon, Oliver Upton, Catalin Marinas, Suzuki K Poulose,
James Morse, Zenghui Yu, linux-arm-kernel, linux-kernel
On Thu, 27 Jul 2023 05:07:54 -0400, Shaoqin Huang wrote:
> In kvm_arch_vcpu_load(), it has the parameter cpu which is the value of
> smp_processor_id(), so no need to get it again. Simply replace it.
Applied to next, thanks!
[1/1] KVM: arm64: Use the known cpu id instead of smp_processor_id()
commit: 1ba11daef0a9b062e40b5393d285c82ab6483730
Cheers,
M.
--
Without deviation from the norm, progress is not possible.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-07-28 11:04 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-27 9:07 [PATCH v1] KVM: arm64: Use the known cpu id instead of smp_processor_id() Shaoqin Huang
2023-07-28 11:04 ` Marc Zyngier
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®