Lines Matching refs:cpu
104 void xen_setup_runstate_info(int cpu) in xen_setup_runstate_info() argument
108 area.addr.v = &per_cpu(xen_runstate, cpu); in xen_setup_runstate_info()
111 cpu, &area)) in xen_setup_runstate_info()
317 int cpu = smp_processor_id(); in xen_vcpuop_shutdown() local
319 if (HYPERVISOR_vcpu_op(VCPUOP_stop_singleshot_timer, cpu, NULL) || in xen_vcpuop_shutdown()
320 HYPERVISOR_vcpu_op(VCPUOP_stop_periodic_timer, cpu, NULL)) in xen_vcpuop_shutdown()
328 int cpu = smp_processor_id(); in xen_vcpuop_set_oneshot() local
330 if (HYPERVISOR_vcpu_op(VCPUOP_stop_periodic_timer, cpu, NULL)) in xen_vcpuop_set_oneshot()
339 int cpu = smp_processor_id(); in xen_vcpuop_set_next_event() local
348 ret = HYPERVISOR_vcpu_op(VCPUOP_set_singleshot_timer, cpu, &single); in xen_vcpuop_set_next_event()
396 void xen_teardown_timer(int cpu) in xen_teardown_timer() argument
399 BUG_ON(cpu == 0); in xen_teardown_timer()
400 evt = &per_cpu(xen_clock_events, cpu).evt; in xen_teardown_timer()
408 void xen_setup_timer(int cpu) in xen_setup_timer() argument
410 struct xen_clock_event_device *xevt = &per_cpu(xen_clock_events, cpu); in xen_setup_timer()
414 WARN(evt->irq >= 0, "IRQ%d for CPU%d is already allocated\n", evt->irq, cpu); in xen_setup_timer()
416 xen_teardown_timer(cpu); in xen_setup_timer()
418 printk(KERN_INFO "installing Xen timer for CPU %d\n", cpu); in xen_setup_timer()
420 snprintf(xevt->name, sizeof(xevt->name), "timer%d", cpu); in xen_setup_timer()
422 irq = bind_virq_to_irqhandler(VIRQ_TIMER, cpu, xen_timer_interrupt, in xen_setup_timer()
430 evt->cpumask = cpumask_of(cpu); in xen_setup_timer()
442 int cpu; in xen_timer_resume() local
449 for_each_online_cpu(cpu) { in xen_timer_resume()
450 if (HYPERVISOR_vcpu_op(VCPUOP_stop_periodic_timer, cpu, NULL)) in xen_timer_resume()
461 int cpu = smp_processor_id(); in xen_time_init() local
470 if (HYPERVISOR_vcpu_op(VCPUOP_stop_periodic_timer, cpu, NULL) == 0) { in xen_time_init()
483 xen_setup_runstate_info(cpu); in xen_time_init()
484 xen_setup_timer(cpu); in xen_time_init()
509 int cpu = smp_processor_id(); in xen_hvm_setup_cpu_clockevents() local
510 xen_setup_runstate_info(cpu); in xen_hvm_setup_cpu_clockevents()