Message ID | 97bf2743f3a302b3066aced02218b9da60690dd3.1681854412.git.christophe.jaillet@wanadoo.fr (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [1/2] KVM: arm64: Slightly optimize flush_context() | expand |
On Tue, 18 Apr 2023 23:47:37 +0200, Christophe JAILLET wrote: > bitmap_zero() is faster than bitmap_clear(), so use it to save a few > cycles. Applied to next, thanks! [1/2] KVM: arm64: Slightly optimize flush_context() commit: 4be8ddb48b1b6c6067fb59c846b9c6e19d6efe14 [2/2] KVM: arm64: Use the bitmap API to allocate bitmaps commit: a00e9e4319c2a8a8b166da028292de83190e39a4 Cheers, M.
diff --git a/arch/arm64/kvm/vmid.c b/arch/arm64/kvm/vmid.c index 08978d0672e7..bbf0677cfefa 100644 --- a/arch/arm64/kvm/vmid.c +++ b/arch/arm64/kvm/vmid.c @@ -47,7 +47,7 @@ static void flush_context(void) int cpu; u64 vmid; - bitmap_clear(vmid_map, 0, NUM_USER_VMIDS); + bitmap_zero(vmid_map, NUM_USER_VMIDS); for_each_possible_cpu(cpu) { vmid = atomic64_xchg_relaxed(&per_cpu(active_vmids, cpu), 0);
bitmap_zero() is faster than bitmap_clear(), so use it to save a few cycles. Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> --- arch/arm64/kvm/vmid.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)