[PATCH 1/1] cpu: msr: disabled test for non-Intel/AMD architectures
Colin Ian King
colin.king at canonical.com
Wed Dec 7 09:34:48 UTC 2011
On 07/12/11 09:25, Keng-Yu Lin wrote:
> Ack from me. and also tested building without an error.
> Since the patch is from Colin, it may make sense to count as two Acks.
Nah, I need 2 Acks like anyone else. :-)
> So the patch is applied in git://kernel.ubuntu.com/lexical/fwts.git
>
> 於 2011年12月06日 02:20, Colin King 提到:
>> From: Colin Ian King<colin.king at canonical.com>
>>
>> Signed-off-by: Colin Ian King<colin.king at canonical.com>
>> ---
>> src/cpu/msr/msr.c | 8 ++++++++
>> 1 files changed, 8 insertions(+), 0 deletions(-)
>>
>> diff --git a/src/cpu/msr/msr.c b/src/cpu/msr/msr.c
>> index d2c16a8..06a756f 100644
>> --- a/src/cpu/msr/msr.c
>> +++ b/src/cpu/msr/msr.c
>> @@ -19,6 +19,8 @@
>>
>> #include "fwts.h"
>>
>> +#ifdef FWTS_ARCH_INTEL
>> +
>> typedef void (*msr_callback_check)(fwts_framework *fw, uint64_t val);
>>
>> static int ncpus;
>> @@ -32,6 +34,10 @@ static int msr_init(fwts_framework *fw)
>> fwts_log_error(fw, "Cannot get CPU info");
>> return FWTS_ERROR;
>> }
>> + if (cpuinfo->vendor_id == NULL) {
>> + fwts_log_error(fw, "Cannot get CPU vendor_id");
>> + return FWTS_ERROR;
>> + }
>> intel_cpu = strstr(cpuinfo->vendor_id, "Intel") != NULL;
>> amd_cpu = strstr(cpuinfo->vendor_id, "AuthenticAMD") != NULL;
>>
>> @@ -555,3 +561,5 @@ static fwts_framework_ops msr_ops = {
>> };
>>
>> FWTS_REGISTER(msr,&msr_ops, FWTS_TEST_ANYTIME, FWTS_BATCH | FWTS_ROOT_PRIV);
>> +
>> +#endif
More information about the fwts-devel
mailing list