qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] KVM: x86: expose new instruction RDSEED to guest
@ 2014-02-21 17:33 Liu, Jinsong
  2014-02-22 14:54 ` Paolo Bonzini
  0 siblings, 1 reply; 2+ messages in thread
From: Liu, Jinsong @ 2014-02-21 17:33 UTC (permalink / raw)
  To: Paolo Bonzini
  Cc: qemu-devel@nongnu.org, kvm@vger.kernel.org, gleb@redhat.com,
	linux-kernel@vger.kernel.org

>From 24ffdce9efebf13c6ed4882f714b2b57ef1141eb Mon Sep 17 00:00:00 2001
From: Liu Jinsong <jinsong.liu@intel.com>
Date: Thu, 20 Feb 2014 17:38:26 +0800
Subject: [PATCH] KVM: x86: expose new instruction RDSEED to guest

RDSEED instruction return a random number, which supplied by a
cryptographically secure, deterministic random bit generator(DRBG).

Signed-off-by: Xudong Hao <xudong.hao@intel.com>
Signed-off-by: Liu Jinsong <jinsong.liu@intel.com>
---
 arch/x86/kvm/cpuid.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/x86/kvm/cpuid.c b/arch/x86/kvm/cpuid.c
index c697625..abe18b4 100644
--- a/arch/x86/kvm/cpuid.c
+++ b/arch/x86/kvm/cpuid.c
@@ -303,7 +303,7 @@ static inline int __do_cpuid_ent(struct kvm_cpuid_entry2 *entry, u32 function,
 	/* cpuid 7.0.ebx */
 	const u32 kvm_supported_word9_x86_features =
 		F(FSGSBASE) | F(BMI1) | F(HLE) | F(AVX2) | F(SMEP) |
-		F(BMI2) | F(ERMS) | f_invpcid | F(RTM);
+		F(BMI2) | F(ERMS) | f_invpcid | F(RTM) | F(RDSEED);
 
 	/* all calls to cpuid_count() should be made on the same cpu */
 	get_cpu();
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Qemu-devel] [PATCH] KVM: x86: expose new instruction RDSEED to guest
  2014-02-21 17:33 [Qemu-devel] [PATCH] KVM: x86: expose new instruction RDSEED to guest Liu, Jinsong
@ 2014-02-22 14:54 ` Paolo Bonzini
  0 siblings, 0 replies; 2+ messages in thread
From: Paolo Bonzini @ 2014-02-22 14:54 UTC (permalink / raw)
  To: Liu, Jinsong
  Cc: qemu-devel@nongnu.org, kvm@vger.kernel.org, gleb@redhat.com,
	linux-kernel@vger.kernel.org

Il 21/02/2014 18:33, Liu, Jinsong ha scritto:
> From 24ffdce9efebf13c6ed4882f714b2b57ef1141eb Mon Sep 17 00:00:00 2001
> From: Liu Jinsong <jinsong.liu@intel.com>
> Date: Thu, 20 Feb 2014 17:38:26 +0800
> Subject: [PATCH] KVM: x86: expose new instruction RDSEED to guest
>
> RDSEED instruction return a random number, which supplied by a
> cryptographically secure, deterministic random bit generator(DRBG).
>
> Signed-off-by: Xudong Hao <xudong.hao@intel.com>
> Signed-off-by: Liu Jinsong <jinsong.liu@intel.com>
> ---
>  arch/x86/kvm/cpuid.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/arch/x86/kvm/cpuid.c b/arch/x86/kvm/cpuid.c
> index c697625..abe18b4 100644
> --- a/arch/x86/kvm/cpuid.c
> +++ b/arch/x86/kvm/cpuid.c
> @@ -303,7 +303,7 @@ static inline int __do_cpuid_ent(struct kvm_cpuid_entry2 *entry, u32 function,
>  	/* cpuid 7.0.ebx */
>  	const u32 kvm_supported_word9_x86_features =
>  		F(FSGSBASE) | F(BMI1) | F(HLE) | F(AVX2) | F(SMEP) |
> -		F(BMI2) | F(ERMS) | f_invpcid | F(RTM);
> +		F(BMI2) | F(ERMS) | f_invpcid | F(RTM) | F(RDSEED);
>
>  	/* all calls to cpuid_count() should be made on the same cpu */
>  	get_cpu();
>

Applied to kvm/queue, thanks.

Paolo

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-02-22 14:55 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-21 17:33 [Qemu-devel] [PATCH] KVM: x86: expose new instruction RDSEED to guest Liu, Jinsong
2014-02-22 14:54 ` Paolo Bonzini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).