diff options
Diffstat (limited to 'firmware')
-rw-r--r-- | firmware/export/powermgmt.h | 7 | ||||
-rw-r--r-- | firmware/powermgmt.c | 12 |
2 files changed, 0 insertions, 19 deletions
diff --git a/firmware/export/powermgmt.h b/firmware/export/powermgmt.h index 41594abe4d..a78386445e 100644 --- a/firmware/export/powermgmt.h +++ b/firmware/export/powermgmt.h | |||
@@ -84,13 +84,6 @@ enum shutdown_type | |||
84 | /* Start up power management thread */ | 84 | /* Start up power management thread */ |
85 | void powermgmt_init(void) INIT_ATTR; | 85 | void powermgmt_init(void) INIT_ATTR; |
86 | 86 | ||
87 | /* Generic current values that are intentionally meaningless - config header | ||
88 | * should define proper numbers.*/ | ||
89 | |||
90 | #ifndef CURRENT_USB | ||
91 | #define CURRENT_USB 2 /* usual current in mA in USB mode */ | ||
92 | #endif | ||
93 | |||
94 | #if CONFIG_CHARGING && !defined(CURRENT_MAX_CHG) | 87 | #if CONFIG_CHARGING && !defined(CURRENT_MAX_CHG) |
95 | #define CURRENT_MAX_CHG 350 /* maximum charging current */ | 88 | #define CURRENT_MAX_CHG 350 /* maximum charging current */ |
96 | #endif | 89 | #endif |
diff --git a/firmware/powermgmt.c b/firmware/powermgmt.c index abcd32f814..e455127496 100644 --- a/firmware/powermgmt.c +++ b/firmware/powermgmt.c | |||
@@ -190,18 +190,6 @@ int battery_current(void) | |||
190 | int current = CURRENT_NORMAL; | 190 | int current = CURRENT_NORMAL; |
191 | 191 | ||
192 | #ifndef BOOTLOADER | 192 | #ifndef BOOTLOADER |
193 | if (usb_inserted() | ||
194 | #ifdef HAVE_USB_POWER | ||
195 | #if (CURRENT_USB < CURRENT_NORMAL) | ||
196 | || usb_powered_only() | ||
197 | #else | ||
198 | && !usb_powered_only() | ||
199 | #endif | ||
200 | #endif | ||
201 | ) { | ||
202 | current = CURRENT_USB; | ||
203 | } | ||
204 | |||
205 | #if defined(HAVE_BACKLIGHT) && defined(CURRENT_BACKLIGHT) | 193 | #if defined(HAVE_BACKLIGHT) && defined(CURRENT_BACKLIGHT) |
206 | if (backlight_get_current_timeout() == 0) /* LED always on */ | 194 | if (backlight_get_current_timeout() == 0) /* LED always on */ |
207 | current += CURRENT_BACKLIGHT; | 195 | current += CURRENT_BACKLIGHT; |