|
@@ -145,8 +145,9 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
@@ -145,8 +145,9 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
145
|
switch (spStage)
|
145
|
switch (spStage)
|
|
146
|
{
|
146
|
{
|
|
147
|
case SP_START_STAGE:
|
147
|
case SP_START_STAGE:
|
|
148
|
- if ((m_bWriteModemNvram || (bCheckCalFlag || bCheckFtFlag)) && mdNums >= 1)
|
148
|
+ if ((m_bWriteModemNvram ) && mdNums >= 1)
|
|
149
|
{
|
149
|
{
|
|
|
|
150
|
+ UpdateUIMsg("WriteNvramLoop SP_START_STAGE");
|
|
150
|
//Target in AP meta mode, need to switch Modem meta
|
151
|
//Target in AP meta mode, need to switch Modem meta
|
|
151
|
if (m_eMetaMode == SP_AP_META)
|
152
|
if (m_eMetaMode == SP_AP_META)
|
|
152
|
{
|
153
|
{
|
|
@@ -154,7 +155,7 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
@@ -154,7 +155,7 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
154
|
}
|
155
|
}
|
|
155
|
else //Target already in modem meta mode
|
156
|
else //Target already in modem meta mode
|
|
156
|
{
|
157
|
{
|
|
157
|
- spNextStage = SP_CHECK_CAL_FT_FLAG_STAGE;
|
158
|
+ spNextStage = SP_BARCODE_MD_STAGE;
|
|
158
|
}
|
159
|
}
|
|
159
|
}
|
160
|
}
|
|
160
|
else
|
161
|
else
|
|
@@ -164,11 +165,12 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
@@ -164,11 +165,12 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
164
|
break;
|
165
|
break;
|
|
165
|
|
166
|
|
|
166
|
case SP_AP2MD_STAGE:
|
167
|
case SP_AP2MD_STAGE:
|
|
|
|
168
|
+ UpdateUIMsg("WriteNvramLoop SP_AP2MD_STAGE");
|
|
167
|
fBeginProcess += fStep;
|
169
|
fBeginProcess += fStep;
|
|
168
|
iRet = APSwithToModemMeta_Ex();
|
170
|
iRet = APSwithToModemMeta_Ex();
|
|
169
|
if (iRet == META_SUCCESS)
|
171
|
if (iRet == META_SUCCESS)
|
|
170
|
{
|
172
|
{
|
|
171
|
- spNextStage = SP_CHECK_CAL_FT_FLAG_STAGE;
|
173
|
+ spNextStage = SP_BARCODE_MD_STAGE;
|
|
172
|
}
|
174
|
}
|
|
173
|
else
|
175
|
else
|
|
174
|
{
|
176
|
{
|
|
@@ -177,33 +179,34 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
@@ -177,33 +179,34 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
177
|
}
|
179
|
}
|
|
178
|
break;
|
180
|
break;
|
|
179
|
|
181
|
|
|
180
|
- case SP_CHECK_CAL_FT_FLAG_STAGE:
|
|
|
|
181
|
- {
|
|
|
|
182
|
- char tmpBuf[2048] = {0};
|
|
|
|
183
|
- iRet = REQ_ReadModem_NVRAM_Start(WRITE_BARCODE, tmpBuf, 1);
|
|
|
|
184
|
- if (iRet == META_SUCCESS)
|
|
|
|
185
|
- {
|
|
|
|
186
|
- bool bCheckPass = true;
|
|
|
|
187
|
- bCheckPass = CheckCalFinalTestStatus(tmpBuf);
|
|
|
|
188
|
- if (bCheckPass == true)
|
|
|
|
189
|
- {
|
|
|
|
190
|
- spNextStage = SP_BARCODE_MD_STAGE;
|
|
|
|
191
|
- }
|
|
|
|
192
|
- else
|
|
|
|
193
|
- {
|
|
|
|
194
|
- iRet = META_FAILED;
|
|
|
|
195
|
- spNextStage = SP_END_STAGE;
|
|
|
|
196
|
- }
|
|
|
|
197
|
- }
|
|
|
|
198
|
- else
|
|
|
|
199
|
- {
|
|
|
|
200
|
- UpdateUIMsg("ERROR!! Read Barcode: MetaResult = %s", ResultToString(iRet));
|
|
|
|
201
|
- spNextStage = SP_END_STAGE;
|
|
|
|
202
|
- }
|
|
|
|
203
|
- }
|
|
|
|
204
|
- break;
|
182
|
+// case SP_CHECK_CAL_FT_FLAG_STAGE:
|
|
|
|
183
|
+// {
|
|
|
|
184
|
+// char tmpBuf[2048] = {0};
|
|
|
|
185
|
+// iRet = REQ_ReadModem_NVRAM_Start(WRITE_BARCODE, tmpBuf, 1);
|
|
|
|
186
|
+// if (iRet == META_SUCCESS)
|
|
|
|
187
|
+// {
|
|
|
|
188
|
+// bool bCheckPass = true;
|
|
|
|
189
|
+// bCheckPass = CheckCalFinalTestStatus(tmpBuf);
|
|
|
|
190
|
+// if (bCheckPass == true)
|
|
|
|
191
|
+// {
|
|
|
|
192
|
+// spNextStage = SP_BARCODE_MD_STAGE;
|
|
|
|
193
|
+// }
|
|
|
|
194
|
+// else
|
|
|
|
195
|
+// {
|
|
|
|
196
|
+// iRet = META_FAILED;
|
|
|
|
197
|
+// spNextStage = SP_END_STAGE;
|
|
|
|
198
|
+// }
|
|
|
|
199
|
+// }
|
|
|
|
200
|
+// else
|
|
|
|
201
|
+// {
|
|
|
|
202
|
+// UpdateUIMsg("ERROR!! Read Barcode: MetaResult = %s", ResultToString(iRet));
|
|
|
|
203
|
+// spNextStage = SP_END_STAGE;
|
|
|
|
204
|
+// }
|
|
|
|
205
|
+// }
|
|
|
|
206
|
+// break;
|
|
205
|
|
207
|
|
|
206
|
case SP_BARCODE_MD_STAGE:
|
208
|
case SP_BARCODE_MD_STAGE:
|
|
|
|
209
|
+ UpdateUIMsg("WriteNvramLoop SP_BARCODE_MD_STAGE");
|
|
207
|
if (g_sMetaComm.sWriteOption.bWriteIMEI)
|
210
|
if (g_sMetaComm.sWriteOption.bWriteIMEI)
|
|
208
|
{
|
211
|
{
|
|
209
|
if (mdNums == 1 && g_sMetaComm.sIMEIOption.iImeiNums == 1)
|
212
|
if (mdNums == 1 && g_sMetaComm.sIMEIOption.iImeiNums == 1)
|
|
@@ -239,6 +242,7 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
@@ -239,6 +242,7 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
239
|
break;
|
242
|
break;
|
|
240
|
|
243
|
|
|
241
|
case SP_IMEI_MD_STAGE:
|
244
|
case SP_IMEI_MD_STAGE:
|
|
|
|
245
|
+ UpdateUIMsg("WriteNvramLoop SP_IMEI_MD_STAGE");
|
|
242
|
|
246
|
|
|
243
|
bWriteModemFail = false;
|
247
|
bWriteModemFail = false;
|
|
244
|
for (MDIndex = 0; MDIndex < mdNums && bWriteModemFail == false; MDIndex++)
|
248
|
for (MDIndex = 0; MDIndex < mdNums && bWriteModemFail == false; MDIndex++)
|
|
@@ -268,10 +272,11 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
@@ -268,10 +272,11 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
268
|
}
|
272
|
}
|
|
269
|
}
|
273
|
}
|
|
270
|
|
274
|
|
|
271
|
- if (g_sMetaComm.sWriteOption.bWriteBarcode && (MDIndex == 0 || (mdNums >= 2 && MDIndex >= 1 && m_iC2kProject == 0)))
|
275
|
+ if (MDIndex == 0 || (mdNums >= 2 && MDIndex >= 1 && m_iC2kProject == 0))
|
|
272
|
{
|
276
|
{
|
|
273
|
fBeginProcess += fStep;
|
277
|
fBeginProcess += fStep;
|
|
274
|
MTRACE(g_hEBOOT_DEBUG, "Barcode[%d] = \"%s\"", MDIndex, m_sScanData.strBarcode);
|
278
|
MTRACE(g_hEBOOT_DEBUG, "Barcode[%d] = \"%s\"", MDIndex, m_sScanData.strBarcode);
|
|
|
|
279
|
+ UpdateUIMsg("WriteNvramLoop REQ_WriteModem_NVRAM_Start WRITE_BARCODE");
|
|
275
|
iRet = REQ_WriteModem_NVRAM_Start(WRITE_BARCODE, m_sScanData.strBarcode, 1);
|
280
|
iRet = REQ_WriteModem_NVRAM_Start(WRITE_BARCODE, m_sScanData.strBarcode, 1);
|
|
276
|
if (iRet != META_SUCCESS)
|
281
|
if (iRet != META_SUCCESS)
|
|
277
|
{
|
282
|
{
|
|
@@ -281,7 +286,7 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
@@ -281,7 +286,7 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
281
|
}
|
286
|
}
|
|
282
|
}
|
287
|
}
|
|
283
|
|
288
|
|
|
284
|
- if (g_sMetaComm.sWriteOption.bWriteIMEI && (MDIndex == 0 || (mdNums >= 2 && MDIndex >= 1 && m_iC2kProject == 0)))
|
289
|
+ if (MDIndex == 0 || (mdNums >= 2 && MDIndex >= 1 && m_iC2kProject == 0))
|
|
285
|
{
|
290
|
{
|
|
286
|
if (multiIMEIOption == SINGLE_MD_SINGLE_IMEI || multiIMEIOption == SINGLE_MD_MULTI_IMEI)
|
291
|
if (multiIMEIOption == SINGLE_MD_SINGLE_IMEI || multiIMEIOption == SINGLE_MD_MULTI_IMEI)
|
|
287
|
{
|
292
|
{
|
|
@@ -291,6 +296,7 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
@@ -291,6 +296,7 @@ META_RESULT SmartPhoneSN::WriteNvramLoop() |
|
291
|
IMEI_index = i;
|
296
|
IMEI_index = i;
|
|
292
|
MTRACE(g_hEBOOT_DEBUG, "IMEI[%d] = \"%s\"", i, m_sScanData.strIMEI[i]);
|
297
|
MTRACE(g_hEBOOT_DEBUG, "IMEI[%d] = \"%s\"", i, m_sScanData.strIMEI[i]);
|
|
293
|
|
298
|
|
|
|
|
299
|
+ UpdateUIMsg("WriteNvramLoop REQ_WriteModem_NVRAM_Start WRITE_IMEI");
|
|
294
|
iRet = REQ_WriteModem_NVRAM_Start(WRITE_IMEI, m_sScanData.strIMEI[i], i + 1);
|
300
|
iRet = REQ_WriteModem_NVRAM_Start(WRITE_IMEI, m_sScanData.strIMEI[i], i + 1);
|
|
295
|
if (iRet != META_SUCCESS)
|
301
|
if (iRet != META_SUCCESS)
|
|
296
|
{
|
302
|
{
|
|
@@ -402,9 +408,12 @@ int SmartPhoneSN::GetSPModemInfo_Ex() |
|
@@ -402,9 +408,12 @@ int SmartPhoneSN::GetSPModemInfo_Ex() |
|
402
|
SPMETA_DLL::MODEM_QUERY_INFO_CNF pCnf;
|
408
|
SPMETA_DLL::MODEM_QUERY_INFO_CNF pCnf;
|
|
403
|
memset(&pReq, 0, sizeof(SPMETA_DLL::MODEM_QUERY_INFO_REQ));
|
409
|
memset(&pReq, 0, sizeof(SPMETA_DLL::MODEM_QUERY_INFO_REQ));
|
|
404
|
memset(&pCnf, 0, sizeof(SPMETA_DLL::MODEM_QUERY_INFO_CNF));
|
410
|
memset(&pCnf, 0, sizeof(SPMETA_DLL::MODEM_QUERY_INFO_CNF));
|
|
|
|
411
|
+ UpdateUIMsg("GetSPModemInfo_Ex");
|
|
405
|
|
412
|
|
|
|
|
413
|
+ UpdateUIMsg("SP_META_QueryIfFunctionSupportedByTarget_r");
|
|
406
|
if (SPMETA_DLL::SP_META_QueryIfFunctionSupportedByTarget_r(m_hSPMetaHandle, 5000, "SP_META_MODEM_Query_Info_r") == SPMETA_DLL::META_SUCCESS)
|
414
|
if (SPMETA_DLL::SP_META_QueryIfFunctionSupportedByTarget_r(m_hSPMetaHandle, 5000, "SP_META_MODEM_Query_Info_r") == SPMETA_DLL::META_SUCCESS)
|
|
407
|
{
|
415
|
{
|
|
|
|
416
|
+ UpdateUIMsg("SP_META_MODEM_Query_Info_r");
|
|
408
|
iRet = SPMETA_DLL::SP_META_MODEM_Query_Info_r(m_hSPMetaHandle, 10000, &pReq, &pCnf);
|
417
|
iRet = SPMETA_DLL::SP_META_MODEM_Query_Info_r(m_hSPMetaHandle, 10000, &pReq, &pCnf);
|
|
409
|
if (iRet != META_SUCCESS)
|
418
|
if (iRet != META_SUCCESS)
|
|
410
|
{
|
419
|
{
|
|
@@ -427,8 +436,10 @@ int SmartPhoneSN::GetSPModemInfo_Ex() |
|
@@ -427,8 +436,10 @@ int SmartPhoneSN::GetSPModemInfo_Ex() |
|
427
|
memset(&pCapabilitiesReq, 0, sizeof(pCapabilitiesReq));
|
436
|
memset(&pCapabilitiesReq, 0, sizeof(pCapabilitiesReq));
|
|
428
|
memset(&pCapabilitiesCnf, 0, sizeof(pCapabilitiesCnf));
|
437
|
memset(&pCapabilitiesCnf, 0, sizeof(pCapabilitiesCnf));
|
|
429
|
|
438
|
|
|
|
|
439
|
+ UpdateUIMsg("SP_META_QueryIfFunctionSupportedByTarget_r");
|
|
430
|
if (SPMETA_DLL::SP_META_QueryIfFunctionSupportedByTarget_r(m_hSPMetaHandle, 5000, "SP_META_MODEM_Capability_r") == SPMETA_DLL::META_SUCCESS)
|
440
|
if (SPMETA_DLL::SP_META_QueryIfFunctionSupportedByTarget_r(m_hSPMetaHandle, 5000, "SP_META_MODEM_Capability_r") == SPMETA_DLL::META_SUCCESS)
|
|
431
|
{
|
441
|
{
|
|
|
|
442
|
+ UpdateUIMsg("SP_META_MODEM_Capability_r");
|
|
432
|
iRet = SPMETA_DLL::SP_META_MODEM_Capability_r(m_hSPMetaHandle, 10000, &pCapabilitiesReq, &pCapabilitiesCnf);
|
443
|
iRet = SPMETA_DLL::SP_META_MODEM_Capability_r(m_hSPMetaHandle, 10000, &pCapabilitiesReq, &pCapabilitiesCnf);
|
|
433
|
if (iRet != META_SUCCESS)
|
444
|
if (iRet != META_SUCCESS)
|
|
434
|
{
|
445
|
{
|
|
@@ -481,8 +492,10 @@ int SmartPhoneSN::GetSPModemInfo_Ex() |
|
@@ -481,8 +492,10 @@ int SmartPhoneSN::GetSPModemInfo_Ex() |
|
481
|
memset(&pCurMDTypeReq, 0, sizeof(pCurMDTypeReq));
|
492
|
memset(&pCurMDTypeReq, 0, sizeof(pCurMDTypeReq));
|
|
482
|
memset(&pCurMDTypeCnf, 0, sizeof(pCurMDTypeCnf));
|
493
|
memset(&pCurMDTypeCnf, 0, sizeof(pCurMDTypeCnf));
|
|
483
|
|
494
|
|
|
|
|
495
|
+ UpdateUIMsg("SP_META_QueryIfFunctionSupportedByTarget_r");
|
|
484
|
if (SPMETA_DLL::SP_META_QueryIfFunctionSupportedByTarget_r(m_hSPMetaHandle, 5000, "SP_META_MODEM_Get_CurrentModemType_r") == SPMETA_DLL::META_SUCCESS)
|
496
|
if (SPMETA_DLL::SP_META_QueryIfFunctionSupportedByTarget_r(m_hSPMetaHandle, 5000, "SP_META_MODEM_Get_CurrentModemType_r") == SPMETA_DLL::META_SUCCESS)
|
|
485
|
{
|
497
|
{
|
|
|
|
498
|
+ UpdateUIMsg("SP_META_MODEM_Get_CurrentModemType_r");
|
|
486
|
iRet = SPMETA_DLL::SP_META_MODEM_Get_CurrentModemType_r(m_hSPMetaHandle, 10000, &pCurMDTypeReq, &pCurMDTypeCnf);
|
499
|
iRet = SPMETA_DLL::SP_META_MODEM_Get_CurrentModemType_r(m_hSPMetaHandle, 10000, &pCurMDTypeReq, &pCurMDTypeCnf);
|
|
487
|
if (iRet != META_SUCCESS)
|
500
|
if (iRet != META_SUCCESS)
|
|
488
|
{
|
501
|
{
|
|
@@ -502,8 +515,10 @@ int SmartPhoneSN::GetSPModemInfo_Ex() |
|
@@ -502,8 +515,10 @@ int SmartPhoneSN::GetSPModemInfo_Ex() |
|
502
|
memset(&pMDImgTypeReq, 0, sizeof(pMDImgTypeReq));
|
515
|
memset(&pMDImgTypeReq, 0, sizeof(pMDImgTypeReq));
|
|
503
|
memset(&pMDImgTypeCnf, 0, sizeof(pMDImgTypeCnf));
|
516
|
memset(&pMDImgTypeCnf, 0, sizeof(pMDImgTypeCnf));
|
|
504
|
|
517
|
|
|
|
|
518
|
+ UpdateUIMsg("SP_META_QueryIfFunctionSupportedByTarget_r");
|
|
505
|
if (SPMETA_DLL::SP_META_QueryIfFunctionSupportedByTarget_r(m_hSPMetaHandle, 5000, "SP_META_MODEM_Query_MDIMGType_r") == SPMETA_DLL::META_SUCCESS)
|
519
|
if (SPMETA_DLL::SP_META_QueryIfFunctionSupportedByTarget_r(m_hSPMetaHandle, 5000, "SP_META_MODEM_Query_MDIMGType_r") == SPMETA_DLL::META_SUCCESS)
|
|
506
|
{
|
520
|
{
|
|
|
|
521
|
+ UpdateUIMsg("SP_META_MODEM_Query_MDIMGType_r");
|
|
507
|
iRet = SPMETA_DLL::SP_META_MODEM_Query_MDIMGType_r(m_hSPMetaHandle, 10000, &pMDImgTypeReq, &pMDImgTypeCnf);
|
522
|
iRet = SPMETA_DLL::SP_META_MODEM_Query_MDIMGType_r(m_hSPMetaHandle, 10000, &pMDImgTypeReq, &pMDImgTypeCnf);
|
|
508
|
if (iRet != META_SUCCESS)
|
523
|
if (iRet != META_SUCCESS)
|
|
509
|
{
|
524
|
{
|
|
@@ -562,6 +577,7 @@ int SmartPhoneSN::GetSPModemInfo_Ex() |
|
@@ -562,6 +577,7 @@ int SmartPhoneSN::GetSPModemInfo_Ex() |
|
562
|
memset(&pDLReq, 0, sizeof(SPMETA_DLL::MODEM_QUERY_DOWNLOAD_STATUS_REQ));
|
577
|
memset(&pDLReq, 0, sizeof(SPMETA_DLL::MODEM_QUERY_DOWNLOAD_STATUS_REQ));
|
|
563
|
memset(&pDLCnf, 0, sizeof(SPMETA_DLL::MODEM_QUERY_DOWNLOAD_STATUS_CNF));
|
578
|
memset(&pDLCnf, 0, sizeof(SPMETA_DLL::MODEM_QUERY_DOWNLOAD_STATUS_CNF));
|
|
564
|
|
579
|
|
|
|
|
580
|
+ UpdateUIMsg("SP_META_MODEM_Query_Download_Status_r");
|
|
565
|
iRet = SPMETA_DLL::SP_META_MODEM_Query_Download_Status_r (m_hSPMetaHandle, 80000, &pDLReq, &pDLCnf);
|
581
|
iRet = SPMETA_DLL::SP_META_MODEM_Query_Download_Status_r (m_hSPMetaHandle, 80000, &pDLReq, &pDLCnf);
|
|
566
|
if (iRet != META_SUCCESS)
|
582
|
if (iRet != META_SUCCESS)
|
|
567
|
{
|
583
|
{
|
|
@@ -585,6 +601,7 @@ int SmartPhoneSN::TryToOpenSPKernelComport(int KernelCom_Num) |
|
@@ -585,6 +601,7 @@ int SmartPhoneSN::TryToOpenSPKernelComport(int KernelCom_Num) |
|
585
|
|
601
|
|
|
586
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::TryToOpenSPKernelComport(): Try to open kernel comport until it ready, KernelCom_Num = %d...", KernelCom_Num);
|
602
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::TryToOpenSPKernelComport(): Try to open kernel comport until it ready, KernelCom_Num = %d...", KernelCom_Num);
|
|
587
|
|
603
|
|
|
|
|
604
|
+ UpdateUIMsg("TryToOpenSPKernelComport");
|
|
588
|
sz_error = new char[1024];
|
605
|
sz_error = new char[1024];
|
|
589
|
memset(sz_error, 0, 1024);
|
606
|
memset(sz_error, 0, 1024);
|
|
590
|
sprintf(tmp_com, "\\\\.\\COM%d", KernelCom_Num);
|
607
|
sprintf(tmp_com, "\\\\.\\COM%d", KernelCom_Num);
|
|
@@ -630,6 +647,7 @@ int SmartPhoneSN::ConnectWithKernelPort_Ex() |
|
@@ -630,6 +647,7 @@ int SmartPhoneSN::ConnectWithKernelPort_Ex() |
|
630
|
SPMETA_DLL::META_ConnectByUSB_Report spUSBConnReport;
|
647
|
SPMETA_DLL::META_ConnectByUSB_Report spUSBConnReport;
|
|
631
|
|
648
|
|
|
632
|
// kernel comport filter white list
|
649
|
// kernel comport filter white list
|
|
|
|
650
|
+ UpdateUIMsg("ConnectWithKernelPort_Ex");
|
|
633
|
cPortHelper.SetFilter(SP_WHITE_LIST, g_sMetaComm.sPortFilter.strKernelFilter);
|
651
|
cPortHelper.SetFilter(SP_WHITE_LIST, g_sMetaComm.sPortFilter.strKernelFilter);
|
|
634
|
psCOMProperty = cPortHelper.GetPorts(true);
|
652
|
psCOMProperty = cPortHelper.GetPorts(true);
|
|
635
|
memset(&spUSBConnReq, 0, sizeof(spUSBConnReq));
|
653
|
memset(&spUSBConnReq, 0, sizeof(spUSBConnReq));
|
|
@@ -643,6 +661,7 @@ int SmartPhoneSN::ConnectWithKernelPort_Ex() |
|
@@ -643,6 +661,7 @@ int SmartPhoneSN::ConnectWithKernelPort_Ex() |
|
643
|
// timeout unit: s, but m_tMetaReq_Ex.ms_connect_timeout unit is ms
|
661
|
// timeout unit: s, but m_tMetaReq_Ex.ms_connect_timeout unit is ms
|
|
644
|
int iTimeout = m_tMetaReq_Ex.ms_connect_timeout / 1000;
|
662
|
int iTimeout = m_tMetaReq_Ex.ms_connect_timeout / 1000;
|
|
645
|
MTRACE(g_hEBOOT_DEBUG, "SP_BROM::SP_GetUSBCOMPortWithFilter(): enum kernel comport...");
|
663
|
MTRACE(g_hEBOOT_DEBUG, "SP_BROM::SP_GetUSBCOMPortWithFilter(): enum kernel comport...");
|
|
|
|
664
|
+ UpdateUIMsg("SP_GetUSBCOMPortWithFilter");
|
|
646
|
iRet = SP_GetUSBCOMPortWithFilter(cPortHelper.GetFilter(), psCOMProperty, _FALSE, m_pMetaStopFlag, iTimeout);
|
665
|
iRet = SP_GetUSBCOMPortWithFilter(cPortHelper.GetFilter(), psCOMProperty, _FALSE, m_pMetaStopFlag, iTimeout);
|
|
647
|
if (iRet != 0)
|
666
|
if (iRet != 0)
|
|
648
|
{
|
667
|
{
|
|
@@ -694,6 +713,7 @@ int SmartPhoneSN::ConnectWithKernelPort_Ex() |
|
@@ -694,6 +713,7 @@ int SmartPhoneSN::ConnectWithKernelPort_Ex() |
|
694
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::TryToOpenSPKernelComport(): Try to open kernel com port ok.");
|
713
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::TryToOpenSPKernelComport(): Try to open kernel com port ok.");
|
|
695
|
|
714
|
|
|
696
|
MTRACE(g_hEBOOT_DEBUG, "SPMETA_DLL::SP_META_ConnectInMetaModeByUSB_r(): Enter AP meta mode by comport %d...", m_nKernelComport);
|
715
|
MTRACE(g_hEBOOT_DEBUG, "SPMETA_DLL::SP_META_ConnectInMetaModeByUSB_r(): Enter AP meta mode by comport %d...", m_nKernelComport);
|
|
|
|
716
|
+ UpdateUIMsg("SP_META_ConnectInMetaModeByUSB_r");
|
|
697
|
iRet = SPMETA_DLL::SP_META_ConnectInMetaModeByUSB_r (m_hSPMetaHandle, &spUSBConnReq, m_pMetaStopFlag, &spUSBConnReport);
|
717
|
iRet = SPMETA_DLL::SP_META_ConnectInMetaModeByUSB_r (m_hSPMetaHandle, &spUSBConnReq, m_pMetaStopFlag, &spUSBConnReport);
|
|
698
|
if (iRet == SPMETA_DLL::META_SUCCESS)
|
718
|
if (iRet == SPMETA_DLL::META_SUCCESS)
|
|
699
|
{
|
719
|
{
|
|
@@ -803,6 +823,7 @@ int SmartPhoneSN::ConnectWithPreloader() |
|
@@ -803,6 +823,7 @@ int SmartPhoneSN::ConnectWithPreloader() |
|
803
|
int iRet = 0;
|
823
|
int iRet = 0;
|
|
804
|
unsigned int eType; //0:BoorROMUSB,1:PreloaderUSB
|
824
|
unsigned int eType; //0:BoorROMUSB,1:PreloaderUSB
|
|
805
|
|
825
|
|
|
|
|
826
|
+ UpdateUIMsg("ConnectWithPreloader");
|
|
806
|
cPortHelper.SetFilter(SP_WHITE_LIST, g_sMetaComm.sPortFilter.strBromFilter, BootROMUSB);
|
827
|
cPortHelper.SetFilter(SP_WHITE_LIST, g_sMetaComm.sPortFilter.strBromFilter, BootROMUSB);
|
|
807
|
cPortHelper.SetFilter(SP_WHITE_LIST, g_sMetaComm.sPortFilter.strPreloaderFilter, PreloaderUSB, true);
|
828
|
cPortHelper.SetFilter(SP_WHITE_LIST, g_sMetaComm.sPortFilter.strPreloaderFilter, PreloaderUSB, true);
|
|
808
|
|
829
|
|
|
@@ -814,6 +835,7 @@ int SmartPhoneSN::ConnectWithPreloader() |
|
@@ -814,6 +835,7 @@ int SmartPhoneSN::ConnectWithPreloader() |
|
814
|
else
|
835
|
else
|
|
815
|
{
|
836
|
{
|
|
816
|
int iTimeout = m_stModeArg.m_uTimeout / 1000; //timeout unit: s, but m_stModeArg.m_uTimeout unit is ms
|
837
|
int iTimeout = m_stModeArg.m_uTimeout / 1000; //timeout unit: s, but m_stModeArg.m_uTimeout unit is ms
|
|
|
|
838
|
+ UpdateUIMsg("SP_GetIncrementCOMPortWithFilter");
|
|
817
|
iRet = SP_GetIncrementCOMPortWithFilter(cPortHelper.GetFilter(), &sCOMProperty, NULL, _TRUE, m_pMetaStopFlag, iTimeout);
|
839
|
iRet = SP_GetIncrementCOMPortWithFilter(cPortHelper.GetFilter(), &sCOMProperty, NULL, _TRUE, m_pMetaStopFlag, iTimeout);
|
|
818
|
if (0 == iRet)
|
840
|
if (0 == iRet)
|
|
819
|
{
|
841
|
{
|
|
@@ -861,6 +883,7 @@ int SmartPhoneSN::ConnectWithPreloader() |
|
@@ -861,6 +883,7 @@ int SmartPhoneSN::ConnectWithPreloader() |
|
861
|
else if (PreloaderUSB == eType)
|
883
|
else if (PreloaderUSB == eType)
|
|
862
|
{
|
884
|
{
|
|
863
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::ConnectWithPreloader(): Get preloader comport successfully, comport = %d", m_stModeArg.m_uPortNumber);
|
885
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::ConnectWithPreloader(): Get preloader comport successfully, comport = %d", m_stModeArg.m_uPortNumber);
|
|
|
|
886
|
+ UpdateUIMsg("SP_Preloader_BootMode");
|
|
864
|
iRet = SP_Preloader_BootMode(&m_stModeArg);
|
887
|
iRet = SP_Preloader_BootMode(&m_stModeArg);
|
|
865
|
if (iRet == 0)
|
888
|
if (iRet == 0)
|
|
866
|
{
|
889
|
{
|
|
@@ -888,6 +911,7 @@ void SmartPhoneSN::APMetaHandle_DeInit() |
|
@@ -888,6 +911,7 @@ void SmartPhoneSN::APMetaHandle_DeInit() |
|
888
|
SPMETA_DLL::META_RESULT SmartPhoneSN::APMetaHandle_Init()
|
911
|
SPMETA_DLL::META_RESULT SmartPhoneSN::APMetaHandle_Init()
|
|
889
|
{
|
912
|
{
|
|
890
|
SPMETA_DLL::META_RESULT spMetaResult = SPMETA_DLL::META_SUCCESS;
|
913
|
SPMETA_DLL::META_RESULT spMetaResult = SPMETA_DLL::META_SUCCESS;
|
|
|
|
914
|
+ UpdateUIMsg("APMetaHandle_Init");
|
|
891
|
spMetaResult = SPMETA_DLL::SP_META_GetAvailableHandle ( &m_hSPMetaHandle );
|
915
|
spMetaResult = SPMETA_DLL::SP_META_GetAvailableHandle ( &m_hSPMetaHandle );
|
|
892
|
if (spMetaResult != SPMETA_DLL::META_SUCCESS )
|
916
|
if (spMetaResult != SPMETA_DLL::META_SUCCESS )
|
|
893
|
{
|
917
|
{
|
|
@@ -896,6 +920,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::APMetaHandle_Init() |
|
@@ -896,6 +920,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::APMetaHandle_Init() |
|
896
|
}
|
920
|
}
|
|
897
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::SP_META_GetAvailableHandle(): Get available AP handle success");
|
921
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::SP_META_GetAvailableHandle(): Get available AP handle success");
|
|
898
|
|
922
|
|
|
|
|
923
|
+ UpdateUIMsg("SP_META_Init_r");
|
|
899
|
spMetaResult = SPMETA_DLL::SP_META_Init_r (m_hSPMetaHandle , NULL);
|
924
|
spMetaResult = SPMETA_DLL::SP_META_Init_r (m_hSPMetaHandle , NULL);
|
|
900
|
if ( spMetaResult != META_SUCCESS)
|
925
|
if ( spMetaResult != META_SUCCESS)
|
|
901
|
{
|
926
|
{
|
|
@@ -953,6 +978,8 @@ void SmartPhoneSN::MetaHandle_DeInit() |
|
@@ -953,6 +978,8 @@ void SmartPhoneSN::MetaHandle_DeInit() |
|
953
|
META_RESULT SmartPhoneSN::ModemMetaHandle_Init()
|
978
|
META_RESULT SmartPhoneSN::ModemMetaHandle_Init()
|
|
954
|
{
|
979
|
{
|
|
955
|
META_RESULT meta_result = META_SUCCESS;
|
980
|
META_RESULT meta_result = META_SUCCESS;
|
|
|
|
981
|
+ UpdateUIMsg("ModemMetaHandle_Init");
|
|
|
|
982
|
+ UpdateUIMsg("META_GetAvailableHandle");
|
|
956
|
meta_result = META_GetAvailableHandle( &m_hMauiMetaHandle );
|
983
|
meta_result = META_GetAvailableHandle( &m_hMauiMetaHandle );
|
|
957
|
if (meta_result != META_SUCCESS)
|
984
|
if (meta_result != META_SUCCESS)
|
|
958
|
{
|
985
|
{
|
|
@@ -971,6 +998,7 @@ META_RESULT SmartPhoneSN::ModemMetaHandle_Init() |
|
@@ -971,6 +998,7 @@ META_RESULT SmartPhoneSN::ModemMetaHandle_Init() |
|
971
|
meta_result = META_Init_Ex_2_r( m_hMauiMetaHandle, NULL, MdQueryHandler, NULL, NULL, NULL, MdTypeSwitchHandler, NULL);
|
998
|
meta_result = META_Init_Ex_2_r( m_hMauiMetaHandle, NULL, MdQueryHandler, NULL, NULL, NULL, MdTypeSwitchHandler, NULL);
|
|
972
|
}
|
999
|
}
|
|
973
|
*/
|
1000
|
*/
|
|
|
|
1001
|
+ UpdateUIMsg("META_Init_Ex_2_r");
|
|
974
|
meta_result = META_Init_Ex_2_r( m_hMauiMetaHandle, NULL, MdQueryHandler, (void*)&m_sMdInfo, NULL, NULL, MdTypeSwitchHandler, NULL);
|
1002
|
meta_result = META_Init_Ex_2_r( m_hMauiMetaHandle, NULL, MdQueryHandler, (void*)&m_sMdInfo, NULL, NULL, MdTypeSwitchHandler, NULL);
|
|
975
|
if (meta_result != META_SUCCESS)
|
1003
|
if (meta_result != META_SUCCESS)
|
|
976
|
{
|
1004
|
{
|
|
@@ -986,6 +1014,7 @@ META_RESULT SmartPhoneSN::MetaHandle_Init() |
|
@@ -986,6 +1014,7 @@ META_RESULT SmartPhoneSN::MetaHandle_Init() |
|
986
|
{
|
1014
|
{
|
|
987
|
META_RESULT meta_result;
|
1015
|
META_RESULT meta_result;
|
|
988
|
SPMETA_DLL::META_RESULT spMetaResult;
|
1016
|
SPMETA_DLL::META_RESULT spMetaResult;
|
|
|
|
1017
|
+ UpdateUIMsg("MetaHandle_Init");
|
|
989
|
|
1018
|
|
|
990
|
if (m_hMauiMetaHandle == INVALID_META_HANDLE)
|
1019
|
if (m_hMauiMetaHandle == INVALID_META_HANDLE)
|
|
991
|
{
|
1020
|
{
|
|
@@ -1275,11 +1304,13 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::REQ_WriteAP_PRODINFO_Start() |
|
@@ -1275,11 +1304,13 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::REQ_WriteAP_PRODINFO_Start() |
|
1275
|
SPMETA_DLL::FT_NVRAM_READ_REQ sNVRAM_ReadReq;
|
1304
|
SPMETA_DLL::FT_NVRAM_READ_REQ sNVRAM_ReadReq;
|
|
1276
|
SPMETA_DLL::FT_NVRAM_READ_CNF sNVRAM_ReadCnf;
|
1305
|
SPMETA_DLL::FT_NVRAM_READ_CNF sNVRAM_ReadCnf;
|
|
1277
|
|
1306
|
|
|
|
|
1307
|
+ UpdateUIMsg("REQ_WriteAP_PRODINFO_Start");
|
|
1278
|
memset(&sNVRAM_WriteReq, 0, sizeof(SPMETA_DLL::FT_NVRAM_WRITE_REQ));
|
1308
|
memset(&sNVRAM_WriteReq, 0, sizeof(SPMETA_DLL::FT_NVRAM_WRITE_REQ));
|
|
1279
|
memset(&sNVRAM_ReadReq, 0, sizeof(SPMETA_DLL::FT_NVRAM_READ_REQ));
|
1309
|
memset(&sNVRAM_ReadReq, 0, sizeof(SPMETA_DLL::FT_NVRAM_READ_REQ));
|
|
1280
|
memset(&sNVRAM_ReadCnf, 0, sizeof(SPMETA_DLL::FT_NVRAM_READ_CNF));
|
1310
|
memset(&sNVRAM_ReadCnf, 0, sizeof(SPMETA_DLL::FT_NVRAM_READ_CNF));
|
|
1281
|
|
1311
|
|
|
1282
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::SP_META_NVRAM_GetRecLen(): Start to get nvram struct size via LID = \"%s\"...", pLID);
|
1312
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::SP_META_NVRAM_GetRecLen(): Start to get nvram struct size via LID = \"%s\"...", pLID);
|
|
|
|
1313
|
+ UpdateUIMsg("SP_META_NVRAM_GetRecLen");
|
|
1283
|
meta_result = SPMETA_DLL::SP_META_NVRAM_GetRecLen(pLID, &iWriteBufSize);
|
1314
|
meta_result = SPMETA_DLL::SP_META_NVRAM_GetRecLen(pLID, &iWriteBufSize);
|
|
1284
|
if ( SPMETA_DLL::META_SUCCESS != meta_result)
|
1315
|
if ( SPMETA_DLL::META_SUCCESS != meta_result)
|
|
1285
|
{
|
1316
|
{
|
|
@@ -1311,6 +1342,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::REQ_WriteAP_PRODINFO_Start() |
|
@@ -1311,6 +1342,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::REQ_WriteAP_PRODINFO_Start() |
|
1311
|
}
|
1342
|
}
|
|
1312
|
|
1343
|
|
|
1313
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::REQ_ReadFromAPNVRAM(): Start to read nvram data...");
|
1344
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::REQ_ReadFromAPNVRAM(): Start to read nvram data...");
|
|
|
|
1345
|
+ UpdateUIMsg("REQ_ReadFromAPNVRAM");
|
|
1314
|
meta_result = REQ_ReadFromAPNVRAM (&sNVRAM_ReadReq, &sNVRAM_ReadCnf);
|
1346
|
meta_result = REQ_ReadFromAPNVRAM (&sNVRAM_ReadReq, &sNVRAM_ReadCnf);
|
|
1315
|
if (meta_result != SPMETA_DLL::META_SUCCESS )
|
1347
|
if (meta_result != SPMETA_DLL::META_SUCCESS )
|
|
1316
|
{
|
1348
|
{
|
|
@@ -1319,6 +1351,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::REQ_WriteAP_PRODINFO_Start() |
|
@@ -1319,6 +1351,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::REQ_WriteAP_PRODINFO_Start() |
|
1319
|
}
|
1351
|
}
|
|
1320
|
|
1352
|
|
|
1321
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::ConductProdInfoData(): Conduct Prod_Info nvram data start...");
|
1353
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::ConductProdInfoData(): Conduct Prod_Info nvram data start...");
|
|
|
|
1354
|
+ UpdateUIMsg("ConductProdInfoData");
|
|
1322
|
meta_result = ConductProdInfoData(sNVRAM_ReadCnf.buf, iWriteBufSize);
|
1355
|
meta_result = ConductProdInfoData(sNVRAM_ReadCnf.buf, iWriteBufSize);
|
|
1323
|
if (meta_result != SPMETA_DLL::META_SUCCESS)
|
1356
|
if (meta_result != SPMETA_DLL::META_SUCCESS)
|
|
1324
|
{
|
1357
|
{
|
|
@@ -1339,6 +1372,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::REQ_WriteAP_PRODINFO_Start() |
|
@@ -1339,6 +1372,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::REQ_WriteAP_PRODINFO_Start() |
|
1339
|
m_sNVRAM_OPID = 1;
|
1372
|
m_sNVRAM_OPID = 1;
|
|
1340
|
|
1373
|
|
|
1341
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::REQ_WriteToAPNVRAM(): Start to write nvram data...");
|
1374
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::REQ_WriteToAPNVRAM(): Start to write nvram data...");
|
|
|
|
1375
|
+ UpdateUIMsg("REQ_WriteToAPNVRAM");
|
|
1342
|
meta_result = REQ_WriteToAPNVRAM(sNVRAM_WriteReq);
|
1376
|
meta_result = REQ_WriteToAPNVRAM(sNVRAM_WriteReq);
|
|
1343
|
if (meta_result != SPMETA_DLL::META_SUCCESS )
|
1377
|
if (meta_result != SPMETA_DLL::META_SUCCESS )
|
|
1344
|
{
|
1378
|
{
|
|
@@ -1349,6 +1383,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::REQ_WriteAP_PRODINFO_Start() |
|
@@ -1349,6 +1383,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::REQ_WriteAP_PRODINFO_Start() |
|
1349
|
|
1383
|
|
|
1350
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::REQ_WriteToAPNVRAM(): Read nvram data for check start...");
|
1384
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::REQ_WriteToAPNVRAM(): Read nvram data for check start...");
|
|
1351
|
memset(sNVRAM_ReadCnf.buf, 0 , sNVRAM_ReadCnf.len);
|
1385
|
memset(sNVRAM_ReadCnf.buf, 0 , sNVRAM_ReadCnf.len);
|
|
|
|
1386
|
+ UpdateUIMsg("REQ_ReadFromAPNVRAM");
|
|
1352
|
meta_result = REQ_ReadFromAPNVRAM (&sNVRAM_ReadReq, &sNVRAM_ReadCnf);
|
1387
|
meta_result = REQ_ReadFromAPNVRAM (&sNVRAM_ReadReq, &sNVRAM_ReadCnf);
|
|
1353
|
if (meta_result != SPMETA_DLL::META_SUCCESS )
|
1388
|
if (meta_result != SPMETA_DLL::META_SUCCESS )
|
|
1354
|
{
|
1389
|
{
|
|
@@ -3096,6 +3131,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::LoadAPDatabase() |
|
@@ -3096,6 +3131,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::LoadAPDatabase() |
|
3096
|
const char * dbpath = NULL;
|
3131
|
const char * dbpath = NULL;
|
|
3097
|
unsigned long db;
|
3132
|
unsigned long db;
|
|
3098
|
|
3133
|
|
|
|
|
3134
|
+ UpdateUIMsg("LoadAPDatabase");
|
|
3099
|
if (g_sMetaComm.sDBFileOption.bAPDBFromDUT && g_sMetaComm.sDBFileOption.strAPDbPath_DUT[0] != '\0')
|
3135
|
if (g_sMetaComm.sDBFileOption.bAPDBFromDUT && g_sMetaComm.sDBFileOption.strAPDbPath_DUT[0] != '\0')
|
|
3100
|
dbpath = g_sMetaComm.sDBFileOption.strAPDbPath_DUT;
|
3136
|
dbpath = g_sMetaComm.sDBFileOption.strAPDbPath_DUT;
|
|
3101
|
else
|
3137
|
else
|
|
@@ -3109,6 +3145,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::LoadAPDatabase() |
|
@@ -3109,6 +3145,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::LoadAPDatabase() |
|
3109
|
}
|
3145
|
}
|
|
3110
|
|
3146
|
|
|
3111
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::LoadAPDatabase(): Start to init AP database, DB path = %s", dbpath);
|
3147
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::LoadAPDatabase(): Start to init AP database, DB path = %s", dbpath);
|
|
|
|
3148
|
+ UpdateUIMsg("SP_META_NVRAM_Init_r");
|
|
3112
|
MetaResult = SPMETA_DLL::SP_META_NVRAM_Init_r(m_hSPMetaHandle, dbpath, &db);
|
3149
|
MetaResult = SPMETA_DLL::SP_META_NVRAM_Init_r(m_hSPMetaHandle, dbpath, &db);
|
|
3113
|
if ( MetaResult == SPMETA_DLL::META_SUCCESS)
|
3150
|
if ( MetaResult == SPMETA_DLL::META_SUCCESS)
|
|
3114
|
{
|
3151
|
{
|
|
@@ -3143,6 +3180,7 @@ META_RESULT SmartPhoneSN::LoadModemDatabase(int MDindex) |
|
@@ -3143,6 +3180,7 @@ META_RESULT SmartPhoneSN::LoadModemDatabase(int MDindex) |
|
3143
|
const char *pStrMDDbpath = NULL;
|
3180
|
const char *pStrMDDbpath = NULL;
|
|
3144
|
unsigned long db = 0;
|
3181
|
unsigned long db = 0;
|
|
3145
|
|
3182
|
|
|
|
|
3183
|
+ UpdateUIMsg("LoadModemDatabase");
|
|
3146
|
switch (MDindex)
|
3184
|
switch (MDindex)
|
|
3147
|
{
|
3185
|
{
|
|
3148
|
case 0:
|
3186
|
case 0:
|
|
@@ -3186,6 +3224,7 @@ META_RESULT SmartPhoneSN::LoadModemDatabase(int MDindex) |
|
@@ -3186,6 +3224,7 @@ META_RESULT SmartPhoneSN::LoadModemDatabase(int MDindex) |
|
3186
|
{
|
3224
|
{
|
|
3187
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::META_NVRAM_Init_Ex_r(): start to init MD[%d] database, DB path = \"%s\"...",
|
3225
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::META_NVRAM_Init_Ex_r(): start to init MD[%d] database, DB path = \"%s\"...",
|
|
3188
|
MDindex, pStrMDDbpath);
|
3226
|
MDindex, pStrMDDbpath);
|
|
|
|
3227
|
+ UpdateUIMsg("META_NVRAM_Init_Ex_r");
|
|
3189
|
meta_result = META_NVRAM_Init_Ex_r(m_hMauiMetaHandle, MDindex, pStrMDDbpath, &db);
|
3228
|
meta_result = META_NVRAM_Init_Ex_r(m_hMauiMetaHandle, MDindex, pStrMDDbpath, &db);
|
|
3190
|
pFuncName = "META_NVRAM_Init_Ex_r";
|
3229
|
pFuncName = "META_NVRAM_Init_Ex_r";
|
|
3191
|
}
|
3230
|
}
|
|
@@ -3204,6 +3243,7 @@ META_RESULT SmartPhoneSN::LoadModemDatabase(int MDindex) |
|
@@ -3204,6 +3243,7 @@ META_RESULT SmartPhoneSN::LoadModemDatabase(int MDindex) |
|
3204
|
|
3243
|
|
|
3205
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::META_NVRAM_Init_Ex_Mdtype_r(): start to init MD[%d] database, DB path = \"%s\"...",
|
3244
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::META_NVRAM_Init_Ex_Mdtype_r(): start to init MD[%d] database, DB path = \"%s\"...",
|
|
3206
|
MDindex, pStrMDDbpath);
|
3245
|
MDindex, pStrMDDbpath);
|
|
|
|
3246
|
+ UpdateUIMsg("META_NVRAM_Init_Ex_Mdtype_r");
|
|
3207
|
meta_result = META_NVRAM_Init_Ex_Mdtype_r(m_hMauiMetaHandle, MDindex, m_sMdInfo.activeMdTypeIdx, pStrMDDbpath, &db);
|
3247
|
meta_result = META_NVRAM_Init_Ex_Mdtype_r(m_hMauiMetaHandle, MDindex, m_sMdInfo.activeMdTypeIdx, pStrMDDbpath, &db);
|
|
3208
|
pFuncName = "META_NVRAM_Init_Ex_Mdtype_r";
|
3248
|
pFuncName = "META_NVRAM_Init_Ex_Mdtype_r";
|
|
3209
|
}
|
3249
|
}
|
|
@@ -3560,6 +3600,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::EnterAPMetaMode() |
|
@@ -3560,6 +3600,7 @@ SPMETA_DLL::META_RESULT SmartPhoneSN::EnterAPMetaMode() |
|
3560
|
int bootResult = 0;
|
3600
|
int bootResult = 0;
|
|
3561
|
|
3601
|
|
|
3562
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::EnterAPMetaMode() : Enter ap meta start...");
|
3602
|
MTRACE (g_hEBOOT_DEBUG, "SmartPhoneSN::EnterAPMetaMode() : Enter ap meta start...");
|
|
|
|
3603
|
+ UpdateUIMsg("EnterAPMetaMode");
|
|
3563
|
|
3604
|
|
|
3564
|
if (!g_sMetaComm.bAlreadyInMeata)
|
3605
|
if (!g_sMetaComm.bAlreadyInMeata)
|
|
3565
|
{
|
3606
|
{
|
|
@@ -3929,6 +3970,7 @@ void SmartPhoneSN::ThreadMainEntryPoint() |
|
@@ -3929,6 +3970,7 @@ void SmartPhoneSN::ThreadMainEntryPoint() |
|
3929
|
}
|
3970
|
}
|
|
3930
|
}
|
3971
|
}
|
|
3931
|
|
3972
|
|
|
|
|
3973
|
+ UpdateUIMsg("SP_META_QueryIfFunctionSupportedByTarget_r");
|
|
3932
|
SPMetaResult = SPMETA_DLL::SP_META_QueryIfFunctionSupportedByTarget_r(m_hSPMetaHandle, 500, "SP_META_ENCRYPTED_Support_r");
|
3974
|
SPMetaResult = SPMETA_DLL::SP_META_QueryIfFunctionSupportedByTarget_r(m_hSPMetaHandle, 500, "SP_META_ENCRYPTED_Support_r");
|
|
3933
|
if (SPMetaResult == SPMETA_DLL::META_SUCCESS)
|
3975
|
if (SPMetaResult == SPMETA_DLL::META_SUCCESS)
|
|
3934
|
{
|
3976
|
{
|
|
@@ -3991,6 +4033,7 @@ void SmartPhoneSN::ThreadMainEntryPoint() |
|
@@ -3991,6 +4033,7 @@ void SmartPhoneSN::ThreadMainEntryPoint() |
|
3991
|
|
4033
|
|
|
3992
|
|
4034
|
|
|
3993
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::ApSwithToModemMeta_Ex(): Switch to MODEM meta from AP meta start...");
|
4035
|
MTRACE(g_hEBOOT_DEBUG, "SmartPhoneSN::ApSwithToModemMeta_Ex(): Switch to MODEM meta from AP meta start...");
|
|
|
|
4036
|
+ UpdateUIMsg("APSwithToModemMeta_Ex");
|
|
3994
|
MetaResult = APSwithToModemMeta_Ex();
|
4037
|
MetaResult = APSwithToModemMeta_Ex();
|
|
3995
|
if (MetaResult != META_SUCCESS)
|
4038
|
if (MetaResult != META_SUCCESS)
|
|
3996
|
{
|
4039
|
{
|
|
@@ -4023,6 +4066,9 @@ void SmartPhoneSN::ThreadMainEntryPoint() |
|
@@ -4023,6 +4066,9 @@ void SmartPhoneSN::ThreadMainEntryPoint() |
|
4023
|
}
|
4066
|
}
|
|
4024
|
|
4067
|
|
|
4025
|
End:
|
4068
|
End:
|
|
|
|
4069
|
+
|
|
|
|
4070
|
+ g_pMainDlg->KillTimer(1);
|
|
|
|
4071
|
+ g_pMainDlg->mytimecount = 0;
|
|
4026
|
if (m_bStopBeforeUSBInsert == true)
|
4072
|
if (m_bStopBeforeUSBInsert == true)
|
|
4027
|
{
|
4073
|
{
|
|
4028
|
UpdateUIMsg("...");
|
4074
|
UpdateUIMsg("...");
|
|
@@ -4913,6 +4959,7 @@ bool SmartPhoneSN::QueryEncryptionSupport(int * MetaHandle ) |
|
@@ -4913,6 +4959,7 @@ bool SmartPhoneSN::QueryEncryptionSupport(int * MetaHandle ) |
|
4913
|
|
4959
|
|
|
4914
|
SPMETA_DLL::CRYPTFS_QUERYSUPPORT_CNF cryptfs_Support_cnf;
|
4960
|
SPMETA_DLL::CRYPTFS_QUERYSUPPORT_CNF cryptfs_Support_cnf;
|
|
4915
|
SPMETA_DLL::META_RESULT MetaResult;
|
4961
|
SPMETA_DLL::META_RESULT MetaResult;
|
|
|
|
4962
|
+ UpdateUIMsg("SP_META_ENCRYPTED_Support_r");
|
|
4916
|
MetaResult = SPMETA_DLL::SP_META_ENCRYPTED_Support_r(*MetaHandle, 60000, &cryptfs_Support_cnf);
|
4963
|
MetaResult = SPMETA_DLL::SP_META_ENCRYPTED_Support_r(*MetaHandle, 60000, &cryptfs_Support_cnf);
|
|
4917
|
|
4964
|
|
|
4918
|
if ((MetaResult == META_SUCCESS) && (cryptfs_Support_cnf.support == 1))
|
4965
|
if ((MetaResult == META_SUCCESS) && (cryptfs_Support_cnf.support == 1))
|