Check system and phone process in a multiple-user-aware way

This CL calls UserHandle.isSameApp to make sure the UID check with
Process.SYSTEM_UID and PHONE_UID are multiple-user-aware.

The logic to directly compare UID with PROCESS_XXX_UID only works for
system user. For secondary users, system/phone processes may run with UID
prefixed with user id.

Bug: 328511085
Test: atest framewoksTelephonyTests
Flag: com.android.internal.telephony.flags.support_phone_uid_check_for_multiuser
Change-Id: If3144179d7986c2a322a43459c22e0435fbaf4d0
diff --git a/src/com/android/phone/PhoneInterfaceManager.java b/src/com/android/phone/PhoneInterfaceManager.java
index 07b027e..97b6a5a 100644
--- a/src/com/android/phone/PhoneInterfaceManager.java
+++ b/src/com/android/phone/PhoneInterfaceManager.java
@@ -12296,7 +12296,7 @@
 
     private static void validateSignalStrengthUpdateRequest(Context context,
             SignalStrengthUpdateRequest request, int callingUid) {
-        if (callingUid == Process.PHONE_UID || callingUid == Process.SYSTEM_UID) {
+        if (TelephonyPermissions.isSystemOrPhone(callingUid)) {
             // phone/system process do not have further restriction on request
             return;
         }