diff options
Diffstat (limited to 'driver/bc12/mt6360.c')
-rw-r--r-- | driver/bc12/mt6360.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/driver/bc12/mt6360.c b/driver/bc12/mt6360.c index 41b5b0e244..50aa4d0e45 100644 --- a/driver/bc12/mt6360.c +++ b/driver/bc12/mt6360.c @@ -118,7 +118,9 @@ static void mt6360_update_charge_manager(int port, static enum charge_supplier current_bc12_type = CHARGE_SUPPLIER_NONE; if (new_bc12_type != current_bc12_type) { - charge_manager_update_charge(current_bc12_type, port, NULL); + if (current_bc12_type >= 0) + charge_manager_update_charge(current_bc12_type, port, + NULL); if (new_bc12_type != CHARGE_SUPPLIER_NONE) { struct charge_port_info chg = { |