base-modem: explicitly say if NET or TTY data ports are supported

A modem that creates exclusively bearer objects that work with NET
ports (e.g. all QMI or MBIM modems) must not add any TTY port in the
list of data ports.

A modem that creates exclusively bearer objects that work with TTY
ports (e.g. the generic modem) must not add any NET port in the
list of data ports.

A modem that may use both TTY and NET ports should add all in the list
of data ports.

Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/324
Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/329
This commit is contained in:
Aleksander Morgado
2021-03-04 18:03:28 +01:00
parent b509229d57
commit 5d176a1e61
43 changed files with 196 additions and 18 deletions
@@ -55,6 +55,9 @@ mm_broadband_modem_qmi_simtech_new (const gchar *device,
MM_BASE_MODEM_PLUGIN, plugin,
MM_BASE_MODEM_VENDOR_ID, vendor_id,
MM_BASE_MODEM_PRODUCT_ID, product_id,
/* QMI modem supports NET only */
MM_BASE_MODEM_DATA_NET_SUPPORTED, TRUE,
MM_BASE_MODEM_DATA_TTY_SUPPORTED, FALSE,
MM_BROADBAND_MODEM_INDICATORS_DISABLED, TRUE,
NULL);
}
@@ -1215,6 +1215,9 @@ mm_broadband_modem_simtech_new (const gchar *device,
MM_BASE_MODEM_PLUGIN, plugin,
MM_BASE_MODEM_VENDOR_ID, vendor_id,
MM_BASE_MODEM_PRODUCT_ID, product_id,
/* Generic bearer supports TTY only */
MM_BASE_MODEM_DATA_NET_SUPPORTED, FALSE,
MM_BASE_MODEM_DATA_TTY_SUPPORTED, TRUE,
MM_BROADBAND_MODEM_INDICATORS_DISABLED, TRUE,
NULL);
}