arch: deprecate _current
`_current` is now functionally equals to `arch_curr_thread()`, remove its usage in-tree and deprecate it instead of removing it outright, as it has been with us since forever. Signed-off-by: Yong Cong Sin <ycsin@meta.com> Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
This commit is contained in:
parent
1a752e8a35
commit
b1def7145f
107 changed files with 490 additions and 479 deletions
|
@ -254,7 +254,7 @@ const struct pm_state_info *pm_policy_next_state(uint8_t cpu, int32_t ticks)
|
|||
"There is no power state defined");
|
||||
|
||||
/* make sure this is idle thread */
|
||||
zassert_true(z_is_idle_thread_object(_current));
|
||||
zassert_true(z_is_idle_thread_object(arch_current_thread()));
|
||||
zassert_true(ticks == _kernel.idle);
|
||||
zassert_false(k_can_yield());
|
||||
idle_entered = true;
|
||||
|
@ -276,7 +276,7 @@ static void notify_pm_state_entry(enum pm_state state)
|
|||
/* enter suspend */
|
||||
zassert_true(notify_app_entry == true,
|
||||
"Notification to enter suspend was not sent to the App");
|
||||
zassert_true(z_is_idle_thread_object(_current));
|
||||
zassert_true(z_is_idle_thread_object(arch_current_thread()));
|
||||
zassert_equal(state, PM_STATE_SUSPEND_TO_IDLE);
|
||||
|
||||
pm_device_state_get(device_dummy, &device_power_state);
|
||||
|
@ -301,7 +301,7 @@ static void notify_pm_state_exit(enum pm_state state)
|
|||
/* leave suspend */
|
||||
zassert_true(notify_app_exit == true,
|
||||
"Notification to leave suspend was not sent to the App");
|
||||
zassert_true(z_is_idle_thread_object(_current));
|
||||
zassert_true(z_is_idle_thread_object(arch_current_thread()));
|
||||
zassert_equal(state, PM_STATE_SUSPEND_TO_IDLE);
|
||||
|
||||
/* at this point, devices are active again*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue