Merge "USB: dwc3-msm: Set speed as high speed if no speed information"

This commit is contained in:
Linux Build Service Account 2017-01-16 13:29:52 -08:00 committed by Gerrit - the friendly Code Review server
commit ed2eb1070d

View file

@ -2574,7 +2574,7 @@ static int dwc3_msm_id_notifier(struct notifier_block *nb,
dbg_event(0xFF, "cc_state", mdwc->typec_orientation);
speed = extcon_get_cable_state_(edev, EXTCON_USB_SPEED);
dwc->maximum_speed = (speed == 0) ? USB_SPEED_HIGH : USB_SPEED_SUPER;
dwc->maximum_speed = (speed <= 0) ? USB_SPEED_HIGH : USB_SPEED_SUPER;
if (mdwc->id_state != id) {
mdwc->id_state = id;
@ -2615,7 +2615,7 @@ static int dwc3_msm_vbus_notifier(struct notifier_block *nb,
dbg_event(0xFF, "cc_state", mdwc->typec_orientation);
speed = extcon_get_cable_state_(edev, EXTCON_USB_SPEED);
dwc->maximum_speed = (speed == 0) ? USB_SPEED_HIGH : USB_SPEED_SUPER;
dwc->maximum_speed = (speed <= 0) ? USB_SPEED_HIGH : USB_SPEED_SUPER;
mdwc->vbus_active = event;
if (dwc->is_drd && !mdwc->in_restart) {