diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2015-12-05 10:27:49 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2015-12-05 10:27:49 +0000 |
commit | ab9d400e9233c6ffc2eb7029dfe9aecc1d3cf7e0 (patch) | |
tree | 219123081581df5462629862a295ae4b8a966962 /sys/arch | |
parent | 3e81254e500f4f19d60302c9dafafdcc3427d206 (diff) |
AMD Family 12h and later processors keep their APIC clock running in deeper
C-states. Set the TMP_ARAT flag for these (which is Intel-specific) such
that acpicpu(4) enables the deeper C-states on these CPUs.
ok deraadt@
Diffstat (limited to 'sys/arch')
-rw-r--r-- | sys/arch/amd64/amd64/identcpu.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/arch/amd64/amd64/identcpu.c b/sys/arch/amd64/amd64/identcpu.c index aa2437ea504..185b64dcfd6 100644 --- a/sys/arch/amd64/amd64/identcpu.c +++ b/sys/arch/amd64/amd64/identcpu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: identcpu.c,v 1.67 2015/11/23 22:57:12 deraadt Exp $ */ +/* $OpenBSD: identcpu.c,v 1.68 2015/12/05 10:27:48 kettenis Exp $ */ /* $NetBSD: identcpu.c,v 1.1 2003/04/26 18:39:28 fvdl Exp $ */ /* @@ -545,12 +545,15 @@ identifycpu(struct cpu_info *ci) printf(",%s", cpu_seff0_ecxfeatures[i].str); } - if (!strcmp(cpu_vendor, "GenuineIntel") && cpuid_level >= 0x06 ) { + if (!strcmp(cpu_vendor, "GenuineIntel") && cpuid_level >= 0x06) { CPUID(0x06, ci->ci_feature_tpmflags, dummy, dummy, dummy); for (i = 0; i < nitems(cpu_tpm_eaxfeatures); i++) if (ci->ci_feature_tpmflags & cpu_tpm_eaxfeatures[i].bit) printf(",%s", cpu_tpm_eaxfeatures[i].str); + } else if (!strcmp(cpu_vendor, "AuthenticAMD")) { + if (ci->ci_family >= 0x12) + ci->ci_feature_tpmflags |= TPM_ARAT; } printf("\n"); |