Lines Matching refs:cpu

249 static void smp_start_sync_tick_client(int cpu);
251 static void smp_synchronize_one_tick(int cpu) in smp_synchronize_one_tick() argument
257 smp_start_sync_tick_client(cpu); in smp_synchronize_one_tick()
282 static void ldom_startcpu_cpuid(unsigned int cpu, unsigned long thread_reg, in ldom_startcpu_cpuid() argument
305 hdesc->cpu = cpu; in ldom_startcpu_cpuid()
308 tb = &trap_block[cpu]; in ldom_startcpu_cpuid()
327 hv_err = sun4v_cpu_start(cpu, trampoline_ra, in ldom_startcpu_cpuid()
344 static int smp_boot_one_cpu(unsigned int cpu, struct task_struct *idle) in smp_boot_one_cpu() argument
359 ldom_startcpu_cpuid(cpu, in smp_boot_one_cpu()
364 prom_startcpu_cpuid(cpu, entry, cookie); in smp_boot_one_cpu()
366 struct device_node *dp = of_find_node_by_cpuid(cpu); in smp_boot_one_cpu()
380 printk("Processor %d is stuck.\n", cpu); in smp_boot_one_cpu()
390 static void spitfire_xcall_helper(u64 data0, u64 data1, u64 data2, u64 pstate, unsigned long cpu) in spitfire_xcall_helper() argument
397 cpu = (((cpu & 0x3c) << 1) | in spitfire_xcall_helper()
398 ((cpu & 0x40) >> 4) | in spitfire_xcall_helper()
399 (cpu & 0x3)); in spitfire_xcall_helper()
402 target = (cpu << 14) | 0x70; in spitfire_xcall_helper()
669 u16 cpu; in hypervisor_xcall_deliver() local
671 cpu = cpu_list[i]; in hypervisor_xcall_deliver()
672 if (cpu == 0xffff) in hypervisor_xcall_deliver()
675 err = sun4v_cpu_state(cpu); in hypervisor_xcall_deliver()
677 saw_cpu_error = (cpu + 1); in hypervisor_xcall_deliver()
799 static void smp_start_sync_tick_client(int cpu) in smp_start_sync_tick_client() argument
802 cpumask_of(cpu)); in smp_start_sync_tick_client()
814 void arch_send_call_function_single_ipi(int cpu) in arch_send_call_function_single_ipi() argument
817 cpumask_of(cpu)); in arch_send_call_function_single_ipi()
886 void smp_flush_dcache_page_impl(struct page *page, int cpu) in smp_flush_dcache_page_impl() argument
899 if (cpu == this_cpu) { in smp_flush_dcache_page_impl()
901 } else if (cpu_online(cpu)) { in smp_flush_dcache_page_impl()
916 (u64) pg_addr, cpumask_of(cpu)); in smp_flush_dcache_page_impl()
1060 int cpu = get_cpu(); in smp_flush_tlb_mm() local
1063 cpumask_copy(mm_cpumask(mm), cpumask_of(cpu)); in smp_flush_tlb_mm()
1094 int cpu = get_cpu(); in smp_flush_tlb_pending() local
1101 cpumask_copy(mm_cpumask(mm), cpumask_of(cpu)); in smp_flush_tlb_pending()
1114 int cpu = get_cpu(); in smp_flush_tlb_page() local
1117 cpumask_copy(mm_cpumask(mm), cpumask_of(cpu)); in smp_flush_tlb_page()
1276 int __cpu_up(unsigned int cpu, struct task_struct *tidle) in __cpu_up() argument
1278 int ret = smp_boot_one_cpu(cpu, tidle); in __cpu_up()
1281 cpumask_set_cpu(cpu, &smp_commenced_mask); in __cpu_up()
1282 while (!cpu_online(cpu)) in __cpu_up()
1284 if (!cpu_online(cpu)) { in __cpu_up()
1291 smp_synchronize_one_tick(cpu); in __cpu_up()
1300 int cpu = smp_processor_id(); in cpu_play_dead() local
1306 struct trap_per_cpu *tb = &trap_block[cpu]; in cpu_play_dead()
1318 cpumask_clear_cpu(cpu, &smp_commenced_mask); in cpu_play_dead()
1335 int cpu = smp_processor_id(); in __cpu_disable() local
1339 for_each_cpu(i, &cpu_core_map[cpu]) in __cpu_disable()
1340 cpumask_clear_cpu(cpu, &cpu_core_map[i]); in __cpu_disable()
1341 cpumask_clear(&cpu_core_map[cpu]); in __cpu_disable()
1343 for_each_cpu(i, &per_cpu(cpu_sibling_map, cpu)) in __cpu_disable()
1344 cpumask_clear_cpu(cpu, &per_cpu(cpu_sibling_map, i)); in __cpu_disable()
1345 cpumask_clear(&per_cpu(cpu_sibling_map, cpu)); in __cpu_disable()
1347 c = &cpu_data(cpu); in __cpu_disable()
1361 set_cpu_online(cpu, false); in __cpu_disable()
1368 void __cpu_die(unsigned int cpu) in __cpu_die() argument
1374 if (!cpumask_test_cpu(cpu, &smp_commenced_mask)) in __cpu_die()
1378 if (cpumask_test_cpu(cpu, &smp_commenced_mask)) { in __cpu_die()
1379 printk(KERN_ERR "CPU %u didn't die...\n", cpu); in __cpu_die()
1386 hv_err = sun4v_cpu_stop(cpu); in __cpu_die()
1388 set_cpu_present(cpu, false); in __cpu_die()
1405 void smp_send_reschedule(int cpu) in smp_send_reschedule() argument
1407 if (cpu == smp_processor_id()) { in smp_send_reschedule()
1412 0, 0, cpumask_of(cpu)); in smp_send_reschedule()
1429 int cpu; in smp_send_stop() local
1432 for_each_online_cpu(cpu) { in smp_send_stop()
1433 if (cpu == smp_processor_id()) in smp_send_stop()
1438 hv_err = sun4v_cpu_stop(cpu); in smp_send_stop()
1444 prom_stopcpu_cpuid(cpu); in smp_send_stop()
1463 static void * __init pcpu_alloc_bootmem(unsigned int cpu, size_t size, in pcpu_alloc_bootmem() argument
1468 int node = cpu_to_node(cpu); in pcpu_alloc_bootmem()
1474 cpu, node); in pcpu_alloc_bootmem()
1476 cpu, size, __pa(ptr)); in pcpu_alloc_bootmem()
1481 "%016lx\n", cpu, size, node, __pa(ptr)); in pcpu_alloc_bootmem()
1535 unsigned int cpu; in setup_per_cpu_areas() local
1558 for_each_possible_cpu(cpu) in setup_per_cpu_areas()
1559 __per_cpu_offset(cpu) = delta + pcpu_unit_offsets[cpu]; in setup_per_cpu_areas()