diff options
author | davidwang <davidwang@zhaoxin.com> | 2018-04-13 15:03:03 +0800 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2018-04-21 00:59:03 +0800 |
commit | 49d1179573c0286474d92529544ad3a1349d15df (patch) | |
tree | 95f5e8937bd204de5a94b07c6d35d30da15e002b /drivers/char/hw_random | |
parent | b2b4f84d9cb2b723fdf5e05401c43d82836fec2f (diff) | |
download | linux-49d1179573c0286474d92529544ad3a1349d15df.tar.gz linux-49d1179573c0286474d92529544ad3a1349d15df.tar.bz2 linux-49d1179573c0286474d92529544ad3a1349d15df.zip |
hwrng: via - support new Centaur CPU
New Centaur CPU(Family > 6) supprt Random Number Generator, but can't
support MSR_VIA_RNG. Just like VIA Nano.
Signed-off-by: David Wang <davidwang@zhaoxin.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/char/hw_random')
-rw-r--r-- | drivers/char/hw_random/via-rng.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/char/hw_random/via-rng.c b/drivers/char/hw_random/via-rng.c index 6e9df558325b..ffe9b0c6c647 100644 --- a/drivers/char/hw_random/via-rng.c +++ b/drivers/char/hw_random/via-rng.c @@ -135,7 +135,7 @@ static int via_rng_init(struct hwrng *rng) * is always enabled if CPUID rng_en is set. There is no * RNG configuration like it used to be the case in this * register */ - if ((c->x86 == 6) && (c->x86_model >= 0x0f)) { + if (((c->x86 == 6) && (c->x86_model >= 0x0f)) || (c->x86 > 6)){ if (!boot_cpu_has(X86_FEATURE_XSTORE_EN)) { pr_err(PFX "can't enable hardware RNG " "if XSTORE is not enabled\n"); |