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

Commit 0025fc32 authored by Nathan Harold's avatar Nathan Harold Committed by android-build-merger
Browse files

Merge "Expose the Radio HAL Version for Test Purposes" am: a6dda25a

am: 225ef93d

Change-Id: Ie4b60e4ba25b69eaef298887ca803b428620e33d
parents 0a9b8512 225ef93d
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1479,6 +1479,7 @@ package android.telephony {

  public class TelephonyManager {
    method public int getCarrierIdListVersion();
    method public android.util.Pair<java.lang.Integer,java.lang.Integer> getRadioHalVersion();
    method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void refreshUiccProfile();
    method public void setCarrierTestOverride(String, String, String, String, String, String, String);
    field public static final int UNKNOWN_CARRIER_ID_LIST_VERSION = -1; // 0xffffffff
+24 −0
Original line number Diff line number Diff line
@@ -10326,4 +10326,28 @@ public class TelephonyManager {
        }
        return false;
    }

    /**
     * Retrieve the Radio HAL Version for this device.
     *
     * Get the HAL version for the IRadio interface for test purposes.
     *
     * @return a Pair of (major version, minor version) or (-1,-1) if unknown.
     *
     * @hide
     */
    @TestApi
    public Pair<Integer, Integer> getRadioHalVersion() {
        try {
            ITelephony service = getITelephony();
            if (service != null) {
                int version = service.getRadioHalVersion();
                if (version == -1) return new Pair<Integer, Integer>(-1, -1);
                return new Pair<Integer, Integer>(version / 100, version % 100);
            }
        } catch (RemoteException e) {
            Log.e(TAG, "getRadioHalVersion() RemoteException", e);
        }
        return new Pair<Integer, Integer>(-1, -1);
    }
}
+5 −0
Original line number Diff line number Diff line
@@ -1855,4 +1855,9 @@ interface ITelephony {
     * Get the mapping from logical slots to physical slots.
     */
    int[] getSlotsMapping();

    /**
     * Get the IRadio HAL Version encoded as 100 * MAJOR_VERSION + MINOR_VERSION or -1 if unknown
     */
     int getRadioHalVersion();
}