Backed out 4 changesets (bug 978027) for suspicion of causing B2G debug mochitest shutdown hangs.
authorRyan VanderMeulen <ryanvm@gmail.com>
Wed, 16 Apr 2014 14:42:42 -0400
changeset 191862 ff6d4fb1ee349fc34d6dc06ef9439378f8b73fc7
parent 191861 9a056810f065757e57c4b261af95dcf75e3628d5
child 191863 752e654ea92b53e9c6251562101890fd8e3a6608
push id3503
push userraliiev@mozilla.com
push dateMon, 28 Apr 2014 18:51:11 +0000
treeherdermozilla-beta@c95ac01e332e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs978027
milestone30.0a2
backs out24e3dcfeccf485d62f11f26dd81b09a2aff063e0
c2f4decd1d2f8572c818c2350fe0044c6c31c930
a8bdec0445f175cbf9bf2f7ee4c0f43868f54160
0912de2bb07f4e7ce479a05a4a6cc110440e5f37
Backed out 4 changesets (bug 978027) for suspicion of causing B2G debug mochitest shutdown hangs. Backed out changeset 24e3dcfeccf4 (bug 978027) Backed out changeset c2f4decd1d2f (bug 978027) Backed out changeset a8bdec0445f1 (bug 978027) Backed out changeset 0912de2bb07f (bug 978027)
dom/icc/interfaces/nsIDOMIccInfo.idl
dom/icc/tests/marionette/icc_header.js
dom/icc/tests/marionette/test_icc_info.js
dom/system/gonk/RILContentHelper.js
dom/system/gonk/RadioInterfaceLayer.js
dom/system/gonk/ril_worker.js
--- a/dom/icc/interfaces/nsIDOMIccInfo.idl
+++ b/dom/icc/interfaces/nsIDOMIccInfo.idl
@@ -50,21 +50,16 @@ interface nsIDOMMozGsmIccInfo : nsIDOMMo
 {
   /**
    * Mobile Station ISDN Number (MSISDN) of the subscriber, aka
    * his phone number.
    */
   readonly attribute DOMString msisdn;
 };
 
-[scriptable, uuid(7e937d09-4d1d-43c5-96d8-c91396022809)]
+[scriptable, uuid(10b89660-2988-443a-a6f0-4ed3618fee41)]
 interface nsIDOMMozCdmaIccInfo : nsIDOMMozIccInfo
 {
   /**
    * Mobile Directory Number (MDN) of the subscriber, aka his phone number.
    */
   readonly attribute DOMString mdn;
-
-  /**
-   * Preferred Roaming List (PRL) version of the subscriber.
-   */
-  readonly attribute long prlVersion;
 };
--- a/dom/icc/tests/marionette/icc_header.js
+++ b/dom/icc/tests/marionette/icc_header.js
@@ -1,13 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
    http://creativecommons.org/publicdomain/zero/1.0/ */
 
-const {Cc: Cc, Ci: Ci, Cr: Cr, Cu: Cu} = SpecialPowers;
-
 SpecialPowers.addPermission("mobileconnection", true, document);
 
 let iccManager = navigator.mozIccManager;
 ok(iccManager instanceof MozIccManager,
    "iccManager is instanceof " + iccManager.constructor);
 
 // TODO: Bug 932650 - B2G RIL: WebIccManager API - add marionette tests for
 //                    multi-sim
--- a/dom/icc/tests/marionette/test_icc_info.js
+++ b/dom/icc/tests/marionette/test_icc_info.js
@@ -26,49 +26,34 @@ function setEmulatorMccMnc(mcc, mnc) {
     ok(result[0].match(re), "MCC/MNC should be changed.");
   });
 }
 
 /* Basic test */
 taskHelper.push(function basicTest() {
   let iccInfo = icc.iccInfo;
 
+  is(iccInfo.iccType, "sim");
   // The emulator's hard coded iccid value.
   // See it here {B2G_HOME}/external/qemu/telephony/sim_card.c#L299.
   is(iccInfo.iccid, 89014103211118510720);
-
-  if (iccInfo instanceof Ci.nsIDOMMozGsmIccInfo) {
-    log("Test Gsm IccInfo");
-    is(iccInfo.iccType, "sim");
-    is(iccInfo.spn, "Android");
-    // The emulator's hard coded mcc and mnc codes.
-    // See it here {B2G_HOME}/external/qemu/telephony/android_modem.c#L2465.
-    is(iccInfo.mcc, 310);
-    is(iccInfo.mnc, 260);
-    // Phone number is hardcoded in MSISDN
-    // See {B2G_HOME}/external/qemu/telephony/sim_card.c, in asimcard_io()
-    is(iccInfo.msisdn, "15555215554");
-  } else {
-    log("Test Cdma IccInfo");
-    is(iccInfo.iccType, "ruim");
-    // MDN is hardcoded as "8587777777".
-    // See it here {B2G_HOME}/hardware/ril/reference-ril/reference-ril.c,
-    // in requestCdmaSubscription()
-    is(iccInfo.mdn, "8587777777");
-    // PRL version is hardcoded as 1.
-    // See it here {B2G_HOME}/hardware/ril/reference-ril/reference-ril.c,
-    // in requestCdmaSubscription()
-    is(iccInfo.prlVersion, 1);
-  }
+  // The emulator's hard coded mcc and mnc codes.
+  // See it here {B2G_HOME}/external/qemu/telephony/android_modem.c#L2465.
+  is(iccInfo.mcc, 310);
+  is(iccInfo.mnc, 260);
+  is(iccInfo.spn, "Android");
+  // Phone number is hardcoded in MSISDN
+  // See {B2G_HOME}/external/qemu/telephony/sim_card.c, in asimcard_io()
+  is(iccInfo.msisdn, "15555215554");
 
   taskHelper.runNext();
 });
 
-/* Test Gsm display condition change */
-taskHelper.push(function testGsmDisplayConditionChange() {
+/* Test display condition change */
+taskHelper.push(function testDisplayConditionChange() {
   function testSPN(mcc, mnc, expectedIsDisplayNetworkNameRequired,
                    expectedIsDisplaySpnRequired, callback) {
     icc.addEventListener("iccinfochange", function handler() {
       icc.removeEventListener("iccinfochange", handler);
       is(icc.iccInfo.isDisplayNetworkNameRequired,
          expectedIsDisplayNetworkNameRequired);
       is(icc.iccInfo.isDisplaySpnRequired,
          expectedIsDisplaySpnRequired);
@@ -84,22 +69,16 @@ taskHelper.push(function testGsmDisplayC
     [123, 456, false, true], // Not in HPLMN.
     [234, 136,  true, true], // Not in HPLMN, but in PLMN specified in SPDI.
     [123, 456, false, true], // Not in HPLMN. Triggering iccinfochange
     [466,  92,  true, true], // Not in HPLMN, but in another PLMN specified in SPDI.
     [123, 456, false, true], // Not in HPLMN. Triggering iccinfochange
     [310, 260,  true, true], // inside HPLMN.
   ];
 
-  // Ignore this test if device is not in gsm mode.
-  if (!(icc.iccInfo instanceof Ci.nsIDOMMozGsmIccInfo)) {
-    taskHelper.runNext();
-    return;
-  }
-
   (function do_call(index) {
     let next = index < (testCases.length - 1) ? do_call.bind(null, index + 1) : taskHelper.runNext.bind(taskHelper);
     testCases[index].push(next);
     testSPN.apply(null, testCases[index]);
   })(0);
 });
 
 /* Test iccInfo when card becomes undetected */
--- a/dom/system/gonk/RILContentHelper.js
+++ b/dom/system/gonk/RILContentHelper.js
@@ -189,18 +189,17 @@ CdmaIccInfo.prototype = {
     classID:          CDMAICCINFO_CID,
     classDescription: "MozCdmaIccInfo",
     flags:            Ci.nsIClassInfo.DOM_OBJECT,
     interfaces:       [Ci.nsIDOMMozCdmaIccInfo]
   }),
 
   // nsIDOMMozCdmaIccInfo
 
-  mdn: null,
-  prlVersion: 0
+  mdn: null
 };
 
 function VoicemailInfo() {}
 VoicemailInfo.prototype = {
   number: null,
   displayName: null
 };
 
--- a/dom/system/gonk/RadioInterfaceLayer.js
+++ b/dom/system/gonk/RadioInterfaceLayer.js
@@ -1033,18 +1033,17 @@ CdmaIccInfo.prototype = {
     classID:          CDMAICCINFO_CID,
     classDescription: "MozCdmaIccInfo",
     flags:            Ci.nsIClassInfo.DOM_OBJECT,
     interfaces:       [Ci.nsIDOMMozCdmaIccInfo]
   }),
 
   // nsIDOMMozCdmaIccInfo
 
-  mdn: null,
-  prlVersion: 0
+  mdn: null
 };
 
 function DataConnectionHandler(clientId, radioInterface) {
   // Initial owning attributes.
   this.clientId = clientId;
   this.radioInterface = radioInterface;
   this.dataCallSettings = {
     oldEnabled: false,
--- a/dom/system/gonk/ril_worker.js
+++ b/dom/system/gonk/ril_worker.js
@@ -3146,24 +3146,16 @@ RilObject.prototype = {
   reportStkServiceIsRunning: function() {
     this.context.Buf.simpleRequest(REQUEST_REPORT_STK_SERVICE_IS_RUNNING);
   },
 
   /**
    * Process ICC status.
    */
   _processICCStatus: function(iccStatus) {
-    // If |_waitingRadioTech| is true, we should not get app information because
-    // the |_isCdma| flag is not ready yet. Otherwise we may use wrong index to
-    // get app information, especially for the case that icc card has both cdma
-    // and gsm subscription.
-    if (this._waitingRadioTech) {
-      return;
-    }
-
     this.iccStatus = iccStatus;
     let newCardState;
     let index = this._isCdma ? iccStatus.cdmaSubscriptionAppIndex :
                                iccStatus.gsmUmtsSubscriptionAppIndex;
     let app = iccStatus.apps[index];
 
     // When |iccStatus.cardState| is not CARD_STATE_PRESENT or have incorrect
     // app information, we can not get iccId. So treat ICC as undetected.
@@ -4248,17 +4240,17 @@ RilObject.prototype = {
       this._isCdma = isCdma;
       this._waitingRadioTech = false;
       if (this._isCdma) {
         this.getDeviceIdentity();
       } else {
         this.getIMEI();
         this.getIMEISV();
       }
-      this.getICCStatus();
+       this.getICCStatus();
     }
   },
 
   /**
    * Helper for returning the TOA for the given dial string.
    */
   _toaFromString: function(number) {
     let toa = TOA_UNKNOWN;
@@ -6170,17 +6162,17 @@ RilObject.prototype[REQUEST_CDMA_SUBSCRI
   }
 
   let result = this.context.Buf.readStringList();
 
   this.iccInfo.mdn = result[0];
   // The result[1] is Home SID. (Already be handled in readCDMAHome())
   // The result[2] is Home NID. (Already be handled in readCDMAHome())
   // The result[3] is MIN.
-  this.iccInfo.prlVersion = parseInt(result[4], 10);
+  // The result[4] is PRL version.
 
   this.context.ICCUtilsHelper.handleICCInfoChange();
 };
 RilObject.prototype[REQUEST_CDMA_WRITE_SMS_TO_RUIM] = null;
 RilObject.prototype[REQUEST_CDMA_DELETE_SMS_ON_RUIM] = null;
 RilObject.prototype[REQUEST_DEVICE_IDENTITY] = function REQUEST_DEVICE_IDENTITY(length, options) {
   if (options.rilRequestError) {
     return;
@@ -6565,24 +6557,16 @@ RilObject.prototype[UNSOLICITED_CDMA_OTA
 RilObject.prototype[UNSOLICITED_CDMA_INFO_REC] = function UNSOLICITED_CDMA_INFO_REC(length) {
   let record = this.context.CdmaPDUHelper.decodeInformationRecord();
   record.rilMessageType = "cdma-info-rec-received";
   this.sendChromeMessage(record);
 };
 RilObject.prototype[UNSOLICITED_OEM_HOOK_RAW] = null;
 RilObject.prototype[UNSOLICITED_RINGBACK_TONE] = null;
 RilObject.prototype[UNSOLICITED_RESEND_INCALL_MUTE] = null;
-RilObject.prototype[UNSOLICITED_CDMA_SUBSCRIPTION_SOURCE_CHANGED] = null;
-RilObject.prototype[UNSOLICITED_CDMA_PRL_CHANGED] = function UNSOLICITED_CDMA_PRL_CHANGED(length) {
-  let version = this.context.Buf.readInt32List()[0];
-  if (version !== this.iccInfo.prlVersion) {
-    this.iccInfo.prlVersion = version;
-    this.context.ICCUtilsHelper.handleICCInfoChange();
-  }
-};
 RilObject.prototype[UNSOLICITED_EXIT_EMERGENCY_CALLBACK_MODE] = function UNSOLICITED_EXIT_EMERGENCY_CALLBACK_MODE() {
   this._handleChangedEmergencyCbMode(false);
 };
 RilObject.prototype[UNSOLICITED_RIL_CONNECTED] = function UNSOLICITED_RIL_CONNECTED(length) {
   // Prevent response id collision between UNSOLICITED_RIL_CONNECTED and
   // UNSOLICITED_VOICE_RADIO_TECH_CHANGED for Akami on gingerbread branch.
   if (!length) {
     return;