Lines Matching defs:cpu

430 	unsigned int cpu = smp_processor_id();
431 struct kvm_user_return_msrs *msrs = per_cpu_ptr(user_return_msrs, cpu);
444 unsigned int cpu = smp_processor_id();
445 struct kvm_user_return_msrs *msrs = per_cpu_ptr(user_return_msrs, cpu);
467 unsigned int cpu = smp_processor_id();
468 struct kvm_user_return_msrs *msrs = per_cpu_ptr(user_return_msrs, cpu);
3051 /* both __this_cpu_read() and rdtsc() should be on the same cpu */
3249 * vcpu->cpu migration, should not allow system_timestamp from
4809 void kvm_arch_vcpu_load(struct kvm_vcpu *vcpu, int cpu)
4814 cpumask_set_cpu(cpu, vcpu->arch.wbinvd_dirty_mask);
4815 else if (vcpu->cpu != -1 && vcpu->cpu != cpu)
4816 smp_call_function_single(vcpu->cpu,
4820 static_call(kvm_x86_vcpu_load)(vcpu, cpu);
4832 if (unlikely(vcpu->cpu != cpu) || kvm_check_tsc_unstable()) {
4850 * kvmclock on vcpu->cpu migration
4852 if (!vcpu->kvm->arch.use_master_clock || vcpu->cpu == -1)
4854 if (vcpu->cpu != cpu)
4856 vcpu->cpu = cpu;
7977 int cpu = get_cpu();
7979 cpumask_set_cpu(cpu, vcpu->arch.wbinvd_dirty_mask);
8592 * If the mapping is invalid in guest, let cpu retry
9174 static int kvmclock_cpu_down_prep(unsigned int cpu)
9200 int cpu;
9211 for_each_present_cpu(cpu)
9212 per_cpu(cpu_tsc_khz, cpu) = tsc_khz;
9226 static void __kvmclock_cpufreq_notifier(struct cpufreq_freqs *freq, int cpu)
9272 smp_call_function_single(cpu, tsc_khz_changed, freq, 1);
9277 if (vcpu->cpu != cpu)
9280 if (vcpu->cpu != raw_smp_processor_id())
9293 * In case we update the frequency for another cpu
9295 * to kick the cpu out of guest context. Next time
9299 smp_call_function_single(cpu, tsc_khz_changed, freq, 1);
9307 int cpu;
9314 for_each_cpu(cpu, freq->policy->cpus)
9315 __kvmclock_cpufreq_notifier(freq, cpu);
9324 static int kvmclock_cpu_online(unsigned int cpu)
9337 int cpu;
9339 cpu = get_cpu();
9340 policy = cpufreq_cpu_get(cpu);
9432 int cpu = smp_processor_id();
9433 struct cpuinfo_x86 *c = &cpu_data(cpu);
9441 WARN_ON(!cpu_online(cpu));
9458 int r, cpu;
9532 for_each_online_cpu(cpu) {
9533 smp_call_function_single(cpu, kvm_x86_check_cpu_compat, &r, 1);
10497 smp_send_reschedule(vcpu->cpu);
10819 vcpu->arch.last_vmentry_cpu = vcpu->cpu;
12206 if (!stable && vcpu->cpu == smp_processor_id())
12297 void kvm_arch_sched_in(struct kvm_vcpu *vcpu, int cpu)
12306 static_call(kvm_x86_sched_in)(vcpu, cpu);