usb: gadget: Mark notify_modem as NULL on gbridge_disconnect
On some targets, f_serial switches transport path from
char_bridge to TTY in DUN+SoftAP scenario. As a part of that,
we call gbridge_disconnect but notify_modem callback is still
marked as gbridge_notify_modem. Then on getting a SETUP req
from host PC, gbridge_notify_modem is called which can lead
to NULL pointer dereference because port_usb is NULL.
Fix this by marking notify_modem callback as NULL on
gbridge_disconnect.
Change-Id: I4470030cde6f38b905f7a88e16ed9f261a8954d6
Signed-off-by:
Ajay Agarwal <ajaya@codeaurora.org>
Loading
Please register or sign in to comment