Lines Matching full:model

30 static struct op_x86_model_spec *model;  variable
42 u64 op_x86_get_ctrl(struct op_x86_model_spec const *model, in op_x86_get_ctrl() argument
56 event &= model->event_mask ? model->event_mask : 0xFF; in op_x86_get_ctrl()
67 model->check_ctrs(regs, this_cpu_ptr(&cpu_msrs)); in profile_exceptions_notify()
71 model->stop(this_cpu_ptr(&cpu_msrs)); in profile_exceptions_notify()
81 for (i = 0; i < model->num_counters; ++i) { in nmi_cpu_save_registers()
86 for (i = 0; i < model->num_controls; ++i) { in nmi_cpu_save_registers()
98 model->start(msrs); in nmi_cpu_start()
118 model->stop(msrs); in nmi_cpu_stop()
135 return !!model->switch_ctrl; in has_mux()
145 return virt % model->num_counters; in op_x86_virt_to_phys()
165 sizeof(struct op_msr) * model->num_virt_counters; in nmi_setup_mux()
189 for (i = 0; i < model->num_virt_counters; ++i) { in nmi_cpu_setup_mux()
206 for (i = 0; i < model->num_counters; ++i) { in nmi_cpu_save_mpx_registers()
219 for (i = 0; i < model->num_counters; ++i) { in nmi_cpu_restore_mpx_registers()
236 si += model->num_counters; in nmi_cpu_switch()
237 if ((si >= model->num_virt_counters) || (counter_config[si].count == 0)) in nmi_cpu_switch()
242 model->switch_ctrl(model, msrs); in nmi_cpu_switch()
256 return counter_config[model->num_counters].count ? 0 : -EINVAL; in nmi_multiplex_on()
287 sizeof(struct op_msr) * model->num_virt_counters); in mux_clone()
317 size_t controls_size = sizeof(struct op_msr) * model->num_controls; in allocate_msrs()
318 size_t counters_size = sizeof(struct op_msr) * model->num_counters; in allocate_msrs()
349 model->setup_ctrs(model, msrs); in nmi_cpu_setup()
362 for (i = 0; i < model->num_controls; ++i) { in nmi_cpu_restore_registers()
367 for (i = 0; i < model->num_counters; ++i) { in nmi_cpu_restore_registers()
417 for (i = 0; i < model->num_virt_counters; ++i) { in nmi_create_files()
458 err = model->fill_in_addresses(&per_cpu(cpu_msrs, 0)); in nmi_setup()
468 sizeof(struct op_msr) * model->num_counters); in nmi_setup()
472 sizeof(struct op_msr) * model->num_controls); in nmi_setup()
514 model->shutdown(msrs); in nmi_shutdown()
566 model = &op_p4_spec; in p4_init()
572 model = &op_p4_spec; in p4_init()
577 model = &op_p4_ht2_spec; in p4_init()
621 * and model can be found in the Intel Software Developer's in ppro_init()
669 model = spec; in ppro_init()
719 model = &op_amd_spec; in op_nmi_init()
746 model = &op_arch_perfmon_spec; in op_nmi_init()
753 /* default values, can be overwritten by model */ in op_nmi_init()
761 if (model->init) in op_nmi_init()
762 ret = model->init(ops); in op_nmi_init()
766 if (!model->num_virt_counters) in op_nmi_init()
767 model->num_virt_counters = model->num_counters; in op_nmi_init()