Linux Audio

Check our new training course

Loading...
Note: File does not exist in v3.5.6.
 1// SPDX-License-Identifier: GPL-2.0
 2// Copyright (C) 2018 Hangzhou C-SKY Microsystems co.,ltd.
 3
 4#include <linux/reboot.h>
 5
 6void (*pm_power_off)(void);
 7EXPORT_SYMBOL(pm_power_off);
 8
 9void machine_power_off(void)
10{
11	local_irq_disable();
12	if (pm_power_off)
13		pm_power_off();
14	asm volatile ("bkpt");
15}
16
17void machine_halt(void)
18{
19	local_irq_disable();
20	if (pm_power_off)
21		pm_power_off();
22	asm volatile ("bkpt");
23}
24
25void machine_restart(char *cmd)
26{
27	local_irq_disable();
28	do_kernel_restart(cmd);
29	asm volatile ("bkpt");
30}