Skip to content

Commit 79e6c84

Browse files
Bjarki Arge Andreasenfabiobaltieri
authored andcommitted
modem: modem_cmux: Reset CMUX events on release
This commit resets the CMUX events to match the initial value of disconnected. Signed-off-by: Bjarki Arge Andreasen <[email protected]>
1 parent 7fe491c commit 79e6c84

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

subsys/modem/modem_cmux.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1023,4 +1023,8 @@ void modem_cmux_release(struct modem_cmux *cmux)
10231023

10241024
/* Unreference pipe */
10251025
cmux->pipe = NULL;
1026+
1027+
/* Reset events */
1028+
k_event_clear(&cmux->event, MODEM_CMUX_EVENT_CONNECTED_BIT);
1029+
k_event_post(&cmux->event, MODEM_CMUX_EVENT_DISCONNECTED_BIT);
10261030
}

0 commit comments

Comments
 (0)