From b822af0022ec109b954d01b5358b80d5ba58817e Mon Sep 17 00:00:00 2001 From: Nathan Harold Date: Tue, 15 Jan 2019 11:59:54 -0800 Subject: [PATCH] Remove LTE Rsrp Boost from SignalStrength The RSRP boost is no longer used in SignalStrength, and there are no major users of this value to justify keeping the value around even though there is no direct alternative. Thus, removing it from SignalStrength. Bug: 122846268 Test: compilation (code removal) Change-Id: I2d4409986a64aa13379e2894457d000ae43f92ca --- .../android/telephony/SignalStrength.java | 26 ++----------------- 1 file changed, 2 insertions(+), 24 deletions(-) diff --git a/telephony/java/android/telephony/SignalStrength.java b/telephony/java/android/telephony/SignalStrength.java index e77042d1930ff..ad3ca6d129c9f 100644 --- a/telephony/java/android/telephony/SignalStrength.java +++ b/telephony/java/android/telephony/SignalStrength.java @@ -86,11 +86,6 @@ public class SignalStrength implements Parcelable { CellSignalStrengthTdscdma mTdscdma; CellSignalStrengthLte mLte; - /** Parameters from the framework */ - @UnsupportedAppUsage - private int mLteRsrpBoost; // offset to be reduced from the rsrp threshold while calculating - // signal strength level - /** * Create a new SignalStrength from a intent notifier Bundle * @@ -140,7 +135,6 @@ public class SignalStrength implements Parcelable { mWcdma = wcdma; mTdscdma = tdscdma; mLte = lte; - mLteRsrpBoost = 0; } /** @@ -211,7 +205,6 @@ public class SignalStrength implements Parcelable { /** @hide */ public void updateLevel(PersistableBundle cc, ServiceState ss) { - mLteRsrpBoost = ss.getLteEarfcnRsrpBoost(); mCdma.updateLevel(cc, ss); mGsm.updateLevel(cc, ss); mWcdma.updateLevel(cc, ss); @@ -241,7 +234,6 @@ public class SignalStrength implements Parcelable { mWcdma = new CellSignalStrengthWcdma(s.mWcdma); mTdscdma = new CellSignalStrengthTdscdma(s.mTdscdma); mLte = new CellSignalStrengthLte(s.mLte); - mLteRsrpBoost = s.mLteRsrpBoost; } /** @@ -258,7 +250,6 @@ public class SignalStrength implements Parcelable { mWcdma = in.readParcelable(CellSignalStrengthWcdma.class.getClassLoader()); mTdscdma = in.readParcelable(CellSignalStrengthTdscdma.class.getClassLoader()); mLte = in.readParcelable(CellSignalStrengthLte.class.getClassLoader()); - mLteRsrpBoost = in.readInt(); } /** @@ -270,8 +261,6 @@ public class SignalStrength implements Parcelable { out.writeParcelable(mWcdma, flags); out.writeParcelable(mTdscdma, flags); out.writeParcelable(mLte, flags); - - out.writeInt(mLteRsrpBoost); } /** @@ -384,11 +373,6 @@ public class SignalStrength implements Parcelable { return mLte.getCqi(); } - /** @hide */ - public int getLteRsrpBoost() { - return mLteRsrpBoost; - } - /** * Retrieve an abstract level value for the overall signal strength. * @@ -616,7 +600,7 @@ public class SignalStrength implements Parcelable { */ @Override public int hashCode() { - return Objects.hash(mCdma, mGsm, mWcdma, mTdscdma, mLte, mLteRsrpBoost); + return Objects.hash(mCdma, mGsm, mWcdma, mTdscdma, mLte); } /** @@ -632,8 +616,7 @@ public class SignalStrength implements Parcelable { && mGsm.equals(s.mGsm) && mWcdma.equals(s.mWcdma) && mTdscdma.equals(s.mTdscdma) - && mLte.equals(s.mLte) - && mLteRsrpBoost == s.mLteRsrpBoost; + && mLte.equals(s.mLte); } /** @@ -647,7 +630,6 @@ public class SignalStrength implements Parcelable { .append(",mWcdma=").append(mWcdma) .append(",mTdscdma=").append(mTdscdma) .append(",mLte=").append(mLte) - .append(",mLteRsrpBoost=").append(mLteRsrpBoost) .append(",primary=").append(getPrimary().getClass().getSimpleName()) .append("}") .toString(); @@ -666,8 +648,6 @@ public class SignalStrength implements Parcelable { mWcdma = m.getParcelable("Wcdma"); mTdscdma = m.getParcelable("Tdscdma"); mLte = m.getParcelable("Lte"); - - mLteRsrpBoost = m.getInt("LteRsrpBoost"); } /** @@ -683,8 +663,6 @@ public class SignalStrength implements Parcelable { m.putParcelable("Wcdma", mWcdma); m.putParcelable("Tdscdma", mTdscdma); m.putParcelable("Lte", mLte); - - m.putInt("LteRsrpBoost", mLteRsrpBoost); } /**