mirror of
https://github.com/hardkernel/linux.git
synced 2026-04-19 12:00:46 +09:00
reboot system if power off with dc charger pluged in
This commit is contained in:
@@ -1638,6 +1638,17 @@ static void rk30_pm_power_off(void)
|
||||
#if defined(CONFIG_MFD_WM831X)
|
||||
wm831x_set_bits(Wm831x,WM831X_GPIO_LEVEL,0x0001,0x0000); //set sys_pwr 0
|
||||
wm831x_device_shutdown(Wm831x);//wm8326 shutdown
|
||||
#endif
|
||||
#if defined(CONFIG_REGULATOR_ACT8846)
|
||||
if (pmic_is_act8846()) {
|
||||
printk("enter dcdet===========\n");
|
||||
if(gpio_get_value (RK30_PIN0_PB2) == GPIO_LOW)
|
||||
{
|
||||
printk("enter restart===========\n");
|
||||
arm_pm_restart(0, NULL);
|
||||
}
|
||||
//act8931_device_shutdown();
|
||||
}
|
||||
#endif
|
||||
while (1);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user