Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f34d9bd5 authored by Pavankumar Kondeti's avatar Pavankumar Kondeti
Browse files

USB: gadget: u_ctrl_hsic: fix a bug in control bits propagation



A work is scheduled to open the hsic transport channel upon
USB cable connect.  If the host sends SET_CONTROL_LINE_STATE
control transfer before the port is opened, the control bits
are not propagated to the mdm.

CRs-Fixed: 556039
Change-Id: Ic60830d2b04327c9ea9ded84e66b8eb7b92aee82
Signed-off-by: default avatarPavankumar Kondeti <pkondeti@codeaurora.org>
parent e3c81f14
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
/* Copyright (c) 2011, The Linux Foundation. All rights reserved.
/* Copyright (c) 2011, 2013 The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -193,6 +193,10 @@ static void ghsic_ctrl_connect_w(struct work_struct *w)
		return;
	}
	set_bit(CH_OPENED, &port->bridge_sts);

	if (port->cbits_tomodem)
		ctrl_bridge_set_cbits(port->brdg.ch_id, port->cbits_tomodem);

	spin_unlock_irqrestore(&port->port_lock, flags);

	cbits = ctrl_bridge_get_cbits_tohost(port->brdg.ch_id);