/tools/testing/selftests/kvm/x86_64/ |
D | get_cpuid_test.c | 39 cpuid(&eax, &ebx, &ecx, &edx); in test_guest_cpuids() 53 cpuid(&eax, &ebx, &ecx, &edx); in test_cpuid_40000000() 84 static void check_cpuid(struct kvm_cpuid2 *cpuid, struct kvm_cpuid_entry2 *entrie) in check_cpuid() argument 88 for (i = 0; i < cpuid->nent; i++) { in check_cpuid() 89 if (cpuid->entries[i].function == entrie->function && in check_cpuid() 90 cpuid->entries[i].index == entrie->index) { in check_cpuid() 94 TEST_ASSERT(cpuid->entries[i].eax == entrie->eax && in check_cpuid() 95 cpuid->entries[i].ebx == entrie->ebx && in check_cpuid() 96 cpuid->entries[i].ecx == entrie->ecx && in check_cpuid() 97 cpuid->entries[i].edx == entrie->edx, in check_cpuid() [all …]
|
D | vmx_pmu_msrs_test.c | 60 struct kvm_cpuid2 *cpuid; in main() local 74 cpuid = kvm_get_supported_cpuid(); in main() 92 vcpu_set_cpuid(vm, VCPU_ID, cpuid); in main() 115 vcpu_set_cpuid(vm, VCPU_ID, cpuid); in main() 123 vcpu_set_cpuid(vm, VCPU_ID, cpuid); in main()
|
D | vmx_set_nested_state_test.c | 249 struct kvm_cpuid2 *cpuid = kvm_get_supported_cpuid(); in disable_vmx() local 252 for (i = 0; i < cpuid->nent; ++i) in disable_vmx() 253 if (cpuid->entries[i].function == 1 && in disable_vmx() 254 cpuid->entries[i].index == 0) in disable_vmx() 256 TEST_ASSERT(i != cpuid->nent, "CPUID function 1 not found"); in disable_vmx() 258 cpuid->entries[i].ecx &= ~CPUID_VMX; in disable_vmx() 259 vcpu_set_cpuid(vm, VCPU_ID, cpuid); in disable_vmx() 260 cpuid->entries[i].ecx |= CPUID_VMX; in disable_vmx()
|
D | hyperv_cpuid.c | 115 static struct kvm_cpuid2 cpuid = {.nent = 0}; in test_hv_cpuid_e2big() local 119 ret = _vcpu_ioctl(vm, VCPU_ID, KVM_GET_SUPPORTED_HV_CPUID, &cpuid); in test_hv_cpuid_e2big() 121 ret = _kvm_ioctl(vm, KVM_GET_SUPPORTED_HV_CPUID, &cpuid); in test_hv_cpuid_e2big()
|
D | emulator_error_test.c | 170 struct kvm_cpuid2 *cpuid; in main() local 186 cpuid = kvm_get_supported_cpuid(); in main() 190 set_cpuid(cpuid, entry); in main() 192 vcpu_set_cpuid(vm, VCPU_ID, cpuid); in main()
|
D | hyperv_features.c | 154 static void hv_set_cpuid(struct kvm_vm *vm, struct kvm_cpuid2 *cpuid, in hv_set_cpuid() argument 159 TEST_ASSERT(set_cpuid(cpuid, feat), in hv_set_cpuid() 161 TEST_ASSERT(set_cpuid(cpuid, recomm), in hv_set_cpuid() 163 TEST_ASSERT(set_cpuid(cpuid, dbg), in hv_set_cpuid() 165 vcpu_set_cpuid(vm, VCPU_ID, cpuid); in hv_set_cpuid()
|
D | kvm_pv_test.c | 145 static void clear_kvm_cpuid_features(struct kvm_cpuid2 *cpuid) in clear_kvm_cpuid_features() argument 150 TEST_ASSERT(set_cpuid(cpuid, &ent), in clear_kvm_cpuid_features()
|
/tools/perf/util/ |
D | sample-raw.c | 17 const char *cpuid = perf_env__cpuid(evlist->env); in evlist__init_trace_event_sample_raw() local 22 cpuid && strstarts(cpuid, "AuthenticAMD") && in evlist__init_trace_event_sample_raw()
|
D | env.c | 204 zfree(&env->cpuid); in perf_env__exit() 368 char cpuid[128]; in perf_env__read_cpuid() local 369 int err = get_cpuid(cpuid, sizeof(cpuid)); in perf_env__read_cpuid() 374 free(env->cpuid); in perf_env__read_cpuid() 375 env->cpuid = strdup(cpuid); in perf_env__read_cpuid() 376 if (env->cpuid == NULL) in perf_env__read_cpuid() 468 if (!env || !env->cpuid) { /* Assume local operation */ in perf_env__cpuid() 474 return env->cpuid; in perf_env__cpuid()
|
D | amd-sample-raw.c | 246 const char *cpuid; in parse_cpuid() local 249 cpuid = perf_env__cpuid(env); in parse_cpuid() 253 ret = sscanf(cpuid, "%*[^,],%u,%u", &cpu_family, &cpu_model); in parse_cpuid()
|
/tools/testing/selftests/kvm/lib/x86_64/ |
D | processor.c | 659 struct kvm_cpuid2 *cpuid; in allocate_kvm_cpuid2() local 663 size = sizeof(*cpuid); in allocate_kvm_cpuid2() 665 cpuid = malloc(size); in allocate_kvm_cpuid2() 666 if (!cpuid) { in allocate_kvm_cpuid2() 671 cpuid->nent = nent; in allocate_kvm_cpuid2() 673 return cpuid; in allocate_kvm_cpuid2() 689 static struct kvm_cpuid2 *cpuid; in kvm_get_supported_cpuid() local 693 if (cpuid) in kvm_get_supported_cpuid() 694 return cpuid; in kvm_get_supported_cpuid() 696 cpuid = allocate_kvm_cpuid2(); in kvm_get_supported_cpuid() [all …]
|
/tools/arch/x86/kcpuid/ |
D | Makefile | 24 install -m 444 -p cpuid.csv $(HWDATADIR)/cpuid.csv
|
D | kcpuid.c | 84 static inline void cpuid(u32 *eax, u32 *ebx, u32 *ecx, u32 *edx) in cpuid() function 217 cpuid(&eax, &ebx, &ecx, &edx); in setup_cpuid_range() 241 cpuid(&eax, &ebx, &ecx, &edx); in setup_cpuid_range() 266 cpuid(&eax, &ebx, &ecx, &edx); in setup_cpuid_range() 557 cpuid(&eax, &ebx, &ecx, &edx); in setup_platform_cpuid()
|
/tools/perf/arch/s390/annotate/ |
D | instructions.c | 139 static int s390__cpuid_parse(struct arch *arch, char *cpuid) in s390__cpuid_parse() argument 149 ret = sscanf(cpuid, "%*[^,],%u,%[^,],%[^,],%[^,],%s", &family, model_c, in s390__cpuid_parse() 160 static int s390__annotate_init(struct arch *arch, char *cpuid __maybe_unused) in s390__annotate_init() 167 if (cpuid) { in s390__annotate_init() 168 if (s390__cpuid_parse(arch, cpuid)) in s390__annotate_init()
|
/tools/perf/arch/x86/util/ |
D | header.c | 14 cpuid(unsigned int op, unsigned int *a, unsigned int *b, unsigned int *c, in cpuid() function 34 cpuid(0, &lvl, &b, &c, &d); in __get_cpuid() 41 cpuid(1, &a, &b, &c, &d); in __get_cpuid()
|
D | kvm-stat.c | 202 int cpu_isa_init(struct perf_kvm_stat *kvm, const char *cpuid) in cpu_isa_init() argument 204 if (strstr(cpuid, "Intel")) { in cpu_isa_init() 207 } else if (strstr(cpuid, "AMD") || strstr(cpuid, "Hygon")) { in cpu_isa_init()
|
/tools/power/cpupower/debug/i386/ |
D | dump_psb.c | 50 u_int32_t cpuid; member 115 if (relevant!= pst->cpuid) in decode_psb() 121 pst->cpuid, in decode_psb()
|
/tools/perf/arch/x86/annotate/ |
D | instructions.c | 175 static int x86__cpuid_parse(struct arch *arch, char *cpuid) in x86__cpuid_parse() argument 183 ret = sscanf(cpuid, "%*[^,],%u,%u,%u", &family, &model, &stepping); in x86__cpuid_parse() 193 static int x86__annotate_init(struct arch *arch, char *cpuid) in x86__annotate_init() argument 200 if (cpuid) { in x86__annotate_init() 201 if (x86__cpuid_parse(arch, cpuid)) in x86__annotate_init()
|
/tools/perf/arch/arc/annotate/ |
D | instructions.c | 4 static int arc__annotate_init(struct arch *arch, char *cpuid __maybe_unused) in arc__annotate_init()
|
/tools/perf/arch/s390/util/ |
D | kvm-stat.c | 102 int cpu_isa_init(struct perf_kvm_stat *kvm, const char *cpuid) in cpu_isa_init() argument 104 if (strstr(cpuid, "IBM")) { in cpu_isa_init()
|
/tools/perf/pmu-events/ |
D | pmu-events.h | 41 const char *cpuid; member
|
/tools/perf/arch/csky/annotate/ |
D | instructions.c | 41 static int csky__annotate_init(struct arch *arch, char *cpuid __maybe_unused) in csky__annotate_init()
|
/tools/perf/arch/mips/annotate/ |
D | instructions.c | 37 int mips__annotate_init(struct arch *arch, char *cpuid __maybe_unused) in mips__annotate_init()
|
/tools/perf/arch/powerpc/annotate/ |
D | instructions.c | 52 static int powerpc__annotate_init(struct arch *arch, char *cpuid __maybe_unused) in powerpc__annotate_init()
|
/tools/perf/arch/arm/annotate/ |
D | instructions.c | 30 static int arm__annotate_init(struct arch *arch, char *cpuid __maybe_unused) in arm__annotate_init()
|