Skip to content

Commit 8f669f4

Browse files
Kazuhiro OndoWink Saville
authored andcommitted
Improve sim ready event handling for CdmaLte.
bug: 6463933 Change-Id: I751f760badb87c1fe4b78fd68921257cec4a4b9d
1 parent d7e4ae4 commit 8f669f4

File tree

2 files changed

+15
-4
lines changed

2 files changed

+15
-4
lines changed

telephony/java/com/android/internal/telephony/IccCard.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -579,10 +579,14 @@ private void handleIccCardStatus(IccCardStatus newCardStatus) {
579579
mHandler.sendMessage(mHandler.obtainMessage(EVENT_CARD_ADDED, null));
580580
}
581581

582-
// Call onReady only when SIM or RUIM card becomes ready (not NV)
582+
// Call onReady Record(s) on the IccCard becomes ready (not NV)
583583
if (oldState != State.READY && newState == State.READY &&
584584
(is3gpp || isSubscriptionFromIccCard)) {
585-
mIccFileHandler.setAid(getAid());
585+
if (!(mIccFileHandler instanceof CdmaLteUiccFileHandler)) {
586+
// CdmaLteUicc File Handler deals with both USIM and CSIM.
587+
// Do not lock onto one AID for now.
588+
mIccFileHandler.setAid(getAid());
589+
}
586590
mIccRecords.onReady();
587591
}
588592
}

telephony/java/com/android/internal/telephony/cdma/CdmaServiceStateTracker.java

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -293,8 +293,15 @@ public void handleMessage (Message msg) {
293293
EVENT_RUIM_RECORDS_LOADED, null);
294294
mNeedToRegForRuimLoaded = false;
295295
}
296-
if (DBG) log("Receive EVENT_RUIM_READY and Send Request getCDMASubscription.");
297-
getSubscriptionInfoAndStartPollingThreads();
296+
297+
if (phone.getLteOnCdmaMode() == Phone.LTE_ON_CDMA_TRUE) {
298+
// Subscription will be read from SIM I/O
299+
if (DBG) log("Receive EVENT_RUIM_READY");
300+
pollState();
301+
} else {
302+
if (DBG) log("Receive EVENT_RUIM_READY and Send Request getCDMASubscription.");
303+
getSubscriptionInfoAndStartPollingThreads();
304+
}
298305
phone.prepareEri();
299306
break;
300307

0 commit comments

Comments
 (0)