summaryrefslogtreecommitdiff
path: root/drivers/tty/n_gsm.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2023-07-31 09:36:55 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2023-07-31 09:36:55 +0200
commit98a9e32bdf2525073fdfbdcc520d5c798a7375e5 (patch)
treeef6cac470ffe574fce5e2d62cee7edcd86696131 /drivers/tty/n_gsm.c
parent1eca51f58a10259f63fbc1ca77e0582581e9bd48 (diff)
parent5d0c230f1de8c7515b6567d9afba1f196fb4e2f4 (diff)
Merge 6.5-rc4 into usb-next
We need the USB fixes in here for testing and for other patches to be applied on top of. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/n_gsm.c')
-rw-r--r--drivers/tty/n_gsm.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/tty/n_gsm.c b/drivers/tty/n_gsm.c
index b411a26cc092..1cdefac4dd1b 100644
--- a/drivers/tty/n_gsm.c
+++ b/drivers/tty/n_gsm.c
@@ -3070,8 +3070,10 @@ static void gsm_cleanup_mux(struct gsm_mux *gsm, bool disc)
gsm->has_devices = false;
}
for (i = NUM_DLCI - 1; i >= 0; i--)
- if (gsm->dlci[i])
+ if (gsm->dlci[i]) {
gsm_dlci_release(gsm->dlci[i]);
+ gsm->dlci[i] = NULL;
+ }
mutex_unlock(&gsm->mutex);
/* Now wipe the queues */
tty_ldisc_flush(gsm->tty);