From: John Youn Date: Thu, 17 Dec 2015 19:18:41 +0000 (-0800) Subject: UPSTREAM: usb: dwc2: gadget: Remove call to dwc2_hsotg_init() X-Git-Tag: firefly_0821_release~895 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=04f8bb8950d16ea2c0395677d63f7b925125b485;p=firefly-linux-kernel-4.4.55.git UPSTREAM: usb: dwc2: gadget: Remove call to dwc2_hsotg_init() Remove call to dwc2_hsotg_init() from dwc2_gadget_init(). The gadget_init function should not access any device registers because the mode isn't guaranteed here. Also, this is already called elsewhere before anything starts on the gadget so it is not necessary here. Change-Id: I677a97b4175af223a6e07bdd5eadd6e0d9deb723 Signed-off-by: John Youn Signed-off-by: Felipe Balbi Signed-off-by: Huang, Tao (cherry picked from commit 60c0288c72c980fb37ed4e48f68c9743a53b662c) --- diff --git a/drivers/usb/dwc2/gadget.c b/drivers/usb/dwc2/gadget.c index 628ba74d8e50..8ab7a9e0e547 100644 --- a/drivers/usb/dwc2/gadget.c +++ b/drivers/usb/dwc2/gadget.c @@ -3545,8 +3545,6 @@ int dwc2_gadget_init(struct dwc2_hsotg *hsotg, int irq) return ret; } - dwc2_hsotg_init(hsotg); - hsotg->ctrl_buff = devm_kzalloc(hsotg->dev, DWC2_CTRL_BUFF_SIZE, GFP_KERNEL); if (!hsotg->ctrl_buff) {