1. 21 5月, 2012 25 次提交
  2. 28 4月, 2012 14 次提交
  3. 27 4月, 2012 1 次提交
    • A
      usb: gadget: udc-core: fix incompatibility with dummy-hcd · 320cd1e7
      Alan Stern 提交于
      This patch (as1548) fixes a recently-introduced incompatibility
      between the UDC core and the dummy-hcd driver.  Commit
      8ae8090c (usb: gadget: udc-core: fix
      asymmetric calls in remove_driver) moved the usb_gadget_udc_stop()
      call in usb_gadget_remove_driver() below the usb_gadget_disconnect()
      call.
      
      As a result, usb_gadget_disconnect() gets called at a time when the
      gadget driver believes it has been unbound but dummy-hcd believes
      it has not.  A nasty error ensues when dummy-hcd calls the gadget
      driver's disconnect method a second time.
      
      To fix the problem, this patch moves the gadget driver's unbind
      notification after the usb_gadget_disconnect() call.  Now nothing
      happens between the two unbind notifications, so nothing goes wrong.
      Signed-off-by: NAlan Stern <stern@rowland.harvard.edu>
      Tested-by: NAlexander Shishkin <alexander.shishkin@linux.intel.com>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      320cd1e7