• Home
  • Raw
  • Download

Lines Matching refs:cpu

89 static void ipi_setup(int cpu);
92 static void ipi_teardown(int cpu);
93 static int op_cpu_kill(unsigned int cpu);
95 static inline int op_cpu_kill(unsigned int cpu) in op_cpu_kill() argument
106 static int boot_secondary(unsigned int cpu, struct task_struct *idle) in boot_secondary() argument
108 const struct cpu_operations *ops = get_cpu_ops(cpu); in boot_secondary()
111 return ops->cpu_boot(cpu); in boot_secondary()
118 int __cpu_up(unsigned int cpu, struct task_struct *idle) in __cpu_up() argument
131 ret = boot_secondary(cpu, idle); in __cpu_up()
133 pr_err("CPU%u: failed to boot: %d\n", cpu, ret); in __cpu_up()
143 if (cpu_online(cpu)) in __cpu_up()
146 pr_crit("CPU%u: failed to come online\n", cpu); in __cpu_up()
155 cpu, status); in __cpu_up()
159 if (!op_cpu_kill(cpu)) { in __cpu_up()
160 pr_crit("CPU%u: died during early boot\n", cpu); in __cpu_up()
163 pr_crit("CPU%u: may not have shut down cleanly\n", cpu); in __cpu_up()
166 pr_crit("CPU%u: is stuck in kernel\n", cpu); in __cpu_up()
168 pr_crit("CPU%u: does not support 52-bit VAs\n", cpu); in __cpu_up()
171 cpu, PAGE_SIZE / SZ_1K); in __cpu_up()
176 panic("CPU%u detected unsupported configuration\n", cpu); in __cpu_up()
206 unsigned int cpu = smp_processor_id(); in secondary_start_kernel() local
224 rcu_cpu_starting(cpu); in secondary_start_kernel()
234 ops = get_cpu_ops(cpu); in secondary_start_kernel()
242 store_cpu_topology(cpu); in secondary_start_kernel()
247 notify_cpu_starting(cpu); in secondary_start_kernel()
249 ipi_setup(cpu); in secondary_start_kernel()
251 numa_add_cpu(cpu); in secondary_start_kernel()
259 cpu, (unsigned long)mpidr, in secondary_start_kernel()
262 set_cpu_online(cpu, true); in secondary_start_kernel()
274 static int op_cpu_disable(unsigned int cpu) in op_cpu_disable() argument
276 const struct cpu_operations *ops = get_cpu_ops(cpu); in op_cpu_disable()
290 return ops->cpu_disable(cpu); in op_cpu_disable()
300 unsigned int cpu = smp_processor_id(); in __cpu_disable() local
303 ret = op_cpu_disable(cpu); in __cpu_disable()
307 remove_cpu_topology(cpu); in __cpu_disable()
308 numa_remove_cpu(cpu); in __cpu_disable()
314 set_cpu_online(cpu, false); in __cpu_disable()
315 ipi_teardown(cpu); in __cpu_disable()
325 static int op_cpu_kill(unsigned int cpu) in op_cpu_kill() argument
327 const struct cpu_operations *ops = get_cpu_ops(cpu); in op_cpu_kill()
337 return ops->cpu_kill(cpu); in op_cpu_kill()
344 void __cpu_die(unsigned int cpu) in __cpu_die() argument
348 if (!cpu_wait_death(cpu, 5)) { in __cpu_die()
349 pr_crit("CPU%u: cpu didn't die\n", cpu); in __cpu_die()
352 pr_debug("CPU%u: shutdown\n", cpu); in __cpu_die()
360 err = op_cpu_kill(cpu); in __cpu_die()
362 pr_warn("CPU%d may not have shut down cleanly: %d\n", cpu, err); in __cpu_die()
371 unsigned int cpu = smp_processor_id(); in cpu_die() local
372 const struct cpu_operations *ops = get_cpu_ops(cpu); in cpu_die()
386 ops->cpu_die(cpu); in cpu_die()
392 static void __cpu_try_die(int cpu) in __cpu_try_die() argument
395 const struct cpu_operations *ops = get_cpu_ops(cpu); in __cpu_try_die()
398 ops->cpu_die(cpu); in __cpu_try_die()
408 int cpu = smp_processor_id(); in cpu_die_early() local
410 pr_crit("CPU%d: will not boot\n", cpu); in cpu_die_early()
413 set_cpu_present(cpu, 0); in cpu_die_early()
414 rcu_report_dead(cpu); in cpu_die_early()
418 __cpu_try_die(cpu); in cpu_die_early()
507 static bool __init is_mpidr_duplicate(unsigned int cpu, u64 hwid) in is_mpidr_duplicate() argument
511 for (i = 1; (i < cpu) && (i < NR_CPUS); i++) in is_mpidr_duplicate()
521 static int __init smp_cpu_setup(int cpu) in smp_cpu_setup() argument
525 if (init_cpu_ops(cpu)) in smp_cpu_setup()
528 ops = get_cpu_ops(cpu); in smp_cpu_setup()
529 if (ops->cpu_init(cpu)) in smp_cpu_setup()
532 set_cpu_possible(cpu, true); in smp_cpu_setup()
543 struct acpi_madt_generic_interrupt *acpi_cpu_get_madt_gicc(int cpu) in acpi_cpu_get_madt_gicc() argument
545 return &cpu_madt_gicc[cpu]; in acpi_cpu_get_madt_gicc()
754 unsigned int cpu; in smp_prepare_cpus() local
776 for_each_possible_cpu(cpu) { in smp_prepare_cpus()
778 per_cpu(cpu_number, cpu) = cpu; in smp_prepare_cpus()
780 if (cpu == smp_processor_id()) in smp_prepare_cpus()
783 ops = get_cpu_ops(cpu); in smp_prepare_cpus()
787 err = ops->cpu_prepare(cpu); in smp_prepare_cpus()
791 set_cpu_present(cpu, true); in smp_prepare_cpus()
792 numa_store_cpu_info(cpu); in smp_prepare_cpus()
812 unsigned int cpu, i; in arch_show_interrupts() local
817 for_each_online_cpu(cpu) in arch_show_interrupts()
818 seq_printf(p, "%10u ", irq_desc_kstat_cpu(ipi_desc[i], cpu)); in arch_show_interrupts()
831 void arch_send_call_function_single_ipi(int cpu) in arch_send_call_function_single_ipi() argument
833 smp_cross_call(cpumask_of(cpu), IPI_CALL_FUNC); in arch_send_call_function_single_ipi()
873 static void ipi_cpu_crash_stop(unsigned int cpu, struct pt_regs *regs) in ipi_cpu_crash_stop() argument
876 crash_save_cpu(regs, cpu); in ipi_cpu_crash_stop()
884 __cpu_try_die(cpu); in ipi_cpu_crash_stop()
896 unsigned int cpu = smp_processor_id(); in do_handle_IPI() local
917 ipi_cpu_crash_stop(cpu, get_irq_regs()); in do_handle_IPI()
937 WARN_ONCE(!acpi_parking_protocol_valid(cpu), in do_handle_IPI()
939 cpu); in do_handle_IPI()
944 pr_crit("CPU%u: Unknown IPI message 0x%x\n", cpu, ipinr); in do_handle_IPI()
964 static void ipi_setup(int cpu) in ipi_setup() argument
976 static void ipi_teardown(int cpu) in ipi_teardown() argument
1017 void smp_send_reschedule(int cpu) in smp_send_reschedule() argument
1019 smp_cross_call(cpumask_of(cpu), IPI_RESCHEDULE); in smp_send_reschedule()