summaryrefslogtreecommitdiff
path: root/board
diff options
context:
space:
mode:
Diffstat (limited to 'board')
-rw-r--r--board/spring/board.h4
-rw-r--r--board/spring/usb_charging.c5
2 files changed, 7 insertions, 2 deletions
diff --git a/board/spring/board.h b/board/spring/board.h
index 8c2a3932c4..d48cfee283 100644
--- a/board/spring/board.h
+++ b/board/spring/board.h
@@ -27,8 +27,8 @@
#undef CONFIG_TASK_PROFILING
#define CONFIG_WATCHDOG_HELP
-/* DE-ACTIVATED: use STOP mode when we have nothing to do */
-#undef CONFIG_LOW_POWER_IDLE
+/* use STOP mode when we have nothing to do */
+#define CONFIG_LOW_POWER_IDLE
/* Smart battery and TPSchrome are on a private I2C bus behind the EC */
#define CONFIG_I2C_PASSTHROUGH
diff --git a/board/spring/usb_charging.c b/board/spring/usb_charging.c
index a0bc3b1734..75b57826da 100644
--- a/board/spring/usb_charging.c
+++ b/board/spring/usb_charging.c
@@ -8,6 +8,7 @@
#include "adc.h"
#include "board.h"
#include "chipset.h"
+#include "clock.h"
#include "console.h"
#include "hooks.h"
#include "gpio.h"
@@ -495,6 +496,10 @@ static void usb_device_change(int dev_type)
keyboard_send_battery_key();
current_dev_type = dev_type;
+ if (dev_type)
+ disable_sleep(SLEEP_MASK_USB_PWR);
+ else
+ enable_sleep(SLEEP_MASK_USB_PWR);
}
/*