diff options
author | Prakash Pabba <quic_ppabba@quicinc.com> | 2021-12-09 16:54:54 +0530 |
---|---|---|
committer | Aleksander Morgado <aleksander@aleksander.es> | 2022-01-30 15:37:05 +0000 |
commit | f05258e757558b93559b4d36087e89ec926c5423 (patch) | |
tree | 61d47849fd27cae8369e50db94fbae6d505e367d | |
parent | 9843546a490c34bf0f8adb1bcce9503eccbb3115 (diff) |
mm-modem-helpers-qmi: Fix current capabilities for multimode device
Keep LTE or 5GNR always in current capabilities if supported by device.
Since capability switching logic is exclusively used for configuring
GSM/UMTS+CDMA/EVDO devices, decide if to have GSM/UMTS or CDMA/EVDO or both
or none when loading current capabilities.
-rw-r--r-- | src/mm-modem-helpers-qmi.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mm-modem-helpers-qmi.c b/src/mm-modem-helpers-qmi.c index d5316363..4d8aec5e 100644 --- a/src/mm-modem-helpers-qmi.c +++ b/src/mm-modem-helpers-qmi.c @@ -1856,15 +1856,15 @@ mm_modem_capability_from_qmi_capabilities_context (MMQmiCapabilitiesContext *ctx else if (ctx->nas_tp_mask != QMI_NAS_RADIO_TECHNOLOGY_PREFERENCE_AUTO) tmp = mm_modem_capability_from_qmi_radio_technology_preference (ctx->nas_tp_mask); - /* Final capabilities are the intersection between the Technology - * Preference or SSP and the device's capabilities. + /* Final capabilities are the union of the active multimode capability + * (GSM/UMTS or CDMA/EVDO or both or none) in TP or SSP and other supported device's capabilities. * If the Technology Preference was "auto" or unknown we just fall back * to the Get Capabilities response. */ if (tmp == MM_MODEM_CAPABILITY_NONE) tmp = ctx->dms_capabilities; else - tmp &= ctx->dms_capabilities; + tmp = (tmp & MULTIMODE) | (MULTIMODE ^ ctx->dms_capabilities); } /* Log about the logic applied */ |