diff options
author | Albert Wang <albertccwang@google.com> | 2021-11-09 17:26:42 +0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-11-17 15:02:52 +0100 |
commit | 26288448120b28af1dfd85a6fa6b6d55a16c7f2f (patch) | |
tree | 00e7f6ffda29077082a134f781ed050b8783d2aa /drivers/regulator/mpq7920.h | |
parent | 3b8599a6f4817bdd7c5e7145f2972b7f22f00a9d (diff) |
usb: dwc3: gadget: Fix null pointer exception
In the endpoint interrupt functions
dwc3_gadget_endpoint_transfer_in_progress() and
dwc3_gadget_endpoint_trbs_complete() will dereference the endpoint
descriptor. But it could be cleared in __dwc3_gadget_ep_disable()
when accessory disconnected. So we need to check whether it is null
or not before dereferencing it.
Fixes: f09ddcfcb8c5 ("usb: dwc3: gadget: Prevent EP queuing while stopping transfers")
Cc: stable <stable@vger.kernel.org>
Reviewed-by: Jack Pham <quic_jackp@quicinc.com>
Signed-off-by: Albert Wang <albertccwang@google.com>
Link: https://lore.kernel.org/r/20211109092642.3507692-1-albertccwang@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/regulator/mpq7920.h')
0 files changed, 0 insertions, 0 deletions