Skip to contentSkip to conversation

ab8500-charger: we print an unintended error message

PATCH Applied Dan Carpenter 2 participants 2 messages Aug 27, 2013 – Aug 28, 2013 Kernel janitors

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ab8500-charger: we print an unintended error message

There is a missing break statement here, so we print an error message that the USB type is invalid. The original code still works fine though except for the error message.

drivers/power/ab8500_charger.c +1 -0
index f098fda..a4c4a10 100644
@@ -774,6 +774,7 @@ static int ab8500_charger_max_usb_curr(struct ab8500_charger *di,
 		di->max_usb_in_curr.usb_type_max = USB_CH_IP_CUR_LVL_0P5;
 		dev_dbg(di->dev, "USB Type - 0x%02x MaxCurr: %d", link_status,
 				di->max_usb_in_curr.usb_type_max);
+		break;
 	case USB_STAT_NOT_VALID_LINK:
 		dev_err(di->dev, "USB Type invalid - try charging anyway\n");
 		di->max_usb_in_curr.usb_type_max = USB_CH_IP_CUR_LVL_0P5;
#1 lore raw
Quoted 5 lines · Dan Carpenter

There is a missing break statement here, so we print an error message that the USB type is invalid. The original code still works fine though except for the error message.

Applied, thanks a lot!

Anton