base-modem: clarify port cleanup/close behavior for serial ports

Signed-off-by: Dan Williams <dan@ioncontrol.co>
This commit is contained in:
Dan Williams
2025-05-08 15:44:36 -05:00
parent e12b3adb35
commit 5e29ece5ec
+5
View File
@@ -2274,6 +2274,11 @@ cleanup_modem_port (MMBaseModem *self,
if (ctx)
teardown_context_ref (ctx);
/* No need to close serial ports here as they do not require a specific
* shutdown procedure with message exchanges and callbacks. They will be
* closed when the modem is invalidated or disposed.
*/
#if defined WITH_MBIM
/* We need to close the MBIM port cleanly when disposing the modem object */
if (MM_IS_PORT_MBIM (port)) {