[<prev] [next>] [day] [month] [year] [list]
Message-Id: <1561551466-13173-1-git-send-email-pbonzini@redhat.com>
Date: Wed, 26 Jun 2019 14:17:46 +0200
From: Paolo Bonzini <pbonzini@...hat.com>
To: linux-kernel@...r.kernel.org, kvm@...r.kernel.org
Cc: Alexander Potapenko <glider@...gle.com>
Subject: [PATCH] KVM: x86: degrade WARN to pr_warn_ratelimited
This warning can be triggered easily by userspace, so it should certainly not
cause a panic if panic_on_warn is set.
Suggested-by: Alexander Potapenko <glider@...gle.com>
Signed-off-by: Paolo Bonzini <pbonzini@...hat.com>
---
arch/x86/kvm/x86.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index 83aefd759846..31cdb0b8d418 100644
--- a/arch/x86/kvm/x86.c
+++ b/arch/x86/kvm/x86.c
@@ -1557,7 +1557,7 @@ static int set_tsc_khz(struct kvm_vcpu *vcpu, u32 user_tsc_khz, bool scale)
vcpu->arch.tsc_always_catchup = 1;
return 0;
} else {
- WARN(1, "user requested TSC rate below hardware speed\n");
+ pr_warn_ratelimited(1, "user requested TSC rate below hardware speed\n");
return -1;
}
}
--
1.8.3.1
Powered by blists - more mailing lists