Re: [PATCH v14] high_freq_hwp_cap_cppc.c: new test
Cyril Hrubis <[email protected]>
| Newsgroups | gmane.linux.ltp |
|---|---|
| Message-ID | <[email protected]> |
Hi!
> +static void setup(void)
> +{
> + unsigned int eax, ebx, ecx, edx;
> +
> + __cpuid_count(0, 0, eax, ebx, ecx, edx);
> + if (ebx != CPUID_VENDOR_EBX || edx != CPUID_VENDOR_EDX ||
> + ecx != CPUID_VENDOR_ECX)
> + tst_brk(TCONF, "not a GenuineIntel CPU");
I've send a patch for the tst_test structure that adds .needs_cpu_vendor
field. If that gets merged you can just set it to "GenuineIntel" and the
test should be automatically skipped on anything but Intel CPUs.
> + __cpuid_count(CPUID_LEAF_THERMAL, 0, eax, ebx, ecx, edx);
> + if (!(eax & CPUID_HWP_BIT))
> + tst_brk(TCONF, "HWP not supported (MSR 0x771 unavailable)");
This specific check still needs to be ifdefed around with x86 and x86_64
macros.
--
Cyril Hrubis
[email protected]
--
Mailing list info: https://lists.linux.it/listinfo/ltp