Skip to content

Commit

Permalink
kernel/reboot: Add stub for pm_power_off
Browse files Browse the repository at this point in the history
Add weak stub for the global pm_power_off callback variable. This will
allow us to remove pm_power_off definitions from arch/ code and transition
to the new sys-off based API that will replace the global variable.

Signed-off-by: Dmitry Osipenko <dmitry.osipenko@collabora.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Dmitry Osipenko authored and Rafael J. Wysocki committed May 19, 2022
1 parent 2b6aa73 commit 5d34b41
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions kernel/reboot.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,12 @@ struct sys_off_handler {
void *list;
};

/*
* Temporary stub that prevents linkage failure while we're in process
* of removing all uses of legacy pm_power_off() around the kernel.
*/
void __weak (*pm_power_off)(void);

/*
* If set, this is used for preparing the system to power off.
*/
Expand Down

0 comments on commit 5d34b41

Please sign in to comment.