Upon driver unbind usb_free_all_descriptors() function frees all speed descriptor pointers without setting them to NULL. In case gadget speed changes (i.e from super speed plus to super speed) after driver unbind only upto super speed descriptor pointers get populated. Super speed plus desc still holds the stale (already freed) pointer. As a result next composition switch results into double free of super speed plus descriptor. Fix this issue by setting all descriptor pointers to NULL after freeing them in usb_free_all_descriptors(). Also clean up gsi_unbind() which is setting up descriptor pointers to NULL already. Change-Id: I4f28294c165bb3b5dc9feb4f22d819f527ad4d50 Signed-off-by: Hemant Kumar <hemantk@codeaurora.org> Signed-off-by: Sriharsha Allenki <sallenki@codeaurora.org> |
||
---|---|---|
.. | ||
association.h | ||
atmel_usba_udc.h | ||
audio-v2.h | ||
audio-v3.h | ||
audio.h | ||
c67x00.h | ||
ccid_desc.h | ||
cdc-wdm.h | ||
cdc.h | ||
cdc_ncm.h | ||
ch9.h | ||
chipidea.h | ||
class-dual-role.h | ||
composite.h | ||
diag_bridge.h | ||
ehci-dbgp.h | ||
ehci_def.h | ||
ehci_pdriver.h | ||
ezusb.h | ||
f_accessory.h | ||
f_mtp.h | ||
functionfs.h | ||
g_hid.h | ||
gadget.h | ||
gadget_configfs.h | ||
gpio_vbus.h | ||
hcd.h | ||
input.h | ||
iowarrior.h | ||
ipc_bridge.h | ||
irda.h | ||
isp116x.h | ||
isp1301.h | ||
isp1362.h | ||
isp1760.h | ||
m66592.h | ||
msm_hsusb.h | ||
msm_hsusb_hw.h | ||
musb-omap.h | ||
musb-ux500.h | ||
musb.h | ||
net2280.h | ||
of.h | ||
ohci_pdriver.h | ||
otg-fsm.h | ||
otg.h | ||
phy.h | ||
phy_companion.h | ||
quirks.h | ||
r8a66597.h | ||
renesas_usbhs.h | ||
rndis_host.h | ||
samsung_usb_phy.h | ||
serial.h | ||
sl811.h | ||
storage.h | ||
tegra_usb_phy.h | ||
tilegx.h | ||
uas.h | ||
ulpi.h | ||
usb338x.h | ||
usb_phy_generic.h | ||
usb_qdss.h | ||
usbdiag.h | ||
usbnet.h | ||
usbpd.h | ||
wusb-wa.h | ||
wusb.h | ||
xhci_pdriver.h |