[ofono-binder] Made LTE network mode configurable

This commit is contained in:
Slava Monich
2022-11-29 18:03:56 +02:00
parent 29234d826d
commit bf16469738
2 changed files with 14 additions and 0 deletions

View File

@@ -195,3 +195,9 @@
# Default none (all supported features are enabled)
#
#disableFeatures=
# LTE network mode.
#
# Default 9 (LTE_GSM_WCDMA)
#
#lteNetworkMode=9

View File

@@ -134,6 +134,7 @@ static const char* const binder_radio_ifaces[] = {
#define BINDER_CONF_SLOT_USE_NETWORK_SCAN "useNetworkScan"
#define BINDER_CONF_SLOT_REPLACE_STRANGE_OPER "replaceStrangeOperatorNames"
#define BINDER_CONF_SLOT_SIGNAL_STRENGTH_RANGE "signalStrengthRange"
#define BINDER_CONF_SLOT_LTE_MODE "lteNetworkMode"
/* Defaults */
#define BINDER_DEFAULT_RADIO_INTERFACE RADIO_INTERFACE_1_2
@@ -1609,6 +1610,13 @@ binder_plugin_create_slot(
slot->data_opt.allow_data = ival;
}
/* lteNetworkMode */
if (ofono_conf_get_integer(file, group,
BINDER_CONF_SLOT_LTE_MODE, &ival)) {
DBG("%s: " BINDER_CONF_SLOT_LTE_MODE " %d", group, ival);
config->lte_network_mode = ival;
}
/* useNetworkScan */
if (ofono_conf_get_boolean(file, group,
BINDER_CONF_SLOT_USE_NETWORK_SCAN,