rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 1 | /***************************************************************************** |
| 2 | * Copyright Statement: |
| 3 | * -------------------- |
| 4 | * This software is protected by Copyright and the information contained |
| 5 | * herein is confidential. The software may not be copied and the information |
| 6 | * contained herein may not be used or disclosed except with the written |
| 7 | * permission of MediaTek Inc. (C) 2005 |
| 8 | * |
| 9 | * BY OPENING THIS FILE, BUYER HEREBY UNEQUIVOCALLY ACKNOWLEDGES AND AGREES |
| 10 | * THAT THE SOFTWARE/FIRMWARE AND ITS DOCUMENTATIONS ("MEDIATEK SOFTWARE") |
| 11 | * RECEIVED FROM MEDIATEK AND/OR ITS REPRESENTATIVES ARE PROVIDED TO BUYER ON |
| 12 | * AN "AS-IS" BASIS ONLY. MEDIATEK EXPRESSLY DISCLAIMS ANY AND ALL WARRANTIES, |
| 13 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF |
| 14 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NONINFRINGEMENT. |
| 15 | * NEITHER DOES MEDIATEK PROVIDE ANY WARRANTY WHATSOEVER WITH RESPECT TO THE |
| 16 | * SOFTWARE OF ANY THIRD PARTY WHICH MAY BE USED BY, INCORPORATED IN, OR |
| 17 | * SUPPLIED WITH THE MEDIATEK SOFTWARE, AND BUYER AGREES TO LOOK ONLY TO SUCH |
| 18 | * THIRD PARTY FOR ANY WARRANTY CLAIM RELATING THERETO. MEDIATEK SHALL ALSO |
| 19 | * NOT BE RESPONSIBLE FOR ANY MEDIATEK SOFTWARE RELEASES MADE TO BUYER'S |
| 20 | * SPECIFICATION OR TO CONFORM TO A PARTICULAR STANDARD OR OPEN FORUM. |
| 21 | * |
| 22 | * BUYER'S SOLE AND EXCLUSIVE REMEDY AND MEDIATEK'S ENTIRE AND CUMULATIVE |
| 23 | * LIABILITY WITH RESPECT TO THE MEDIATEK SOFTWARE RELEASED HEREUNDER WILL BE, |
| 24 | * AT MEDIATEK'S OPTION, TO REVISE OR REPLACE THE MEDIATEK SOFTWARE AT ISSUE, |
| 25 | * OR REFUND ANY SOFTWARE LICENSE FEES OR SERVICE CHARGE PAID BY BUYER TO |
| 26 | * MEDIATEK FOR SUCH MEDIATEK SOFTWARE AT ISSUE. |
| 27 | * |
| 28 | * THE TRANSACTION CONTEMPLATED HEREUNDER SHALL BE CONSTRUED IN ACCORDANCE |
| 29 | * WITH THE LAWS OF THE STATE OF CALIFORNIA, USA, EXCLUDING ITS CONFLICT OF |
| 30 | * LAWS PRINCIPLES. ANY DISPUTES, CONTROVERSIES OR CLAIMS ARISING THEREOF AND |
| 31 | * RELATED THERETO SHALL BE SETTLED BY ARBITRATION IN SAN FRANCISCO, CA, UNDER |
| 32 | * THE RULES OF THE INTERNATIONAL CHAMBER OF COMMERCE (ICC). |
| 33 | * |
| 34 | *****************************************************************************/ |
| 35 | /***************************************************************************** |
| 36 | * Filename: |
| 37 | * --------- |
| 38 | * sbp_public_utility.h |
| 39 | * |
| 40 | * Description: |
| 41 | * ------------ |
| 42 | * This file is intends for put the header of SBP public API |
| 43 | * |
| 44 | * Author: |
| 45 | * ------- |
| 46 | * ------- |
| 47 | * |
| 48 | *============================================================================ |
| 49 | *****************************************************************************/ |
| 50 | |
| 51 | #ifndef _SBP_PUBLIC_UTILITY_H |
| 52 | #define _SBP_PUBLIC_UTILITY_H |
| 53 | |
| 54 | #ifdef __cplusplus |
| 55 | extern "C" { |
| 56 | #endif |
| 57 | |
| 58 | #include "kal_general_types.h" |
| 59 | #include "kal_public_defs.h" |
| 60 | #include "sim_exported_enum.h" |
| 61 | |
| 62 | #define SBP_ID_INVALID 0xffffffff |
| 63 | #define SBP_SIM_SLOT_ID_INVALID 0xff |
| 64 | |
| 65 | |
| 66 | /***************************************************************************** |
| 67 | * DESCRIPTION |
| 68 | * This enum is defined for Single Binary Platform (SBP) features |
| 69 | * NVRAM saves one binary value for each feature |
| 70 | *****************************************************************************/ |
| 71 | typedef enum |
| 72 | { |
| 73 | //Please add SBP features in sbp_feature.def |
| 74 | |
| 75 | #define SBP_FEATURE_DEF_BEGIN(x) |
| 76 | #define SBP_FEATURE_DEF(FEATURE, ATTR, DESC, DESC_V0,DESC_V1, DEFAULT_VAL) FEATURE, |
| 77 | #define SBP_FEATURE_DEF_END(x) |
| 78 | |
| 79 | #include "sbp_feature.def" |
| 80 | #undef SBP_FEATURE_DEF_BEGIN |
| 81 | #undef SBP_FEATURE_DEF |
| 82 | #undef SBP_FEATURE_DEF_END |
| 83 | |
| 84 | |
| 85 | SBP_MAX_MD_FEATURE |
| 86 | }sbp_md_feature_enum; |
| 87 | |
| 88 | /***************************************************************************** |
| 89 | * DESCRIPTION |
| 90 | * This enum is defined for Single Binary Platform (SBP) features |
| 91 | * NVRAM saves one byte value for each feature |
| 92 | *****************************************************************************/ |
| 93 | typedef enum |
| 94 | { |
| 95 | //Please add SBP data in sbp_data.def |
| 96 | |
| 97 | #define SBP_DATA_DEF(ID, FEATURE, ATTR, DESC) FEATURE, |
| 98 | #define SBP_DATA_DEF_BIT(ID, FEATURE, ATTR) FEATURE, |
| 99 | |
| 100 | #include "sbp_data.def" |
| 101 | #undef SBP_DATA_DEF |
| 102 | #undef SBP_DATA_DEF_BIT |
| 103 | |
| 104 | SBP_DATA_MAX_MD_FEATURE |
| 105 | }sbp_md_feature_data_enum; |
| 106 | |
| 107 | #if defined (__TC01_NVRAM__) || defined(__TC01__) // __TC01_CUST_SBP__ |
| 108 | /***************************************************************************** |
| 109 | * DESCRIPTION |
| 110 | * This enum is defined for SBP by the customer itself. |
| 111 | * NVRAM saves one binary value for each feature |
| 112 | *****************************************************************************/ |
| 113 | typedef enum |
| 114 | { |
| 115 | //Please add SBP features in sbp_feature_cust.def |
| 116 | #define SBP_FEATURE_DEF_BEGIN(x) |
| 117 | #define SBP_FEATURE_DEF(FEATURE, ATTR, DESC, DESC_V0,DESC_V1, DEFAULT_VAL) FEATURE, |
| 118 | #define SBP_FEATURE_DEF_END(x) |
| 119 | |
| 120 | #include "sbp_feature_cust.def" |
| 121 | #undef SBP_FEATURE_DEF_BEGIN |
| 122 | #undef SBP_FEATURE_DEF |
| 123 | #undef SBP_FEATURE_DEF_END |
| 124 | |
| 125 | SBP_CUSTOM_MAX_MD_FEATURE |
| 126 | }sbp_md_feature_custom_enum; |
| 127 | #endif |
| 128 | |
| 129 | |
| 130 | /* SBP Test Mode Enum */ |
| 131 | typedef enum |
| 132 | { |
| 133 | SBP_TEST_MODE_NONE = 0, |
| 134 | SBP_TEST_MODE_1, // Obsolete, use NVRAM_EF_SBP_CUSTOM_MODEM_CONFIG_LID to specify test feature value |
| 135 | SBP_TEST_MODE_2, // To skip hard coded feature changes |
| 136 | SBP_TEST_MODE_MAX |
| 137 | }sbp_test_mode_enum; |
| 138 | |
| 139 | /* SBP ATTRIBUTE Bitmask */ |
| 140 | typedef enum |
| 141 | { |
| 142 | SBP_ATTR_NONE = 0, |
| 143 | SBP_ATTR_NOT_SUPPORT_DYNAMIC_SBP = 0x01, /* bit 1 is for current SBP NV will keep when Dynamic SBP change */ |
| 144 | SBP_ATTR_ALL = 0xff |
| 145 | }sbp_attribute_enum; |
| 146 | |
| 147 | /** |
| 148 | * DESCRIPTION |
| 149 | * This enum is TO define RUIM configuration. |
| 150 | **/ |
| 151 | typedef enum |
| 152 | { |
| 153 | SBP_RUIM_DISABLED = 0x00, /* Non-RUIM configuration */ |
| 154 | SBP_RUIM_ENABLED = 0x01 /* RUIM configuration */ |
| 155 | }c2k_sbp_ruim_config_enum; |
| 156 | |
| 157 | /** |
| 158 | * SBP(Single Binary Platform) modem configuration |
| 159 | * a bitmap for all modem configurable feature |
| 160 | **/ |
| 161 | typedef struct |
| 162 | { |
| 163 | kal_uint32 sbp_mode; //reserved for usage |
| 164 | kal_uint8 modem_sbp_config[(SBP_MAX_MD_FEATURE/8)+1]; //the size depends on SBP_MAX_MD_FEATURE |
| 165 | } nvram_ef_sbp_modem_config_struct; |
| 166 | |
| 167 | #if defined (__TC01_NVRAM__) || defined(__TC01__) // __TC01_CUST_SBP__ |
| 168 | /*MUSE - ALPS0144925 */ |
| 169 | /*Customer's specific Single Binary Platform (SBP) features */ |
| 170 | #define NVRAM_EF_SBP_MODEM_CONFIG_TOTAL (2) |
| 171 | #define NVRAM_CUST_SBP_IDX 2 |
| 172 | |
| 173 | #else /* __TC01__ */ |
| 174 | #define NVRAM_EF_SBP_MODEM_CONFIG_TOTAL (1) |
| 175 | #endif /* __TC01__ */ |
| 176 | |
| 177 | #define NVRAM_EF_SBP_MODEM_CONFIG_SIZE sizeof(nvram_ef_sbp_modem_config_struct) |
| 178 | |
| 179 | /** |
| 180 | * SBP(Single Binary Platform) modem data configuration |
| 181 | * a byte for each modem configurable feature |
| 182 | **/ |
| 183 | typedef struct |
| 184 | { |
| 185 | kal_uint32 sbp_mode; //reserved for usage |
| 186 | kal_uint8 modem_sbp_data_config[SBP_DATA_MAX_MD_FEATURE]; |
| 187 | } nvram_ef_sbp_modem_data_config_struct; |
| 188 | |
| 189 | #define NVRAM_EF_SBP_MODEM_DATA_CONFIG_TOTAL (1) |
| 190 | #define NVRAM_EF_SBP_MODEM_DATA_CONFIG_SIZE sizeof(nvram_ef_sbp_modem_data_config_struct) |
| 191 | |
| 192 | /** |
| 193 | * SBP(Single Binary Platform) modem feature/data customization |
| 194 | * a list of customized SBP feature / feature data |
| 195 | * priorirty: customization > DSBP > SBP |
| 196 | **/ |
| 197 | |
| 198 | #define SBP_MAX_CUSTOM_CONFIG (100) // allows 100 custom configurations |
| 199 | |
| 200 | typedef enum |
| 201 | { |
| 202 | SBP_CUST_CFG_TYPE_NONE = 0, |
| 203 | SBP_CUST_CFG_TYPE_FEATURE, |
| 204 | SBP_CUST_CFG_TYPE_DATA |
| 205 | }sbp_cust_cfg_type_enum; |
| 206 | |
| 207 | typedef struct{ |
| 208 | kal_uint32 sbp_id; |
| 209 | sbp_cust_cfg_type_enum sbp_cust_cfg_type; |
| 210 | kal_uint16 sbp_cust_cfg_feature; // enum for SBP feature or SBP feature data |
| 211 | kal_uint8 sbp_cust_cfg_feature_val; |
| 212 | }sbp_custom_config_struct; |
| 213 | |
| 214 | typedef struct{ |
| 215 | sbp_custom_config_struct sbp_custom_config[SBP_MAX_CUSTOM_CONFIG]; |
| 216 | }nvram_ef_sbp_custom_modem_config_struct; |
| 217 | |
| 218 | #define NVRAM_EF_SBP_CUSTOM_MODEM_CONFIG_TOTAL (1) |
| 219 | #define NVRAM_EF_SBP_CUSTOM_MODEM_CONFIG_SIZE sizeof(nvram_ef_sbp_custom_modem_config_struct) |
| 220 | |
| 221 | |
| 222 | typedef struct{ |
| 223 | kal_uint32 mcf_dsbp_dr_time; |
| 224 | kal_uint32 max_mcf_dsbp_dr_time; |
| 225 | }nvram_ef_sbp_dsbp_config_struct; |
| 226 | |
| 227 | #define NVRAM_EF_SBP_DSBP_CONFIG_TOTAL (1) |
| 228 | #define NVRAM_EF_SBP_DSBP_CONFIG_SIZE sizeof(nvram_ef_sbp_dsbp_config_struct) |
| 229 | |
| 230 | /** |
| 231 | * SBP(Single Binary Platform) ID - plmn_id/iccid customization |
| 232 | * a customized SBP_ID - plmn_id/iccid mapping table |
| 233 | * priorirty: customization > internal static g_l4bsbp_iccid_prefix_table > internal static g_l4bsbp_plmn_table |
| 234 | **/ |
| 235 | |
| 236 | #define SBP_MAX_CUSTOM_SBP_ID_ICCID_MAPPING (100) // allows 100 custom mapping |
| 237 | #define SBP_MAX_CUSTOM_SBP_ID_PLMN_MAPPING (500) // allows 500 custom mapping |
| 238 | #define SBP_MAX_CUSTOM_ICCID_LEN 21 |
| 239 | |
| 240 | typedef struct{ |
| 241 | kal_uint8 iccid_prefix[SBP_MAX_CUSTOM_ICCID_LEN]; |
| 242 | kal_uint32 sbp_id; |
| 243 | }sbp_custom_sbp_id_iccid_mapping_struct; |
| 244 | |
| 245 | typedef struct{ |
| 246 | kal_uint32 plmn_range_start; |
| 247 | kal_uint32 plmn_range_end; |
| 248 | kal_uint32 sbp_id; |
| 249 | }sbp_custom_sbp_id_plmn_mapping_struct; |
| 250 | |
| 251 | typedef struct{ |
| 252 | kal_uint32 num_of_iccid_map; |
| 253 | sbp_custom_sbp_id_iccid_mapping_struct sbp_custom_sbp_id_iccid_map_table[SBP_MAX_CUSTOM_SBP_ID_ICCID_MAPPING]; |
| 254 | kal_uint32 num_of_plmn_map; |
| 255 | sbp_custom_sbp_id_plmn_mapping_struct sbp_custom_sbp_id_plmn_map_table[SBP_MAX_CUSTOM_SBP_ID_PLMN_MAPPING]; |
| 256 | }nvram_ef_sbp_custom_sbp_id_mapping_struct; |
| 257 | |
| 258 | #define NVRAM_EF_SBP_CUSTOM_SBP_ID_MAPPING_TOTAL (1) |
| 259 | #define NVRAM_EF_SBP_CUSTOM_SBP_ID_MAPPING_SIZE sizeof(nvram_ef_sbp_custom_sbp_id_mapping_struct) |
| 260 | |
| 261 | /** |
| 262 | * SBP(Single Binary Platform) ID list which need MD CXP reboot flow |
| 263 | **/ |
| 264 | |
| 265 | #define SBP_MAX_MDCXP_SBP_ID_NUM (100) // allows 100 operators |
| 266 | |
| 267 | typedef struct{ |
| 268 | kal_uint32 sbp_id_list[SBP_MAX_MDCXP_SBP_ID_NUM]; |
| 269 | }nvram_ef_sbp_mdcxp_sbp_id_list_struct; |
| 270 | |
| 271 | #define NVRAM_EF_SBP_MDCXP_SBP_ID_LIST_TOTAL (1) |
| 272 | #define NVRAM_EF_SBP_MDCXP_SBP_ID_LIST_SIZE sizeof(nvram_ef_sbp_mdcxp_sbp_id_list_struct) |
| 273 | |
| 274 | typedef struct |
| 275 | { |
| 276 | kal_uint8 mcc_mnc[7]; |
| 277 | kal_uint32 sbp_id; |
| 278 | } mccmnc_to_sbp_id_struct; |
| 279 | |
| 280 | typedef struct |
| 281 | { |
| 282 | kal_char csc_salecode[3]; |
| 283 | kal_char network_code[3]; |
| 284 | kal_char network_code_2[3]; |
| 285 | } sbp_salecode_struct; |
| 286 | |
| 287 | typedef enum |
| 288 | { |
| 289 | SBP_ID_OM = 0, |
| 290 | SBP_ID_UNKNOWN = SBP_ID_OM, |
| 291 | |
| 292 | /* the Operator enum*/ |
| 293 | SBP_ID_CMCC = 1, |
| 294 | SBP_ID_CU = 2, |
| 295 | SBP_ID_ORANGE = 3, |
| 296 | SBP_ID_TMO_EU = 5, |
| 297 | SBP_ID_VODAFONE = 6, |
| 298 | SBP_ID_ATT = 7, |
| 299 | SBP_ID_TMO_US = 8, |
| 300 | SBP_ID_CT = 9, |
| 301 | SBP_ID_TIER_2 = 10, |
| 302 | SBP_ID_H3G = 11, |
| 303 | SBP_ID_VERIZON = 12, |
| 304 | SBP_ID_TELEFONICA = 15, |
| 305 | SBP_ID_EE = 16, |
| 306 | SBP_ID_DOCOMO = 17, |
| 307 | SBP_ID_RJL = 18, |
| 308 | SBP_ID_TELSTRA = 19, |
| 309 | SBP_ID_SPRINT = 20, |
| 310 | SBP_ID_DISH = 21, |
| 311 | SBP_ID_SOFTBANK = 50, |
| 312 | SBP_ID_CSL = 100, |
| 313 | SBP_ID_PCCW = 101, |
| 314 | SBP_ID_SMT = 102, |
| 315 | SBP_ID_SINGTEL = 103, |
| 316 | SBP_ID_STARHUB = 104, |
| 317 | SBP_ID_AMX = 105, |
| 318 | SBP_ID_3HK = 106, |
| 319 | SBP_ID_SFR = 107, |
| 320 | SBP_ID_TWN = 108, |
| 321 | SBP_ID_CHT = 109, |
| 322 | SBP_ID_FET = 110, |
| 323 | SBP_ID_VDF_INDIA = 111, |
| 324 | SBP_ID_TELCEL = 112, |
| 325 | SBP_ID_BEELINE = 113, |
| 326 | SBP_ID_KT = 114, |
| 327 | SBP_ID_SKT = 115, |
| 328 | SBP_ID_UPLUS = 116, |
| 329 | SBP_ID_SMARTFREN = 117, |
| 330 | SBP_ID_YTL = 118, |
| 331 | SBP_ID_NATCOM = 119, |
| 332 | SBP_ID_CLARO = 120, |
| 333 | SBP_ID_BELL = 121, |
| 334 | SBP_ID_AIS = 122, |
| 335 | SBP_ID_APTG = 124, |
| 336 | SBP_ID_DTAC = 125, |
| 337 | SBP_ID_AVEA = 126, |
| 338 | SBP_ID_MEGAFON = 127, |
| 339 | SBP_ID_DNA = 128, |
| 340 | SBP_ID_KDDI = 129, |
| 341 | SBP_ID_TIM = 130, |
| 342 | SBP_ID_TRUEMOVER = 131, |
| 343 | SBP_ID_MOVISTAR = 132, |
| 344 | SBP_ID_DU = 133, |
| 345 | SBP_ID_ELISA = 134, |
| 346 | SBP_ID_MTS = 135, |
| 347 | SBP_ID_ENTEL = 136, |
| 348 | SBP_ID_TELE2 = 137, |
| 349 | SBP_ID_BOUYGUES = 139, |
| 350 | SBP_ID_MTN = 140, |
| 351 | SBP_ID_CELL_C = 141, |
| 352 | SBP_ID_TURKCELL = 143, |
| 353 | SBP_ID_SMILTE = 144, |
| 354 | SBP_ID_CRICKET = 145, |
| 355 | SBP_ID_ETISALAT = 146, |
| 356 | SBP_ID_AIRTEL = 147, |
| 357 | SBP_ID_SEATEL = 148, |
| 358 | SBP_ID_CMHK = 149, |
| 359 | SBP_ID_SWISSCOM_SCHWEIZ_AG = 150, |
| 360 | SBP_ID_M1 = 151, |
| 361 | SBP_ID_OPTUS = 152, |
| 362 | SBP_ID_VHA = 153, |
| 363 | SBP_ID_TELIA = 154, |
| 364 | SBP_ID_DIGI = 155, |
| 365 | SBP_ID_TELENOR = 156, |
| 366 | SBP_ID_TELUS = 157, |
| 367 | SBP_ID_ZAIN = 158, |
| 368 | SBP_ID_STC = 159, |
| 369 | SBP_ID_WEBE = 160, |
| 370 | SBP_ID_PLAY = 161, |
| 371 | SBP_ID_FREEDOM = 162, |
| 372 | SBP_ID_DIALOG = 163, |
| 373 | SBP_ID_TELENET = 164, |
| 374 | SBP_ID_SUNRISE = 165, |
| 375 | SBP_ID_SALT = 166, |
| 376 | SBP_ID_EIR = 168, |
| 377 | SBP_ID_VIPNET = 169, |
| 378 | SBP_ID_PARTNER = 170, |
| 379 | SBP_ID_WOM = 171, |
| 380 | SBP_ID_ALTICE = 172, |
| 381 | SBP_ID_NZ = 174, |
| 382 | SBP_ID_TDC = 175, |
| 383 | SBP_ID_TSTAR = 176, |
| 384 | SBP_ID_TELEKOM_EGYPT = 177, |
| 385 | SBP_ID_SMART = 178, |
| 386 | SBP_ID_ALLAI_NEWROZ = 179, |
| 387 | SBP_ID_SWAZI_MOBILE = 180, |
| 388 | SBP_ID_TELKOM_SA = 181, |
| 389 | SBP_ID_PROXIMUS = 182, |
| 390 | SBP_ID_PERSONAL = 183, |
| 391 | SBP_ID_VIETTEL = 184, |
| 392 | SBP_ID_2DEGREES = 185, |
| 393 | SBP_ID_IDEA = 186, |
| 394 | SBP_ID_SAFARICOM = 187, |
| 395 | SBP_ID_A1 = 188, |
| 396 | SBP_ID_UMOBILE = 189, |
| 397 | SBP_ID_TELKOM_KENYA = 190, |
| 398 | SBP_ID_GRAMEENPHONE = 191, |
| 399 | SBP_ID_ROBI = 192, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 400 | SBP_ID_BANGLALINK = 193, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 401 | SBP_ID_O2 = 195, |
| 402 | SBP_ID_FIRSTNET = 196, |
| 403 | SBP_ID_SBERBANK = 198, |
| 404 | SBP_ID_VIVACOM = 199, |
| 405 | SBP_ID_JTL_KENYA = 200, |
| 406 | SBP_ID_KPN_NETHERLANDS = 201, |
| 407 | SBP_ID_SPARK = 202, |
| 408 | SBP_ID_NOS = 203, |
| 409 | SBP_ID_ROGERS = 204, |
| 410 | SBP_ID_ALTAN = 205, |
| 411 | SBP_ID_SKY = 206, |
| 412 | SBP_ID_CTM = 207, |
| 413 | SBP_ID_3MACAU = 208, |
| 414 | SBP_ID_AVANTEL = 209, |
| 415 | SBP_ID_BSNL = 210, |
| 416 | SBP_ID_CW = 211, |
| 417 | SBP_ID_OPEN_MOBILE = 212, |
| 418 | SBP_ID_IDC = 214, |
| 419 | SBP_ID_MOTIV = 213, |
| 420 | SBP_ID_CELLCARD = 215, |
| 421 | SBP_ID_ZONG = 216, |
| 422 | SBP_ID_TELEKOM_SLOVENIA = 217, |
| 423 | SBP_ID_RAKUTEN = 218, |
| 424 | SBP_ID_MYTEL = 219, |
| 425 | SBP_ID_TIGO = 220, |
| 426 | SBP_ID_TPG = 221, |
| 427 | SBP_ID_ACG = 222, |
| 428 | SBP_ID_OOREDOO = 223, |
| 429 | SBP_ID_TELKOMSEL = 224, |
| 430 | SBP_ID_XL = 225, |
| 431 | SBP_ID_WIND = 227, |
| 432 | SBP_ID_CELCOM = 228, |
| 433 | SBP_ID_MAXIS = 231, |
| 434 | SBP_ID_MOBITEL = 232, |
| 435 | SBP_ID_PELEPHONE = 233, |
| 436 | SBP_ID_PLUS = 234, |
| 437 | SBP_ID_VIP = 235, |
| 438 | SBP_ID_USCC = 236, |
| 439 | SBP_ID_ICE = 237, |
| 440 | SBP_ID_VIDEOTRON = 238, |
| 441 | SBP_ID_EASTLINK = 239, |
| 442 | SBP_ID_XPLORE_MOBILE = 240, |
| 443 | SBP_ID_CLARO_PUERTO_RICO = 241, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 444 | SBP_ID_INWI = 242, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 445 | SBP_ID_GLOBE = 243, |
| 446 | SBP_ID_METFONE = 244, |
| 447 | SBP_ID_VIETNAMOBILE = 245, |
| 448 | SBP_ID_OOREDOO_QATAR = 246, |
| 449 | SBP_ID_MAROC_TELECOM = 247, |
| 450 | SBP_ID_EXECULINK = 248, |
| 451 | SBP_ID_WIGHTMAN = 249, |
| 452 | SBP_ID_UNION = 250, |
| 453 | SBP_ID_CORR = 251, |
| 454 | SBP_ID_PLATEAU = 252, |
| 455 | SBP_ID_GTA = 253, |
| 456 | SBP_ID_NEP = 254, |
| 457 | SBP_ID_CELLULAR_ONE_NEAZ = 255, |
| 458 | SBP_ID_CBW = 256, |
| 459 | SBP_ID_VIAERO = 257, |
| 460 | SBP_ID_CELLULAR_ONE_MTPCS = 258, |
| 461 | SBP_ID_EPIC = 259, |
| 462 | SBP_ID_IMMIX = 260, |
| 463 | SBP_ID_ASTAC = 261, |
| 464 | SBP_ID_IWIRELESS = 262, |
| 465 | SBP_ID_DTC = 263, |
| 466 | SBP_ID_PINE = 264, |
| 467 | SBP_ID_LONG_LINES = 265, |
| 468 | SBP_ID_CELLULAR_ONE_EIL = 266, |
| 469 | SBP_ID_GCI = 267, |
| 470 | SBP_ID_MOSAIC = 268, |
| 471 | SBP_ID_NEWCORE = 269, |
| 472 | SBP_ID_TELALASKA = 270, |
| 473 | SBP_ID_SAGEBRUSH = 271, |
| 474 | SBP_ID_GTT = 272, |
| 475 | SBP_ID_OPTIMERA = 273, |
| 476 | SBP_ID_YOIGO = 274, |
| 477 | SBP_ID_LIFECELL = 275, |
| 478 | SBP_ID_ALTICE_US = 276, |
| 479 | SBP_ID_TELEMACH = 277, |
| 480 | SBP_ID_JAZZ = 278, |
| 481 | SBP_ID_DITO = 279, |
| 482 | SBP_ID_OTZ = 280, |
| 483 | SBP_ID_KYIVSTAR = 281, |
| 484 | SBP_ID_MOBILY = 282, |
| 485 | SBP_ID_MEO = 283, |
| 486 | SBP_ID_MTS_SERBIA = 284, |
| 487 | SBP_ID_VINAPHONE = 285, |
| 488 | SBP_ID_MNSHUBS = 286, |
| 489 | SBP_ID_FREE = 287, |
| 490 | SBP_ID_VIRGIN = 288, |
| 491 | SBP_ID_BATELCO = 289, |
| 492 | SBP_ID_OMANTEL = 290, |
| 493 | SBP_ID_LMT = 291, |
| 494 | SBP_ID_CMHK_HKIA = 292, |
| 495 | SBP_ID_POST = 293, |
| 496 | SBP_ID_MPT = 294, |
| 497 | SBP_ID_NTC = 295, |
| 498 | SBP_ID_CAROLINA_WEST_WIRELESS = 296, |
| 499 | SBP_ID_FASTWEB = 297, |
| 500 | SBP_ID_UMNIAH = 298, |
| 501 | SBP_ID_NRJ = 299, |
| 502 | SBP_ID_TANGO = 301, |
| 503 | SBP_ID_OOREDOO_OMAN = 302, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 504 | SBP_ID_ILIAD = 303, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 505 | SBP_ID_CTMO = 304, |
| 506 | SBP_ID_CUHK = 306, |
| 507 | SBP_ID_CELLCOM = 307, |
| 508 | SBP_ID_HOTMOBILE = 310, |
| 509 | SBP_ID_BITE = 312, |
| 510 | SBP_ID_AXTEL = 313, |
| 511 | SBP_ID_TELE_GREENLAND = 314, |
| 512 | SBP_ID_TELE2_KAZAK = 315, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 513 | SBP_ID_NTWLS = 316, |
| 514 | SBP_ID_COMMNET_WIRELESS = 317, |
| 515 | SBP_ID_VIANOVA = 318, |
| 516 | SBP_ID_MONACO = 319, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 517 | SBP_ID_CORIOLIS = 320, |
| 518 | SBP_ID_ORA_VITI = 321, |
| 519 | SBP_ID_UPC = 322, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 520 | SBP_ID_LYCAMOBILE = 323, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 521 | SBP_ID_MOLDCELL = 324, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 522 | SBP_ID_JAMBOTEL = 325, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 523 | SBP_ID_9MOBILE = 326, |
| 524 | SBP_ID_SASKTEL = 327, |
| 525 | SBP_ID_VOO = 328, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 526 | SBP_ID_PLINTRON = 329, |
| 527 | SBP_ID_SOUTHERN_LINC = 332, |
| 528 | SBP_ID_CELLCOM_USA = 333, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 529 | SBP_ID_TASHICELL = 334, |
| 530 | SBP_ID_TOT = 335, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 531 | SBP_ID_MOBIFONE = 336, |
| 532 | SBP_ID_ANTEL = 337, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 533 | SBP_ID_SPUSU = 338, |
| 534 | SBP_ID_UNITEL = 339, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 535 | SBP_ID_VODAFONE_PNG = 340, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 536 | SBP_ID_UCELL = 341, |
| 537 | SBP_ID_4KA = 344, |
| 538 | SBP_ID_PRIMETEL = 345, |
| 539 | SBP_ID_AIRTEL_KENYA = 347, |
| 540 | SBP_ID_NCELL = 348, |
| 541 | SBP_ID_GIBTELECOM = 350, |
| 542 | SBP_ID_MOD_EGYPT = 352, |
| 543 | SBP_ID_WE4G = 353, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 544 | SBP_ID_POSTEMOBILE = 354, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 545 | SBP_ID_ALFA = 355, |
| 546 | SBP_ID_RAIN = 356, |
| 547 | SBP_ID_CNT = 357, |
| 548 | SBP_ID_TELMA = 358, |
| 549 | SBP_ID_ALIV = 359, |
| 550 | SBP_ID_CTEXCEL = 360, |
| 551 | SBP_ID_BMOBILE = 362, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 552 | SBP_ID_CSPIRE = 363, |
| 553 | SBP_ID_UNITED_WIRELESS = 364, |
| 554 | SBP_ID_IVCEL = 365, |
| 555 | SBP_ID_APPALACHIAN = 366, |
| 556 | SBP_ID_JAMES_VALLEY = 367, |
| 557 | SBP_ID_PIONEER = 368, |
| 558 | SBP_ID_PINE_BELT = 369, |
| 559 | SBP_ID_STRATA = 370, |
| 560 | SBP_ID_SILVER_STAR = 371, |
| 561 | SBP_ID_ONECOMM = 372, |
| 562 | SBP_ID_CORDOVA = 373, |
| 563 | SBP_ID_COPPER_VALLEY = 374, |
| 564 | SBP_ID_BLUE_WIRELESS = 375, |
| 565 | SBP_ID_INLAND = 376, |
| 566 | SBP_ID_OOREDOO_TUNISIA = 377, |
| 567 | SBP_ID_GEOVERSE = 378, |
| 568 | SBP_ID_PTCI = 379, |
| 569 | SBP_ID_ASIA_CELL = 381, |
| 570 | SBP_ID_ZEOP = 382, |
| 571 | SBP_ID_MAGTI = 383, |
| 572 | SBP_ID_BAKCEL = 384, |
| 573 | SBP_ID_BHMOBILE = 385, |
| 574 | SBP_ID_ENETWORKS = 386, |
| 575 | SBP_ID_WCW = 387, |
rjw | 2b1408e | 2022-12-19 11:19:29 +0800 | [diff] [blame] | 576 | SBP_ID_CBN = 388, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 577 | SBP_ID_UNITEL_LAOS = 389, |
| 578 | SBP_ID_MOBILE_NATION = 392, |
| 579 | SBP_ID_THUMB = 396, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 580 | SBP_ID_LICT = 398, |
yu.dong | 99f21a2 | 2023-05-30 22:15:37 -0700 | [diff] [blame] | 581 | SBP_ID_IMAGINE = 403, |
| 582 | SBP_ID_PROGRESIF = 404, |
| 583 | SBP_ID_UNN = 405, |
| 584 | SBP_ID_DST = 406, |
| 585 | SBP_ID_AMERICANET = 407, |
| 586 | SBP_ID_BITEL = 408, |
| 587 | SBP_ID_MTEL = 410, |
| 588 | SBP_ID_EVOLVE_BROADBAND = 411, |
| 589 | SBP_ID_STANDING_ROCK_TELECOM = 412, |
| 590 | SBP_ID_BRISANET = 416, |
| 591 | SBP_ID_ATLAS_TELECOM = 417, |
| 592 | SBP_ID_EMTEL = 418, |
| 593 | SBP_ID_REDBULL = 420, |
| 594 | SBP_ID_NLC = 426, |
rjw | 6c1fd8f | 2022-11-30 14:33:01 +0800 | [diff] [blame] | 595 | |
| 596 | /* Lab testing SBP ID */ |
| 597 | SBP_ID_ERICSSON = 1001, |
| 598 | SBP_ID_NOKIA = 1002, |
| 599 | SBP_ID_MTK_HQLAB_ERICSSON = 1003, |
| 600 | SBP_ID_HUAWEI_IMS_LAB = 1004, |
| 601 | |
| 602 | |
| 603 | /* Legacy C2K SBP ID */ |
| 604 | SBP_ID_GENERIC = SBP_ID_OM, |
| 605 | SBP_ID_VERIZON_C2K = SBP_ID_VERIZON, |
| 606 | |
| 607 | #ifdef __TC10__ |
| 608 | /* START - allocated ID for Samsung 10000 ~ 20000 */ |
| 609 | |
| 610 | // SBP ID FOR CHINA 10001 ~ 10999 |
| 611 | SBP_ID_CHINA = 10000, |
| 612 | // SBP ID FOR GLOBAL 11001 ~ 11999 |
| 613 | SBP_ID_GLOBAL = 11000, |
| 614 | SBP_ID_TNZ, // TNZ - SPARK (Formerly Telecom New Zealand) |
| 615 | // SBP ID FOR JPN 12001 ~ 12999 |
| 616 | SBP_ID_JPN = 12000, |
| 617 | // SBP ID FOR KOR 13001 ~ 13999 |
| 618 | SBP_ID_KOR = 13000, |
| 619 | // SBP ID FOR LATIN_AMERICA 14001 ~ 14999 |
| 620 | SBP_ID_LATIN_AMERICA = 14000, |
| 621 | // SBP ID FOR N_AMERICA_CAN 15001 ~ 15999 |
| 622 | SBP_ID_N_AMERICA_CAN = 15000, |
| 623 | // SBP ID FOR N_AMERICA 16001 ~ 16999 |
| 624 | SBP_ID_N_AMERICA = 16000, |
| 625 | // SBP ID FOR N_AMERICA_3GPP2 17001 ~ 17999 |
| 626 | SBP_ID_N_AMERICA_3GPP2 = 17000, |
| 627 | |
| 628 | /* END - allocated ID for Samsung 10000 ~ 20000 */ |
| 629 | |
| 630 | SBP_ID_MAX = 20000, // MAX |
| 631 | #endif /* __TC10__ */ |
| 632 | |
| 633 | } sbp_id_enum; |
| 634 | |
| 635 | /* -------------------------- |
| 636 | * End of SBP Configuration |
| 637 | * --------------------------- */ |
| 638 | |
| 639 | |
| 640 | /***************************************************************************** |
| 641 | * FUNCTION |
| 642 | * sbp_query_md_feature() |
| 643 | * |
| 644 | * DESCRIPTION |
| 645 | * This function is used to query modem configuration |
| 646 | * |
| 647 | * PARAMETERS |
| 648 | * feature [IN] modem feature |
| 649 | * |
| 650 | * RETURNS |
| 651 | * KAL_TRUE : if this feature is turned on |
| 652 | * KAL_FALSE : if this feature is turned off |
| 653 | *****************************************************************************/ |
| 654 | extern kal_bool sbp_query_md_feature(sbp_md_feature_enum feature); |
| 655 | |
| 656 | /***************************************************************************** |
| 657 | * FUNCTION |
| 658 | * sbp_query_id() |
| 659 | * |
| 660 | * DESCRIPTION |
| 661 | * This function is used to query SBP ID received by modem |
| 662 | * |
| 663 | * PARAMETERS |
| 664 | * [IN] N/A |
| 665 | * RETURNS |
| 666 | * the unsigned 4-byte value for the SBP ID |
| 667 | *****************************************************************************/ |
| 668 | extern kal_uint32 sbp_query_id(void); |
| 669 | |
| 670 | /***************************************************************************** |
| 671 | * FUNCTION |
| 672 | * sbp_query_sub_id() |
| 673 | * |
| 674 | * DESCRIPTION |
| 675 | * This function is used to query SBP Sub ID received by modem |
| 676 | * |
| 677 | * PARAMETERS |
| 678 | * [IN] N/A |
| 679 | * RETURNS |
| 680 | * the unsigned 4-byte value for the SBP Sub ID |
| 681 | *****************************************************************************/ |
| 682 | extern kal_uint32 sbp_query_sub_id(void); |
| 683 | |
| 684 | |
| 685 | /***************************************************************************** |
| 686 | * FUNCTION |
| 687 | * sbp_query_md_feature_for_c2k() |
| 688 | * |
| 689 | * DESCRIPTION |
| 690 | * This function is used to query modem configuration and used by C2K team only |
| 691 | * The function will judge current active PS using C2K's API and return the corresponding setting. |
| 692 | * |
| 693 | * PARAMETERS |
| 694 | * feature [IN] modem feature |
| 695 | * |
| 696 | * RETURNS |
| 697 | * KAL_TRUE : if this feature is turned on |
| 698 | * KAL_FALSE : if this feature is turned off |
| 699 | *****************************************************************************/ |
| 700 | extern kal_bool sbp_query_md_feature_for_c2k(sbp_md_feature_enum feature); |
| 701 | |
| 702 | /***************************************************************************** |
| 703 | * FUNCTION |
| 704 | * sbp_query_md_feature_by_ps() |
| 705 | * |
| 706 | * DESCRIPTION |
| 707 | * This function is used to query modem configuration according to the PS ID |
| 708 | * |
| 709 | * PARAMETERS |
| 710 | * feature [IN] modem feature |
| 711 | * ps_id [IN] PS ID |
| 712 | * |
| 713 | * RETURNS |
| 714 | * KAL_TRUE : if this feature is turned on |
| 715 | * KAL_FALSE : if this feature is turned off |
| 716 | *****************************************************************************/ |
| 717 | extern kal_bool sbp_query_md_feature_by_ps(sbp_md_feature_enum feature, protocol_id_enum ps_id); |
| 718 | |
| 719 | /***************************************************************************** |
| 720 | * FUNCTION |
| 721 | * sbp_query_md_feature_no_overwrite() |
| 722 | * |
| 723 | * DESCRIPTION |
| 724 | * This function is used to query modem configuration without overwrite |
| 725 | * |
| 726 | * PARAMETERS |
| 727 | * feature [IN] modem feature |
| 728 | * |
| 729 | * RETURNS |
| 730 | * KAL_TRUE : if this feature is turned on |
| 731 | * KAL_FALSE : if this feature is turned off |
| 732 | *****************************************************************************/ |
| 733 | extern kal_bool sbp_query_md_feature_no_overwrite(sbp_md_feature_enum feature); |
| 734 | |
| 735 | /***************************************************************************** |
| 736 | * FUNCTION |
| 737 | * sbp_query_md_feature_no_overwrite_by_ps() |
| 738 | * |
| 739 | * DESCRIPTION |
| 740 | * This function is used to query modem configuration without overwrite according to the PS ID |
| 741 | * |
| 742 | * PARAMETERS |
| 743 | * feature [IN] modem feature |
| 744 | * ps_id [IN] PS ID |
| 745 | * |
| 746 | * RETURNS |
| 747 | * KAL_TRUE : if this feature is turned on |
| 748 | * KAL_FALSE : if this feature is turned off |
| 749 | *****************************************************************************/ |
| 750 | extern kal_bool sbp_query_md_feature_no_overwrite_by_ps(sbp_md_feature_enum feature, protocol_id_enum ps_id); |
| 751 | |
| 752 | |
| 753 | /***************************************************************************** |
| 754 | * FUNCTION |
| 755 | * sbp_set_md_feature() |
| 756 | * |
| 757 | * DESCRIPTION |
| 758 | * This function is used to set modem configuration |
| 759 | * |
| 760 | * PARAMETERS |
| 761 | * feature [IN] modem feature |
| 762 | * is_turned_on [IN] |
| 763 | * sbp_feature_ptr [IN/OUT] |
| 764 | * |
| 765 | * RETURNS |
| 766 | * KAL_TRUE if success; otherwise KAL_FALSE |
| 767 | *****************************************************************************/ |
| 768 | extern kal_bool sbp_set_md_feature(sbp_md_feature_enum feature, |
| 769 | kal_bool is_turned_on, |
| 770 | nvram_ef_sbp_modem_config_struct *sbp_feature_ptr); |
| 771 | |
| 772 | /***************************************************************************** |
| 773 | * FUNCTION |
| 774 | * sbp_query_md_feature_data() |
| 775 | * |
| 776 | * DESCRIPTION |
| 777 | * This function is used to query modem configuration |
| 778 | * |
| 779 | * PARAMETERS |
| 780 | * feature [IN] modem feature |
| 781 | * |
| 782 | * RETURNS |
| 783 | * The byte value for the input feature |
| 784 | *****************************************************************************/ |
| 785 | extern kal_uint8 sbp_query_md_feature_data(sbp_md_feature_data_enum feature); |
| 786 | |
| 787 | /***************************************************************************** |
| 788 | * FUNCTION |
| 789 | * sbp_query_md_feature_data_for_c2k() |
| 790 | * |
| 791 | * DESCRIPTION |
| 792 | * This function is used to query modem configuration and used by C2K team only |
| 793 | * The function will judge current active PS using C2K's API and return the corresponding setting. |
| 794 | * |
| 795 | * PARAMETERS |
| 796 | * feature [IN] modem feature |
| 797 | * |
| 798 | * RETURNS |
| 799 | * the unsigned byte value for the feature |
| 800 | *****************************************************************************/ |
| 801 | extern kal_uint8 sbp_query_md_feature_data_for_c2k(sbp_md_feature_data_enum feature); |
| 802 | |
| 803 | /***************************************************************************** |
| 804 | * FUNCTION |
| 805 | * sbp_query_md_feature_data_by_ps() |
| 806 | * |
| 807 | * DESCRIPTION |
| 808 | * This function is used to query modem configuration data |
| 809 | * |
| 810 | * PARAMETERS |
| 811 | * feature [IN] modem feature |
| 812 | * ps_id [IN] PS ID |
| 813 | * |
| 814 | * RETURNS |
| 815 | * the unsigned byte value for the feature |
| 816 | *****************************************************************************/ |
| 817 | extern kal_uint8 sbp_query_md_feature_data_by_ps(sbp_md_feature_data_enum feature, protocol_id_enum ps_id); |
| 818 | |
| 819 | /***************************************************************************** |
| 820 | * FUNCTION |
| 821 | * sbp_query_md_feature_data_no_overwrite() |
| 822 | * |
| 823 | * DESCRIPTION |
| 824 | * This function is used to query modem configuration without overwrite |
| 825 | * |
| 826 | * PARAMETERS |
| 827 | * feature [IN] modem feature |
| 828 | * |
| 829 | * RETURNS |
| 830 | * The byte value for the input feature |
| 831 | *****************************************************************************/ |
| 832 | extern kal_uint8 sbp_query_md_feature_data_no_overwrite(sbp_md_feature_data_enum feature); |
| 833 | |
| 834 | /***************************************************************************** |
| 835 | * FUNCTION |
| 836 | * sbp_query_md_feature_data_no_overwrite_by_ps() |
| 837 | * |
| 838 | * DESCRIPTION |
| 839 | * This function is used to query modem configuration data without overwrite |
| 840 | * |
| 841 | * PARAMETERS |
| 842 | * feature [IN] modem feature |
| 843 | * ps_id [IN] PS ID |
| 844 | * |
| 845 | * RETURNS |
| 846 | * the unsigned byte value for the feature |
| 847 | *****************************************************************************/ |
| 848 | extern kal_uint8 sbp_query_md_feature_data_no_overwrite_by_ps(sbp_md_feature_data_enum feature, protocol_id_enum ps_id); |
| 849 | |
| 850 | /***************************************************************************** |
| 851 | * FUNCTION |
| 852 | * sbp_set_md_feature_data() |
| 853 | * |
| 854 | * DESCRIPTION |
| 855 | * This function is used to query modem configuration |
| 856 | * |
| 857 | * PARAMETERS |
| 858 | * feature [IN] modem feature |
| 859 | * data [IN] |
| 860 | * sbp_data_ptr [IN/OUT] |
| 861 | * |
| 862 | * RETURNS |
| 863 | * KAL_TRUE if success; otherwise KAL_FALSE |
| 864 | *****************************************************************************/ |
| 865 | extern kal_bool sbp_set_md_feature_data(sbp_md_feature_data_enum feature, |
| 866 | kal_uint8 data, |
| 867 | nvram_ef_sbp_modem_data_config_struct *sbp_data_ptr); |
| 868 | |
| 869 | /***************************************************************************** |
| 870 | * FUNCTION |
| 871 | * sbp_general_set_md_feature_data() |
| 872 | * |
| 873 | * DESCRIPTION |
| 874 | * This function is used to set modem configuration data |
| 875 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 876 | * |
| 877 | * PARAMETERS |
| 878 | * feature [IN] modem feature |
| 879 | * |
| 880 | * RETURNS |
| 881 | * the unsigned byte value for the feature |
| 882 | *****************************************************************************/ |
| 883 | extern kal_bool sbp_general_set_md_feature_data(sbp_md_feature_data_enum feature, kal_uint8 data); |
| 884 | |
| 885 | /***************************************************************************** |
| 886 | * FUNCTION |
| 887 | * custom_nvram_set_sbp_id |
| 888 | * DESCRIPTION |
| 889 | * Set SBP features and data according to SBP ID. |
| 890 | * PARAMETERS |
| 891 | * sbp_mode [IN] |
| 892 | * RETURNS |
| 893 | * KAL_TRUE : Set SBP ID successfully |
| 894 | * KAL_FALSE : Error happens when setting SBP ID |
| 895 | *****************************************************************************/ |
| 896 | extern kal_bool custom_nvram_set_sbp_id(kal_uint32 sbp_id, kal_bool is_in_dynamic_sbp, kal_uint8 *imsi, protocol_id_enum ps_id); |
| 897 | |
| 898 | /***************************************************************************** |
| 899 | * FUNCTION |
| 900 | * custom_nvram_init_sbp_id |
| 901 | * DESCRIPTION |
| 902 | * Set SBP features and data according to SBP ID and SIM SBP ID. |
| 903 | * PARAMETERS |
| 904 | * sbp_id [IN] |
| 905 | * RETURNS |
| 906 | * Void |
| 907 | *****************************************************************************/ |
| 908 | extern void custom_nvram_init_sbp_id(kal_uint32 sbp_id); |
| 909 | |
| 910 | |
| 911 | /***************************************************************************** |
| 912 | * FUNCTION |
| 913 | * sbp_get_sim_sbp_id_for_all() |
| 914 | * |
| 915 | * DESCRIPTION |
| 916 | * get SIM SBP ID which trigger DSBP for all modem (IMS/VoLTE + PS/L1) |
| 917 | * |
| 918 | * PARAMETERS |
| 919 | * ps_id [IN] protocol ID |
| 920 | * |
| 921 | * RETURNS |
| 922 | * the unsigned 4-byte value for the SIM SBP ID |
| 923 | * |
| 924 | *****************************************************************************/ |
| 925 | extern kal_uint32 sbp_get_sim_sbp_id_for_all(protocol_id_enum ps_id); |
| 926 | |
| 927 | /***************************************************************************** |
| 928 | * FUNCTION |
| 929 | * sbp_get_current_sim_sbp_id() |
| 930 | * |
| 931 | * DESCRIPTION |
| 932 | * get SIM SBP ID which trigger DSBP for IMS/VoLTE |
| 933 | * |
| 934 | * PARAMETERS |
| 935 | * ps_id [IN] protocol ID |
| 936 | * |
| 937 | * RETURNS |
| 938 | * the unsigned 4-byte value for the SIM SBP ID |
| 939 | * |
| 940 | *****************************************************************************/ |
| 941 | extern kal_uint32 sbp_get_current_sim_sbp_id(protocol_id_enum ps_id); |
| 942 | |
| 943 | |
| 944 | /***************************************************************************** |
| 945 | * FUNCTION |
| 946 | * sbp_get_sim_sbp_id() |
| 947 | * |
| 948 | * DESCRIPTION |
| 949 | * get SIM SBP ID which trigger DSBP for IMS/VoLTE |
| 950 | * |
| 951 | * PARAMETERS |
| 952 | * ps_id [IN] protocol ID |
| 953 | * |
| 954 | * RETURNS |
| 955 | * the unsigned 4-byte value for the SIM SBP ID |
| 956 | * |
| 957 | *****************************************************************************/ |
| 958 | extern kal_uint32 sbp_get_sim_sbp_id(protocol_id_enum ps_id); |
| 959 | |
| 960 | /***************************************************************************** |
| 961 | * FUNCTION |
| 962 | * sbp_set_sim_sbp_id_for_all() |
| 963 | * |
| 964 | * DESCRIPTION |
| 965 | * set SIM SBP ID which trigger DSBP for all modem (IMS/VoLTE + PS/L1) |
| 966 | * |
| 967 | * PARAMETERS |
| 968 | * ps_id [IN] protocol ID |
| 969 | * sim_sbp_id [IN] SIM SBP ID |
| 970 | * mcc [IN] MCC |
| 971 | * mnc [IN] MNC |
| 972 | * iccid [IN] ICCID |
| 973 | * |
| 974 | * RETURNS |
| 975 | * KAL_TRUE - success |
| 976 | * KAL_FALSE - failure |
| 977 | * |
| 978 | *****************************************************************************/ |
| 979 | extern kal_bool sbp_set_sim_sbp_id_for_all(protocol_id_enum ps_id, kal_uint32 sim_sbp_id, kal_uint8 *mcc, kal_uint8 *mnc, kal_uint8 *iccid); |
| 980 | |
| 981 | /***************************************************************************** |
| 982 | * FUNCTION |
| 983 | * sbp_set_current_sim_sbp_id() |
| 984 | * |
| 985 | * DESCRIPTION |
| 986 | * get SIM SBP ID which trigger DSBP for IMS/VoLTE |
| 987 | * |
| 988 | * PARAMETERS |
| 989 | * ps_id [IN] protocol ID |
| 990 | * sim_sbp_id [IN] SIM SBP ID |
| 991 | * |
| 992 | * RETURNS |
| 993 | * KAL_TRUE - success |
| 994 | * KAL_FALSE - failure |
| 995 | * |
| 996 | *****************************************************************************/ |
| 997 | extern kal_bool sbp_set_current_sim_sbp_id(protocol_id_enum ps_id, kal_uint32 sim_sbp_id); |
| 998 | |
| 999 | /***************************************************************************** |
| 1000 | * FUNCTION |
| 1001 | * sbp_set_sim_sbp_id() |
| 1002 | * |
| 1003 | * DESCRIPTION |
| 1004 | * set SIM SBP ID which trigger DSBP for IMS/VoLTE |
| 1005 | * |
| 1006 | * PARAMETERS |
| 1007 | * ps_id [IN] protocol ID |
| 1008 | * sim_sbp_id [IN] SIM SBP ID |
| 1009 | * |
| 1010 | * RETURNS |
| 1011 | * KAL_TRUE - success |
| 1012 | * KAL_FALSE - failure |
| 1013 | * |
| 1014 | *****************************************************************************/ |
| 1015 | extern kal_bool sbp_set_sim_sbp_id(protocol_id_enum ps_id, kal_uint32 sim_sbp_id, kal_uint8 *mcc, kal_uint8 *mnc, kal_uint8 *iccid); |
| 1016 | |
| 1017 | /***************************************************************************** |
| 1018 | * FUNCTION |
| 1019 | * sbp_convert_mcc_mnc_string_from_imsi |
| 1020 | * DESCRIPTION |
| 1021 | * get mcc, mnc from imsi with string format |
| 1022 | * PARAMETERS |
| 1023 | * imsi |
| 1024 | * RETURNS |
| 1025 | * KAL_TRUE |
| 1026 | *****************************************************************************/ |
| 1027 | kal_bool sbp_convert_mcc_mnc_string_from_imsi(kal_uint8* mcc_ptr, kal_uint32 mcc_size, kal_uint8 *mnc_ptr, kal_uint32 mnc_size, kal_uint8* imsi_ptr, kal_uint8 mnc_len); |
| 1028 | |
| 1029 | /***************************************************************************** |
| 1030 | * FUNCTION |
| 1031 | * sbp_get_sbp_feature_raw_config() |
| 1032 | * |
| 1033 | * DESCRIPTION |
| 1034 | * Get SBP Feature Raw Data according to the ps_id |
| 1035 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1036 | * |
| 1037 | * PARAMETERS |
| 1038 | * ps_id [IN] protocol ID |
| 1039 | * |
| 1040 | * RETURNS |
| 1041 | * KAL_TRUE - success |
| 1042 | * KAL_FALSE - failure |
| 1043 | * |
| 1044 | *****************************************************************************/ |
| 1045 | extern kal_bool sbp_get_sbp_feature_raw_config(protocol_id_enum ps_id, kal_uint8 *raw_config); |
| 1046 | |
| 1047 | /***************************************************************************** |
| 1048 | * FUNCTION |
| 1049 | * sbp_set_sbp_feature_raw_config() |
| 1050 | * |
| 1051 | * DESCRIPTION |
| 1052 | * Set SBP Feature Raw Data according to the ps_id |
| 1053 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1054 | * |
| 1055 | * PARAMETERS |
| 1056 | * ps_id [IN] protocol ID |
| 1057 | * |
| 1058 | * RETURNS |
| 1059 | * KAL_TRUE - success |
| 1060 | * KAL_FALSE - failure |
| 1061 | * |
| 1062 | *****************************************************************************/ |
| 1063 | extern void sbp_set_sbp_feature_raw_config(protocol_id_enum ps_id, kal_uint8 *raw_config); |
| 1064 | |
| 1065 | |
| 1066 | /***************************************************************************** |
| 1067 | * FUNCTION |
| 1068 | * sbp_get_sbp_data_raw_config() |
| 1069 | * |
| 1070 | * DESCRIPTION |
| 1071 | * Get SBP Data Raw Data according to the ps_id |
| 1072 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1073 | * |
| 1074 | * PARAMETERS |
| 1075 | * ps_id [IN] protocol ID |
| 1076 | * |
| 1077 | * RETURNS |
| 1078 | * KAL_TRUE - success |
| 1079 | * KAL_FALSE - failure |
| 1080 | * |
| 1081 | *****************************************************************************/ |
| 1082 | extern kal_bool sbp_get_sbp_data_raw_config(protocol_id_enum ps_id, kal_uint8 *raw_config); |
| 1083 | |
| 1084 | /***************************************************************************** |
| 1085 | * FUNCTION |
| 1086 | * sbp_set_sbp_data_raw_config() |
| 1087 | * |
| 1088 | * DESCRIPTION |
| 1089 | * Get SBP Data Raw Data according to the ps_id |
| 1090 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1091 | * |
| 1092 | * PARAMETERS |
| 1093 | * ps_id [IN] protocol ID |
| 1094 | * |
| 1095 | * RETURNS |
| 1096 | * KAL_TRUE - success |
| 1097 | * KAL_FALSE - failure |
| 1098 | * |
| 1099 | *****************************************************************************/ |
| 1100 | extern void sbp_set_sbp_data_raw_config(protocol_id_enum ps_id, kal_uint8 *raw_config); |
| 1101 | |
| 1102 | |
| 1103 | /***************************************************************************** |
| 1104 | * FUNCTION |
| 1105 | * sbp_general_set_md_feature() |
| 1106 | * |
| 1107 | * DESCRIPTION |
| 1108 | * This function is used to set modem configuration. |
| 1109 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1110 | * |
| 1111 | * PARAMETERS |
| 1112 | * feature [IN] modem feature |
| 1113 | * is_turned_on [IN] |
| 1114 | * |
| 1115 | * RETURNS |
| 1116 | * KAL_TRUE if success; otherwise KAL_FALSE |
| 1117 | *****************************************************************************/ |
| 1118 | extern kal_bool sbp_general_set_md_feature(sbp_md_feature_enum feature, kal_bool is_turned_on); |
| 1119 | |
| 1120 | /***************************************************************************** |
| 1121 | * FUNCTION |
| 1122 | * sbp_update_features_to_nvram() |
| 1123 | * |
| 1124 | * DESCRIPTION |
| 1125 | * This function is used to store current config of features from SBP contexts into NVRAM_EF_SBP_MODEM_CONFIG_LID |
| 1126 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1127 | * |
| 1128 | * PARAMETERS |
| 1129 | * ps_id [IN] protocol ID |
| 1130 | * |
| 1131 | * RETURNS |
| 1132 | * KAL_TRUE - success |
| 1133 | * KAL_FALSE - failure |
| 1134 | * |
| 1135 | *****************************************************************************/ |
| 1136 | extern kal_bool sbp_update_features_to_nvram(); |
| 1137 | |
| 1138 | /***************************************************************************** |
| 1139 | * FUNCTION |
| 1140 | * sbp_update_data_to_nvram() |
| 1141 | * |
| 1142 | * DESCRIPTION |
| 1143 | * This function is used to store current config of data from SBP contexts into NVRAM_EF_SBP_MODEM_DATA_CONFIG_LID |
| 1144 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1145 | * |
| 1146 | * PARAMETERS |
| 1147 | * ps_id [IN] protocol ID |
| 1148 | * |
| 1149 | * RETURNS |
| 1150 | * KAL_TRUE - success |
| 1151 | * KAL_FALSE - failure |
| 1152 | * |
| 1153 | *****************************************************************************/ |
| 1154 | extern kal_bool sbp_update_data_to_nvram(); |
| 1155 | |
| 1156 | /***************************************************************************** |
| 1157 | * FUNCTION |
| 1158 | * sbp_update_specific_feature_to_nvram() |
| 1159 | * |
| 1160 | * DESCRIPTION |
| 1161 | * This function is used to write a single SBP feature to NVRAM, keeping all other features the same |
| 1162 | * |
| 1163 | * PARAMETERS |
| 1164 | * feature [IN] modem feature |
| 1165 | * is_turned_on [IN] |
| 1166 | * |
| 1167 | * RETURNS |
| 1168 | * KAL_TRUE - success |
| 1169 | * KAL_FALSE - failure |
| 1170 | * |
| 1171 | *****************************************************************************/ |
| 1172 | kal_bool sbp_update_specific_feature_to_nvram(sbp_md_feature_enum feature, kal_bool is_turned_on); |
| 1173 | |
| 1174 | /***************************************************************************** |
| 1175 | * FUNCTION |
| 1176 | * sbp_update_specific_data_to_nvram() |
| 1177 | * |
| 1178 | * DESCRIPTION |
| 1179 | * This function is used to write a single SBP feature data to NVRAM, keeping all other feature data the same |
| 1180 | * |
| 1181 | * PARAMETERS |
| 1182 | * feature [IN] modem feature data |
| 1183 | * data [IN] value of feature data |
| 1184 | * |
| 1185 | * RETURNS |
| 1186 | * KAL_TRUE - success |
| 1187 | * KAL_FALSE - failure |
| 1188 | * |
| 1189 | *****************************************************************************/ |
| 1190 | kal_bool sbp_update_specific_data_to_nvram(sbp_md_feature_data_enum feature, kal_uint8 data); |
| 1191 | |
| 1192 | /***************************************************************************** |
| 1193 | * FUNCTION |
| 1194 | * sbp_init_contexts() |
| 1195 | * |
| 1196 | * DESCRIPTION |
| 1197 | * This function is used to init SBP Contexts |
| 1198 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1199 | * |
| 1200 | * PARAMETERS |
| 1201 | * [IN] N/A |
| 1202 | * |
| 1203 | * RETURNS |
| 1204 | * KAL_TRUE or KAL_FALSE |
| 1205 | *****************************************************************************/ |
| 1206 | extern kal_bool sbp_init_contexts(); |
| 1207 | |
| 1208 | /***************************************************************************** |
| 1209 | * FUNCTION |
| 1210 | * sbp_get_dsbp_mode |
| 1211 | * |
| 1212 | * DESCRIPTION |
| 1213 | * query dynamic SBP mode |
| 1214 | * |
| 1215 | * PARAMETERS |
| 1216 | * [IN] N/A |
| 1217 | * RETURNS |
| 1218 | * current DSBP mode : l4bsbp_dsbp_mode_enum |
| 1219 | *****************************************************************************/ |
| 1220 | extern kal_uint8 sbp_get_dsbp_mode(void); |
| 1221 | |
| 1222 | /***************************************************************************** |
| 1223 | * FUNCTION |
| 1224 | * sbp_set_dsbp_mode |
| 1225 | * |
| 1226 | * DESCRIPTION |
| 1227 | * Set dynamic SBP mode. |
| 1228 | * |
| 1229 | * PARAMETERS |
| 1230 | * dsbp_mdoe [IN] l4bsbp_dsbp_mode_enum |
| 1231 | * RETURNS |
| 1232 | * KAL_TRUE : success |
| 1233 | * KAL_FALSE : fail |
| 1234 | *****************************************************************************/ |
| 1235 | extern kal_bool sbp_set_dsbp_mode(kal_uint8 dspb_mode); |
| 1236 | |
| 1237 | /***************************************************************************** |
| 1238 | * FUNCTION |
| 1239 | * sbp_get_test_mode |
| 1240 | * |
| 1241 | * DESCRIPTION |
| 1242 | * query if it is under test mode or not |
| 1243 | * |
| 1244 | * PARAMETERS |
| 1245 | * [IN] N/A |
| 1246 | * RETURNS |
| 1247 | * current SBP test mode : sbp_test_mode_enum |
| 1248 | *****************************************************************************/ |
| 1249 | extern sbp_test_mode_enum sbp_get_test_mode(void); |
| 1250 | |
| 1251 | /***************************************************************************** |
| 1252 | * FUNCTION |
| 1253 | * sbp_set_test_mode |
| 1254 | * |
| 1255 | * DESCRIPTION |
| 1256 | * Set SBP to test mode. |
| 1257 | * In test mode, we read current values of nvram files instead of using default values before applying SBP settings. |
| 1258 | * |
| 1259 | * PARAMETERS |
| 1260 | * test_mdoe [IN] sbp_test_mode_enum |
| 1261 | * RETURNS |
| 1262 | * KAL_TRUE : success |
| 1263 | * KAL_FALSE : fail |
| 1264 | *****************************************************************************/ |
| 1265 | extern kal_bool sbp_set_test_mode(sbp_test_mode_enum test_mode); |
| 1266 | |
| 1267 | /***************************************************************************** |
| 1268 | * FUNCTION |
| 1269 | * sbp_set_md_feature_by_ps() |
| 1270 | * |
| 1271 | * DESCRIPTION |
| 1272 | * This function is used to set modem configuration by PS |
| 1273 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1274 | * |
| 1275 | * PARAMETERS |
| 1276 | * feature [IN] modem feature |
| 1277 | * is_turned_on [IN] |
| 1278 | * sbp_feature_ptr [IN/OUT] |
| 1279 | * |
| 1280 | * RETURNS |
| 1281 | * KAL_TRUE if success; otherwise KAL_FALSE |
| 1282 | *****************************************************************************/ |
| 1283 | kal_bool sbp_set_md_feature_by_ps(sbp_md_feature_enum feature, |
| 1284 | kal_bool is_turned_on, |
| 1285 | protocol_id_enum ps_id); |
| 1286 | |
| 1287 | /***************************************************************************** |
| 1288 | * FUNCTION |
| 1289 | * sbp_set_md_feature_data_by_ps() |
| 1290 | * |
| 1291 | * DESCRIPTION |
| 1292 | * This function is used to set modem configuration data by PS |
| 1293 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1294 | * |
| 1295 | * PARAMETERS |
| 1296 | * feature [IN] modem feature |
| 1297 | * |
| 1298 | * RETURNS |
| 1299 | * the unsigned byte value for the feature |
| 1300 | *****************************************************************************/ |
| 1301 | kal_bool sbp_set_md_feature_data_by_ps(sbp_md_feature_data_enum feature, |
| 1302 | kal_uint8 data, |
| 1303 | protocol_id_enum ps_id); |
| 1304 | |
| 1305 | /***************************************************************************** |
| 1306 | * FUNCTION |
| 1307 | * sbp_set_sbp_id() |
| 1308 | * |
| 1309 | * DESCRIPTION |
| 1310 | * This function is used to set SBP ID into SBP contexts and its NVRAM |
| 1311 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1312 | * |
| 1313 | * PARAMETERS |
| 1314 | * [IN] N/A |
| 1315 | * |
| 1316 | * RETURNS |
| 1317 | * KAL_TRUE or KAL_FALSE |
| 1318 | *****************************************************************************/ |
| 1319 | extern kal_bool sbp_set_sbp_id(kal_uint32 sbp_id); |
| 1320 | |
| 1321 | /***************************************************************************** |
| 1322 | * FUNCTION |
| 1323 | * sbp_md_feature_overwrite() |
| 1324 | * |
| 1325 | * DESCRIPTION |
| 1326 | * This function is used to overwrite the configuration for GCF or other test modes |
| 1327 | * |
| 1328 | * PARAMETERS |
| 1329 | * feature [IN] modem feature |
| 1330 | * enabled [IN] feature is turned on or not |
| 1331 | * |
| 1332 | * RETURNS |
| 1333 | * KAL_TRUE : if this feature is turned on |
| 1334 | * KAL_FALSE : if this feature is turned off |
| 1335 | *****************************************************************************/ |
| 1336 | extern kal_bool sbp_md_feature_overwrite(sbp_md_feature_enum feature, kal_bool enabled); |
| 1337 | |
| 1338 | /***************************************************************************** |
| 1339 | * FUNCTION |
| 1340 | * sbp_md_feature_data_overwrite() |
| 1341 | * |
| 1342 | * DESCRIPTION |
| 1343 | * This function is used to overwrite the configuration for GCF or other test modes |
| 1344 | * |
| 1345 | * PARAMETERS |
| 1346 | * feature [IN] modem feature |
| 1347 | * value [IN] the value of the feature |
| 1348 | * |
| 1349 | * RETURNS |
| 1350 | * the overwrited value for the feature |
| 1351 | *****************************************************************************/ |
| 1352 | extern kal_uint8 sbp_md_feature_data_overwrite(sbp_md_feature_data_enum feature, kal_uint8 value); |
| 1353 | |
| 1354 | /***************************************************************************** |
| 1355 | * FUNCTION |
| 1356 | * sbp_reload_config() |
| 1357 | * |
| 1358 | * DESCRIPTION |
| 1359 | * This function is used to reload SBP related feature/data configuration |
| 1360 | * Please don't use this API if you don't get the permission from SBP FPM. |
| 1361 | * |
| 1362 | * PARAMETERS |
| 1363 | * ps_id [IN] protocol ID |
| 1364 | * |
| 1365 | * RETURNS |
| 1366 | * KAL_TRUE - success |
| 1367 | * KAL_FALSE - failure |
| 1368 | * |
| 1369 | *****************************************************************************/ |
| 1370 | void sbp_reload_config(); |
| 1371 | |
| 1372 | |
| 1373 | /***************************************************************************** |
| 1374 | * FUNCTION |
| 1375 | * nvram_custom_config_sbp_by_model_id |
| 1376 | * DESCRIPTION |
| 1377 | * Set SBP features and data according to Model ID. |
| 1378 | * PARAMETERS |
| 1379 | * md_product_model_id [IN] |
| 1380 | * RETURNS |
| 1381 | * KAL_TRUE : Set SBP ID successfully |
| 1382 | * KAL_FALSE : Error happens when setting SBP ID |
| 1383 | *****************************************************************************/ |
| 1384 | extern kal_bool nvram_custom_config_sbp_by_model_id(kal_uint32 md_product_model_id); |
| 1385 | |
| 1386 | /***************************************************************************** |
| 1387 | * FUNCTION |
| 1388 | * sbp_update_custom_config_to_nvram |
| 1389 | * |
| 1390 | * DESCRIPTION |
| 1391 | * This function updates sbp feature/data custom config to nvram |
| 1392 | * |
| 1393 | * |
| 1394 | * PARAMETERS |
| 1395 | * ps_id [IN] protocol ID |
| 1396 | * is_erase [IN] reset the feature/data item or not |
| 1397 | * RETURNS |
| 1398 | * void |
| 1399 | * |
| 1400 | *****************************************************************************/ |
| 1401 | kal_bool sbp_update_custom_config_to_nvram(sbp_custom_config_struct *sbp_custom_config_ptr, kal_bool is_erase); |
| 1402 | |
| 1403 | /***************************************************************************** |
| 1404 | * FUNCTION |
| 1405 | * sbp_get_custom_config_nv_with_mcf |
| 1406 | * |
| 1407 | * DESCRIPTION |
| 1408 | * This function reads NVRAM_EF_SBP_CUSTOM_MODEM_CONFIG_LID and applies MCF OTA by OP change |
| 1409 | * |
| 1410 | * PARAMETERS |
| 1411 | * ps_id [IN] protocol ID |
| 1412 | * |
| 1413 | * RETURNS |
| 1414 | * void |
| 1415 | * |
| 1416 | *****************************************************************************/ |
| 1417 | kal_bool sbp_get_custom_config_nv_with_mcf(protocol_id_enum ps_id, nvram_ef_sbp_custom_modem_config_struct * sbp_custom_modem_config_nv_ptr); |
| 1418 | |
| 1419 | /***************************************************************************** |
| 1420 | * FUNCTION |
| 1421 | * sbp_get_max_custom_config |
| 1422 | * |
| 1423 | * DESCRIPTION |
| 1424 | * This function gets MAX custom config NV entries |
| 1425 | * |
| 1426 | * PARAMETERS |
| 1427 | * [IN] N/A |
| 1428 | * RETURNS |
| 1429 | * void |
| 1430 | * |
| 1431 | *****************************************************************************/ |
| 1432 | kal_uint16 sbp_get_max_custom_config(void); |
| 1433 | |
| 1434 | /***************************************************************************** |
| 1435 | * FUNCTION |
| 1436 | * sbp_get_last_dsbp_sim_info() |
| 1437 | * |
| 1438 | * DESCRIPTION |
| 1439 | * This function is used to get MCC/MNC/ICCID of last completed DSBP |
| 1440 | * For mode2 device, this will include SIM info from last power up |
| 1441 | * For mode1 device, only include SIM info in current sbp context |
| 1442 | * |
| 1443 | * PARAMETERS |
| 1444 | * ps_id [IN] protocol ID |
| 1445 | * param [IN] mcc, mnc, iccid |
| 1446 | * RETURNS |
| 1447 | * void |
| 1448 | * |
| 1449 | *****************************************************************************/ |
| 1450 | extern void sbp_get_last_dsbp_sim_info(protocol_id_enum ps_id, kal_uint8 *mcc, kal_uint8 *mnc, kal_uint8 *iccid); |
| 1451 | |
| 1452 | /***************************************************************************** |
| 1453 | * FUNCTION |
| 1454 | * sbp_get_last_mode2_dsbp_sim_info() |
| 1455 | * |
| 1456 | * DESCRIPTION |
| 1457 | * This function is used to get SIM_SBP_ID/MCC/MNC/ICCID of last completed mode2 DSBP |
| 1458 | * Can be used in DSBP callback function to compare with last mode2 DSBP result |
| 1459 | * As part of mode2 design, this includes info from SIM insert of last power cycle |
| 1460 | * |
| 1461 | * PARAMETERS |
| 1462 | * ps_id [IN] protocol ID |
| 1463 | * param [IN] sim_sbp_id, mcc, mnc, iccid |
| 1464 | * RETURNS |
| 1465 | * void |
| 1466 | * |
| 1467 | *****************************************************************************/ |
| 1468 | extern void sbp_get_last_mode2_dsbp_sim_info(protocol_id_enum ps_id, kal_uint32 *sim_sbp_id, kal_uint8 *mcc, kal_uint8 *mnc, kal_uint8 *iccid); |
| 1469 | |
| 1470 | /***************************************************************************** |
| 1471 | * FUNCTION |
| 1472 | * sbp_get_dsbp_config() |
| 1473 | * |
| 1474 | * DESCRIPTION |
| 1475 | * This function is used to get dsbp retry config |
| 1476 | * |
| 1477 | * PARAMETERS |
| 1478 | * void |
| 1479 | * RETURNS |
| 1480 | * nvram_ef_sbp_dsbp_config_struct |
| 1481 | * |
| 1482 | *****************************************************************************/ |
| 1483 | extern nvram_ef_sbp_dsbp_config_struct* sbp_get_dsbp_config(void); |
| 1484 | /***************************************************************************** |
| 1485 | * FUNCTION |
| 1486 | * nvram_custom_config_refresh_sbp_id_mapping_when_mcf_ota_start() |
| 1487 | * |
| 1488 | * DESCRIPTION |
| 1489 | * This function is used to re-read NVRAM and update the globle custom sbp_id mapping table |
| 1490 | * when MCF default OTA triggered. |
| 1491 | * |
| 1492 | * PARAMETERS |
| 1493 | * void |
| 1494 | * RETURNS |
| 1495 | * void |
| 1496 | * |
| 1497 | *****************************************************************************/ |
| 1498 | extern void nvram_custom_config_refresh_sbp_id_mapping_when_mcf_ota_start(void); |
| 1499 | |
| 1500 | /***************************************************************************** |
| 1501 | * FUNCTION |
| 1502 | * sbp_get_custom_sbp_id_mapping_table |
| 1503 | * |
| 1504 | * DESCRIPTION |
| 1505 | * This function is used to get the globle custom sbp_id mapping table |
| 1506 | * |
| 1507 | * PARAMETERS |
| 1508 | * void |
| 1509 | * RETURNS |
| 1510 | * nvram_ef_sbp_custom_sbp_id_mapping_struct |
| 1511 | * |
| 1512 | *****************************************************************************/ |
| 1513 | extern nvram_ef_sbp_custom_sbp_id_mapping_struct* sbp_get_custom_sbp_id_mapping_table(void); |
| 1514 | |
| 1515 | /***************************************************************************** |
| 1516 | * FUNCTION |
| 1517 | * sbp_get_md_cxp_sbp_id |
| 1518 | * |
| 1519 | * DESCRIPTION |
| 1520 | * This function is used to get trigger modem CXP (device) sbp_id |
| 1521 | * |
| 1522 | * PARAMETERS |
| 1523 | * kal_uint32 sim_sbp_id |
| 1524 | * RETURNS |
| 1525 | * kal_uint32 md_cxp_sbp_id |
| 1526 | * |
| 1527 | *****************************************************************************/ |
| 1528 | extern kal_uint32 sbp_get_md_cxp_sbp_id(kal_uint32 sim_sbp_id); |
| 1529 | |
| 1530 | /***************************************************************************** |
| 1531 | * FUNCTION |
| 1532 | * sbp_set_md_cxp_sbp_id |
| 1533 | * |
| 1534 | * DESCRIPTION |
| 1535 | * This function is used to add trigger modem CXP (device) sbp_id |
| 1536 | * |
| 1537 | * PARAMETERS |
| 1538 | * kal_uint32 sbp_id |
| 1539 | * RETURNS |
| 1540 | * |
| 1541 | *****************************************************************************/ |
| 1542 | extern void sbp_set_md_cxp_sbp_id(kal_uint32 sbp_id); |
| 1543 | |
| 1544 | #if defined (__TC01_NVRAM__) || defined(__TC01__) // __TC01_CUST_SBP__ |
| 1545 | /***************************************************************************** |
| 1546 | * FUNCTION |
| 1547 | * sbp_query_md_feature_custom() |
| 1548 | * |
| 1549 | * DESCRIPTION |
| 1550 | * clone sbp_query_md_feature() for customer's SBP. |
| 1551 | * |
| 1552 | * PARAMETERS |
| 1553 | * feature [IN] customer's modem feature |
| 1554 | * |
| 1555 | * RETURNS |
| 1556 | * KAL_TRUE : if this feature is turned on |
| 1557 | * KAL_FALSE : if this feature is turned off |
| 1558 | *****************************************************************************/ |
| 1559 | extern kal_bool sbp_query_md_feature_custom(sbp_md_feature_custom_enum feature); |
| 1560 | |
| 1561 | /***************************************************************************** |
| 1562 | * FUNCTION |
| 1563 | * sbp_query_md_feature_by_ps_custom() |
| 1564 | * |
| 1565 | * DESCRIPTION |
| 1566 | * clone sbp_query_md_feature_by_ps() for customer's SBP. |
| 1567 | * |
| 1568 | * PARAMETERS |
| 1569 | * feature [IN] customer's modem feature |
| 1570 | * ps_id [IN] PS ID |
| 1571 | * |
| 1572 | * RETURNS |
| 1573 | * KAL_TRUE : if this feature is turned on |
| 1574 | * KAL_FALSE : if this feature is turned off |
| 1575 | *****************************************************************************/ |
| 1576 | extern kal_bool sbp_query_md_feature_by_ps_custom(sbp_md_feature_custom_enum feature, protocol_id_enum ps_id); |
| 1577 | |
| 1578 | /***************************************************************************** |
| 1579 | * FUNCTION |
| 1580 | * sbp_set_md_feature_custom() |
| 1581 | * |
| 1582 | * DESCRIPTION |
| 1583 | * clone sbp_set_md_feature() for customer's SBP. |
| 1584 | * |
| 1585 | * PARAMETERS |
| 1586 | * feature [IN] customer's modem feature |
| 1587 | * is_turned_on [IN] |
| 1588 | * sbp_feature_ptr [IN/OUT] |
| 1589 | * |
| 1590 | * RETURNS |
| 1591 | * KAL_TRUE if success; otherwise KAL_FALSE |
| 1592 | *****************************************************************************/ |
| 1593 | extern kal_bool sbp_set_md_feature_custom(sbp_md_feature_custom_enum feature, |
| 1594 | kal_bool is_turned_on, |
| 1595 | nvram_ef_sbp_modem_config_struct *sbp_feature_ptr); |
| 1596 | |
| 1597 | /***************************************************************************** |
| 1598 | * FUNCTION |
| 1599 | * sbp_set_md_feature_by_ps_custom() |
| 1600 | * |
| 1601 | * DESCRIPTION |
| 1602 | * clone sbp_set_md_feature_by_ps() for customer's SBP. |
| 1603 | * |
| 1604 | * PARAMETERS |
| 1605 | * feature [IN] customer's modem feature |
| 1606 | * is_turned_on [IN] |
| 1607 | * sbp_feature_ptr [IN/OUT] |
| 1608 | * |
| 1609 | * RETURNS |
| 1610 | * KAL_TRUE if success; otherwise KAL_FALSE |
| 1611 | *****************************************************************************/ |
| 1612 | extern kal_bool sbp_set_md_feature_by_ps_custom(sbp_md_feature_custom_enum feature, |
| 1613 | kal_bool is_turned_on, |
| 1614 | protocol_id_enum ps_id); |
| 1615 | |
| 1616 | /***************************************************************************** |
| 1617 | * FUNCTION |
| 1618 | * sbp_general_set_md_feature_custom() |
| 1619 | * |
| 1620 | * DESCRIPTION |
| 1621 | * clone sbp_general_set_md_feature() for customer's SBP. |
| 1622 | * |
| 1623 | * PARAMETERS |
| 1624 | * feature [IN] customer's modem feature |
| 1625 | * is_turned_on [IN] |
| 1626 | * |
| 1627 | * RETURNS |
| 1628 | * KAL_TRUE if success; otherwise KAL_FALSE |
| 1629 | *****************************************************************************/ |
| 1630 | extern kal_bool sbp_general_set_md_feature_custom(sbp_md_feature_custom_enum feature, kal_bool is_turned_on); |
| 1631 | |
| 1632 | /***************************************************************************** |
| 1633 | * FUNCTION |
| 1634 | * sbp_update_features_to_nvram_custom() |
| 1635 | * |
| 1636 | * DESCRIPTION |
| 1637 | * clone sbp_update_features_to_nvram() for customer's SBP. |
| 1638 | * |
| 1639 | * PARAMETERS |
| 1640 | * ps_id [IN] protocol ID |
| 1641 | * |
| 1642 | * RETURNS |
| 1643 | * KAL_TRUE - success |
| 1644 | * KAL_FALSE - failure |
| 1645 | * |
| 1646 | *****************************************************************************/ |
| 1647 | extern kal_bool sbp_update_features_to_nvram_custom(); |
| 1648 | |
| 1649 | |
| 1650 | /***************************************************************************** |
| 1651 | * FUNCTION |
| 1652 | * sbp_get_sbp_feature_raw_config_custom() |
| 1653 | * |
| 1654 | * DESCRIPTION |
| 1655 | * clone sbp_get_sbp_feature_raw_config() for customer's SBP. |
| 1656 | * |
| 1657 | * PARAMETERS |
| 1658 | * ps_id [IN] protocol ID |
| 1659 | * |
| 1660 | * RETURNS |
| 1661 | * KAL_TRUE - success |
| 1662 | * KAL_FALSE - failure |
| 1663 | * |
| 1664 | *****************************************************************************/ |
| 1665 | extern kal_bool sbp_get_sbp_feature_raw_config_custom(protocol_id_enum ps_id, kal_uint8 *raw_config); |
| 1666 | |
| 1667 | /***************************************************************************** |
| 1668 | * FUNCTION |
| 1669 | * sbp_set_sbp_feature_raw_config_custom() |
| 1670 | * |
| 1671 | * DESCRIPTION |
| 1672 | * clone sbp_set_sbp_feature_raw_config() for customer's SBP. |
| 1673 | * |
| 1674 | * PARAMETERS |
| 1675 | * ps_id [IN] protocol ID |
| 1676 | * |
| 1677 | * RETURNS |
| 1678 | * KAL_TRUE - success |
| 1679 | * KAL_FALSE - failure |
| 1680 | * |
| 1681 | *****************************************************************************/ |
| 1682 | extern void sbp_set_sbp_feature_raw_config_custom(protocol_id_enum ps_id, kal_uint8 *raw_config); |
| 1683 | #endif /* (__TC01_NVRAM__) || defined(__TC01__) */ |
| 1684 | |
| 1685 | #ifdef __IPC_ADAPTER__ |
| 1686 | /***************************************************************************** |
| 1687 | * FUNCTION |
| 1688 | * sbp_get_salecode() |
| 1689 | * |
| 1690 | * DESCRIPTION |
| 1691 | * This function is used to get salecode of this ps_id |
| 1692 | * If network code is present, network code is given |
| 1693 | * otherwise, csc_salecode is given |
| 1694 | * |
| 1695 | * PARAMETERS |
| 1696 | * ps_id [IN] protocol ID |
| 1697 | * param [IN] salecode |
| 1698 | * RETURNS |
| 1699 | * void |
| 1700 | * |
| 1701 | *****************************************************************************/ |
| 1702 | extern void sbp_get_salecode(kal_char *salecode, protocol_id_enum ps_id); |
| 1703 | extern void sbp_get_csc_salecode(kal_char *salecode); |
| 1704 | extern void sbp_get_network_code_salecode(kal_char *salecode, protocol_id_enum ps_id); |
| 1705 | #endif /* __IPC_ADAPTER__ */ |
| 1706 | |
| 1707 | #ifdef __cplusplus |
| 1708 | } |
| 1709 | #endif |
| 1710 | |
| 1711 | #endif /* _SBP_PUBLIC_UTILITY_H */ |
| 1712 | |