-/* $OpenBSD: machdep.c,v 1.649 2022/07/07 00:56:46 daniel Exp $ */
+/* $OpenBSD: machdep.c,v 1.650 2022/07/12 05:45:49 jsg Exp $ */
/* $NetBSD: machdep.c,v 1.214 1996/11/10 03:16:17 thorpej Exp $ */
/*-
u_int regs[4];
cpuid(0x80000000, regs);
- if (regs[0] >= 0x80000005)
- cpuid(0x80000005, ci->ci_amdcacheinfo);
-
if (regs[0] >= 0x80000006) {
- cpuid(0x80000006, ci->ci_extcacheinfo);
- cachesize = (ci->ci_extcacheinfo[2] >> 16);
+ cpuid(0x80000006, regs);
+ cachesize = (regs[2] >> 16);
}
}
}
if (vendor == CPUVENDOR_INTEL) {
- u_int regs[4];
/*
* PIII, Core Solo and Core Duo CPUs have known
* errata stating:
*/
if (ci->ci_family == 6 && ci->ci_model < 15)
ci->ci_feature_flags &= ~CPUID_PAT;
-
- if (cpuid_level >= 0x1) {
- cpuid(0x80000000, regs);
- if (regs[0] >= 0x80000006)
- cpuid(0x80000006, ci->ci_extcacheinfo);
- }
}
/* Remove leading, trailing and duplicated spaces from cpu_brandstr */
-/* $OpenBSD: cpu.h,v 1.175 2021/07/06 09:34:06 kettenis Exp $ */
+/* $OpenBSD: cpu.h,v 1.176 2022/07/12 05:45:49 jsg Exp $ */
/* $NetBSD: cpu.h,v 1.35 1996/05/05 19:29:26 christos Exp $ */
/*-
u_int32_t ci_feature_tpmflags; /* thermal & power bits */
u_int32_t cpu_class; /* CPU class */
u_int32_t ci_cflushsz; /* clflush cache-line size */
- u_int32_t ci_amdcacheinfo[4]; /* AMD cache info */
- u_int32_t ci_extcacheinfo[4]; /* Intel cache info */
int ci_inatomic;