diff options
author | Banavathu, Srinivas Naik <snb@codeaurora.org> | 2012-10-01 15:03:35 +0530 |
---|---|---|
committer | Linux Build Service Account <lnxbuild@localhost> | 2013-10-31 18:50:51 -0600 |
commit | edae7fd8d1135ca75452dcfaab4d01b6be000c64 (patch) | |
tree | 3942e01a82ff187cd128c993c5f0d5da1e6653a2 /src/java/com/android/internal/telephony/uicc/IccRecords.java | |
parent | 982d0dbc74479d2e8fea5fb934af7c6ca1283ad5 (diff) | |
download | android_frameworks_opt_telephony-edae7fd8d1135ca75452dcfaab4d01b6be000c64.tar.gz android_frameworks_opt_telephony-edae7fd8d1135ca75452dcfaab4d01b6be000c64.tar.bz2 android_frameworks_opt_telephony-edae7fd8d1135ca75452dcfaab4d01b6be000c64.zip |
Do not send Radio Power Off on SIM_RESET
This change is needed as per GCF test spec
Change-Id: I287eb9b5a0263109b2343a6d1397ee6641ff7a56
CRs-Fixed: 441924
(cherry picked from commit a452c2d7b482a365c8e0cdff3c364ea29ec86dae)
(cherry picked from commit c13e350f4f4e52d4809508fd8f099c6ca3737d17)
(cherry picked from commit b470d1315741774093ba51af5eec988f67afeb8f)
Diffstat (limited to 'src/java/com/android/internal/telephony/uicc/IccRecords.java')
-rw-r--r-- | src/java/com/android/internal/telephony/uicc/IccRecords.java | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/src/java/com/android/internal/telephony/uicc/IccRecords.java b/src/java/com/android/internal/telephony/uicc/IccRecords.java index 3ce5fc8a8..f78c23f6f 100644 --- a/src/java/com/android/internal/telephony/uicc/IccRecords.java +++ b/src/java/com/android/internal/telephony/uicc/IccRecords.java @@ -460,15 +460,16 @@ public abstract class IccRecords extends Handler implements IccConstants { break; case IccRefreshResponse.REFRESH_RESULT_RESET: if (DBG) log("handleRefresh with SIM_REFRESH_RESET"); - mCi.setRadioPower(false, null); - /* Note: no need to call setRadioPower(true). Assuming the desired - * radio power state is still ON (as tracked by ServiceStateTracker), - * ServiceStateTracker will call setRadioPower when it receives the - * RADIO_STATE_CHANGED notification for the power off. And if the - * desired power state has changed in the interim, we don't want to - * override it with an unconditional power on. - */ - + if (powerOffOnSimReset()) { + mCi.setRadioPower(false, null); + /* Note: no need to call setRadioPower(true). Assuming the desired + * radio power state is still ON (as tracked by ServiceStateTracker), + * ServiceStateTracker will call setRadioPower when it receives the + * RADIO_STATE_CHANGED notification for the power off. And if the + * desired power state has changed in the interim, we don't want to + * override it with an unconditional power on. + */ + } mAdnCache.reset(); //We will re-fetch the records when the app // goes back to the ready state. Nothing to do here. @@ -619,4 +620,9 @@ public abstract class IccRecords extends Handler implements IccConstants { pw.println(" mSpn=" + mSpn); pw.flush(); } + + protected boolean powerOffOnSimReset() { + return !mContext.getResources().getBoolean( + com.android.internal.R.bool.skip_radio_power_off_on_sim_refresh_reset); + } } |