Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 17213580 authored by Nazanin Bakhshi's avatar Nazanin Bakhshi Committed by android-build-merger
Browse files

Merge "Add more logging around switchMultiSimConfig for better debugging" am: 440ee1da

am: 8eeebba5

Change-Id: Idea71844e61ce8173e761961cd3a7291bffe6c51
parents 9a049b8f 8eeebba5
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -162,12 +162,14 @@ public class PhoneConfigurationManager {
     * @param numOfSims number of active sims we want to switch to
     */
    public void switchMultiSimConfig(int numOfSims) {
        log("switchMultiSimConfig: with numOfSims = " + numOfSims);
        if (getStaticPhoneCapability().logicalModemList.size() < numOfSims) {
            log("switchMultiSimConfig: Phone is not capable of enabling "
                    + numOfSims + " sims, exiting!");
            return;
        }
        if (getNumOfActiveSims() != numOfSims) {
        if (getPhoneCount() != numOfSims) {
            log("switchMultiSimConfig: sending the request for switching");
            Message callback = Message.obtain(
                    mHandler, EVENT_SWITCH_DSDS_CONFIG_DONE, numOfSims, 0 /**dummy arg*/);
            mRadioConfig.setModemsConfig(numOfSims, callback);
@@ -206,6 +208,7 @@ public class PhoneConfigurationManager {
    public boolean isRebootRequiredForModemConfigChange() {
        String rebootRequired = SystemProperties.get(
                TelephonyProperties.PROPERTY_REBOOT_REQUIRED_ON_MODEM_CHANGE);
        log("isRebootRequiredForModemConfigChange: isRebootRequired = " + rebootRequired);
        return !rebootRequired.equals("false");
    }

@@ -234,6 +237,9 @@ public class PhoneConfigurationManager {
                    + finalMultiSimConfig);
            PowerManager pm = (PowerManager) mContext.getSystemService(Context.POWER_SERVICE);
            pm.reboot("Switching to " + finalMultiSimConfig);
        } else {
            log("setMultiSimProperties: Rebooting is not required to switch multi-sim config to "
                    + finalMultiSimConfig);
        }
    }

+1 −1
Original line number Diff line number Diff line
@@ -419,7 +419,7 @@ public class RadioConfig extends Handler {

            if (DBG) {
                logd(rr.serialString() + "> " + requestToString(rr.mRequest)
                        + "numOfLiveModems = " + numOfLiveModems);
                        + ", numOfLiveModems = " + numOfLiveModems);
            }

            try {