usb: dwc3: of-simple: fix use-after-free on remove
commit896e518883f18e601335908192e33426c1f599a4
authorJohan Hovold <johan@kernel.org>
Thu, 31 May 2018 14:45:52 +0000 (31 16:45 +0200)
committerFelipe Balbi <felipe.balbi@linux.intel.com>
Mon, 18 Jun 2018 09:41:00 +0000 (18 12:41 +0300)
tree0952cd38a8133342455738b47363273af1f20fda
parent1ffba9058737af2ddeebc813faa8ea9b16bc892a
usb: dwc3: of-simple: fix use-after-free on remove

The clocks have already been explicitly disabled and put as part of
remove() so the runtime suspend callback must not be run when balancing
the runtime PM usage count before returning.

Fixes: 16adc674d0d6 ("usb: dwc3: add generic OF glue layer")
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
drivers/usb/dwc3/dwc3-of-simple.c