Lines Matching refs:cpuhp_state

67 	enum cpuhp_state	state;
68 enum cpuhp_state target;
69 enum cpuhp_state fail;
78 enum cpuhp_state cb_state;
86 static DEFINE_PER_CPU(struct cpuhp_cpu_state, cpuhp_state) = {
147 static struct cpuhp_step *cpuhp_get_step(enum cpuhp_state state) in cpuhp_get_step()
169 static int cpuhp_invoke_callback(unsigned int cpu, enum cpuhp_state state, in cpuhp_invoke_callback()
173 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in cpuhp_invoke_callback()
252 static bool cpuhp_is_ap_state(enum cpuhp_state state) in cpuhp_is_ap_state()
276 static bool cpuhp_is_atomic_state(enum cpuhp_state state) in cpuhp_is_atomic_state()
301 atomic_t *st = this_cpu_ptr(&cpuhp_state.ap_sync_state); in cpuhp_ap_update_sync_state()
311 atomic_t *st = per_cpu_ptr(&cpuhp_state.ap_sync_state, cpu); in cpuhp_wait_for_sync_state()
362 atomic_t *st = per_cpu_ptr(&cpuhp_state.ap_sync_state, cpu); in cpuhp_bp_sync_dead()
393 atomic_t *st = this_cpu_ptr(&cpuhp_state.ap_sync_state); in cpuhp_ap_sync_alive()
404 atomic_t *st = per_cpu_ptr(&cpuhp_state.ap_sync_state, cpu); in cpuhp_can_boot_ap()
708 static inline enum cpuhp_state
709 cpuhp_set_state(int cpu, struct cpuhp_cpu_state *st, enum cpuhp_state target) in cpuhp_set_state()
711 enum cpuhp_state prev_state = st->state; in cpuhp_set_state()
728 enum cpuhp_state prev_state) in cpuhp_reset_state()
777 enum cpuhp_state target) in cpuhp_kick_ap()
779 enum cpuhp_state prev_state; in cpuhp_kick_ap()
794 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in bringup_wait_for_ap_online()
827 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in cpuhp_bringup_ap()
859 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in bringup_cpu()
929 enum cpuhp_state *state_to_run, in cpuhp_next_state()
931 enum cpuhp_state target) in cpuhp_next_state()
956 enum cpuhp_state target, in __cpuhp_invoke_callback_range()
959 enum cpuhp_state state; in __cpuhp_invoke_callback_range()
987 enum cpuhp_state target) in cpuhp_invoke_callback_range()
995 enum cpuhp_state target) in cpuhp_invoke_callback_range_nofail()
1015 enum cpuhp_state target) in cpuhp_up_callbacks()
1017 enum cpuhp_state prev_state = st->state; in cpuhp_up_callbacks()
1039 struct cpuhp_cpu_state *st = this_cpu_ptr(&cpuhp_state); in cpuhp_should_run()
1060 struct cpuhp_cpu_state *st = this_cpu_ptr(&cpuhp_state); in cpuhp_thread_fun()
1062 enum cpuhp_state state; in cpuhp_thread_fun()
1125 cpuhp_invoke_ap_callback(int cpu, enum cpuhp_state state, bool bringup, in cpuhp_invoke_ap_callback()
1128 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in cpuhp_invoke_ap_callback()
1177 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in cpuhp_kick_ap_work()
1178 enum cpuhp_state prev_state = st->state; in cpuhp_kick_ap_work()
1195 .store = &cpuhp_state.thread,
1208 st = per_cpu_ptr(&cpuhp_state, cpu); in cpuhp_init_state()
1218 kthread_unpark(this_cpu_read(cpuhp_state.thread)); in cpuhp_threads_init()
1270 struct cpuhp_cpu_state *st = this_cpu_ptr(&cpuhp_state); in take_cpu_down()
1271 enum cpuhp_state target = max((int)st->target, CPUHP_AP_OFFLINE); in take_cpu_down()
1297 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in takedown_cpu()
1362 struct cpuhp_cpu_state *st = this_cpu_ptr(&cpuhp_state); in cpuhp_report_idle_dead()
1377 enum cpuhp_state target) in cpuhp_down_callbacks()
1379 enum cpuhp_state prev_state = st->state; in cpuhp_down_callbacks()
1400 enum cpuhp_state target) in _cpu_down()
1402 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in _cpu_down()
1466 enum cpuhp_state target;
1476 static int cpu_down_maps_locked(unsigned int cpu, enum cpuhp_state target) in cpu_down_maps_locked()
1502 static int cpu_down(unsigned int cpu, enum cpuhp_state target) in cpu_down()
1594 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in notify_cpu_starting()
1595 enum cpuhp_state target = min((int)st->target, CPUHP_AP_ONLINE); in notify_cpu_starting()
1611 void cpuhp_online_idle(enum cpuhp_state state) in cpuhp_online_idle()
1613 struct cpuhp_cpu_state *st = this_cpu_ptr(&cpuhp_state); in cpuhp_online_idle()
1632 static int _cpu_up(unsigned int cpu, int tasks_frozen, enum cpuhp_state target) in _cpu_up()
1634 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in _cpu_up()
1697 static int cpu_up(unsigned int cpu, enum cpuhp_state target) in cpu_up()
1781 enum cpuhp_state target) in cpuhp_bringup_mask()
1786 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in cpuhp_bringup_mask()
2271 static int cpuhp_cb_check(enum cpuhp_state state) in cpuhp_cb_check()
2283 static int cpuhp_reserve_state(enum cpuhp_state state) in cpuhp_reserve_state()
2285 enum cpuhp_state i, end; in cpuhp_reserve_state()
2309 static int cpuhp_store_callbacks(enum cpuhp_state state, const char *name, in cpuhp_store_callbacks()
2346 static void *cpuhp_get_teardown_cb(enum cpuhp_state state) in cpuhp_get_teardown_cb()
2355 static int cpuhp_issue_call(int cpu, enum cpuhp_state state, bool bringup, in cpuhp_issue_call()
2388 static void cpuhp_rollback_install(int failedcpu, enum cpuhp_state state, in cpuhp_rollback_install()
2395 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in cpuhp_rollback_install()
2407 int __cpuhp_state_add_instance_cpuslocked(enum cpuhp_state state, in __cpuhp_state_add_instance_cpuslocked()
2431 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in __cpuhp_state_add_instance_cpuslocked()
2452 int __cpuhp_state_add_instance(enum cpuhp_state state, struct hlist_node *node, in __cpuhp_state_add_instance()
2482 int __cpuhp_setup_state_cpuslocked(enum cpuhp_state state, in __cpuhp_setup_state_cpuslocked()
2515 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in __cpuhp_setup_state_cpuslocked()
2541 int __cpuhp_setup_state(enum cpuhp_state state, in __cpuhp_setup_state()
2557 int __cpuhp_state_remove_instance(enum cpuhp_state state, in __cpuhp_state_remove_instance()
2579 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in __cpuhp_state_remove_instance()
2605 void __cpuhp_remove_state_cpuslocked(enum cpuhp_state state, bool invoke) in __cpuhp_remove_state_cpuslocked()
2631 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); in __cpuhp_remove_state_cpuslocked()
2643 void __cpuhp_remove_state(enum cpuhp_state state, bool invoke) in __cpuhp_remove_state()
2743 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, dev->id); in state_show()
2752 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, dev->id); in target_store()
2793 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, dev->id); in target_show()
2802 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, dev->id); in fail_store()
2852 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, dev->id); in fail_show()
3185 atomic_set(this_cpu_ptr(&cpuhp_state.ap_sync_state), SYNC_STATE_ONLINE); in boot_cpu_hotplug_init()
3187 this_cpu_write(cpuhp_state.state, CPUHP_ONLINE); in boot_cpu_hotplug_init()
3188 this_cpu_write(cpuhp_state.target, CPUHP_ONLINE); in boot_cpu_hotplug_init()