Merge cherrypicks of ['googleplex-android-review.googlesource.com/30882759'] into 25Q1-release.

Change-Id: Ie1b478c0939b63a8be9a3c17e53d9f968fd90fa3
diff --git a/src/java/com/android/internal/telephony/DisplayInfoController.java b/src/java/com/android/internal/telephony/DisplayInfoController.java
index bb19a31..57ea022 100644
--- a/src/java/com/android/internal/telephony/DisplayInfoController.java
+++ b/src/java/com/android/internal/telephony/DisplayInfoController.java
@@ -115,6 +115,13 @@
         // EVENT_UPDATE will transition from DefaultState to the current state
         // and update the TelephonyDisplayInfo based on the current state.
         mNetworkTypeController.sendMessage(NetworkTypeController.EVENT_UPDATE);
+
+        // To Support Satellite bandwidth constrained data capability status at telephony
+        // display info
+        if (mFeatureFlags.carrierEnabledSatelliteFlag()) {
+            log("register for satellite network callback");
+            mNetworkTypeController.registerForSatelliteNetwork();
+        }
     }
 
     /**
@@ -129,19 +136,23 @@
      * NetworkTypeController.
      */
     public void updateTelephonyDisplayInfo() {
-        TelephonyDisplayInfo newDisplayInfo = new TelephonyDisplayInfo(
-                mNetworkTypeController.getDataNetworkType(),
-                mNetworkTypeController.getOverrideNetworkType(),
-                isRoaming(),
-                mPhone.getServiceStateTracker().getServiceState().isUsingNonTerrestrialNetwork(),
-                mNetworkTypeController.getSatelliteConstrainedData());
-        if (!newDisplayInfo.equals(mTelephonyDisplayInfo)) {
-            logl("TelephonyDisplayInfo changed from " + mTelephonyDisplayInfo + " to "
-                    + newDisplayInfo);
-            validateDisplayInfo(newDisplayInfo);
-            mTelephonyDisplayInfo = newDisplayInfo;
-            mTelephonyDisplayInfoChangedRegistrants.notifyRegistrants();
-            mPhone.notifyDisplayInfoChanged(mTelephonyDisplayInfo);
+        if (mNetworkTypeController != null && mServiceState != null) {
+            TelephonyDisplayInfo newDisplayInfo = new TelephonyDisplayInfo(
+                    mNetworkTypeController.getDataNetworkType(),
+                    mNetworkTypeController.getOverrideNetworkType(),
+                    isRoaming(),
+                    mServiceState.isUsingNonTerrestrialNetwork(),
+                    mNetworkTypeController.getSatelliteConstrainedData());
+            if (!newDisplayInfo.equals(mTelephonyDisplayInfo)) {
+                logl("TelephonyDisplayInfo changed from " + mTelephonyDisplayInfo + " to "
+                        + newDisplayInfo);
+                validateDisplayInfo(newDisplayInfo);
+                mTelephonyDisplayInfo = newDisplayInfo;
+                mTelephonyDisplayInfoChangedRegistrants.notifyRegistrants();
+                mPhone.notifyDisplayInfoChanged(mTelephonyDisplayInfo);
+            }
+        } else {
+            loge("Found null object");
         }
     }
 
diff --git a/src/java/com/android/internal/telephony/NetworkTypeController.java b/src/java/com/android/internal/telephony/NetworkTypeController.java
index b12a3df..82e0c6e 100644
--- a/src/java/com/android/internal/telephony/NetworkTypeController.java
+++ b/src/java/com/android/internal/telephony/NetworkTypeController.java
@@ -338,10 +338,6 @@
         mServiceState = mPhone.getServiceStateTracker().getServiceState();
         mPhysicalChannelConfigs = mPhone.getServiceStateTracker().getPhysicalChannelConfigList();
 
-        if(mFeatureFlags.carrierEnabledSatelliteFlag()) {
-            registerForSatelliteNetwork();
-        }
-
         sendMessage(EVENT_INITIALIZE);
     }