From dc3e07d8155cc40804e7b033f06a548d05d2f347 Mon Sep 17 00:00:00 2001 From: Roshan Pius Date: Thu, 9 Jan 2020 06:02:38 -0800 Subject: [PATCH 1/2] Process: Make WIFI_UID a public API constant The Process.WIFI_UID constant is referenced by the wifi mainline module & hence needs to be a formal API constant. There are some other subsystem uid's like PHONE_UID which are already public constants, so there is precedence for making these uid's public if necessary? Bug: 147396785 Test: Compiles Change-Id: I85008965f9017e208c501c5a349f7e60cc102e0f --- api/current.txt | 1 + core/java/android/os/Process.java | 5 ++--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/api/current.txt b/api/current.txt index b673df0b5c90a..a182867ad4c22 100644 --- a/api/current.txt +++ b/api/current.txt @@ -35827,6 +35827,7 @@ package android.os { field public static final int THREAD_PRIORITY_URGENT_AUDIO = -19; // 0xffffffed field public static final int THREAD_PRIORITY_URGENT_DISPLAY = -8; // 0xfffffff8 field public static final int THREAD_PRIORITY_VIDEO = -10; // 0xfffffff6 + field public static final int WIFI_UID = 1010; // 0x3f2 } public abstract class ProxyFileDescriptorCallback { diff --git a/core/java/android/os/Process.java b/core/java/android/os/Process.java index 3ef86ed9f994e..5d0885a7ef55e 100644 --- a/core/java/android/os/Process.java +++ b/core/java/android/os/Process.java @@ -68,10 +68,9 @@ public class Process { public static final int LOG_UID = 1007; /** - * Defines the UID/GID for the WIFI supplicant process. - * @hide + * Defines the UID/GID for the WIFI native processes like wificond, supplicant, hostapd, + * vendor HAL, etc. */ - @UnsupportedAppUsage public static final int WIFI_UID = 1010; /** From 39624ff39b4690dec44c9cc2e018ff53b74aa9fc Mon Sep 17 00:00:00 2001 From: Roshan Pius Date: Thu, 9 Jan 2020 06:30:56 -0800 Subject: [PATCH 2/2] Promote RADIO_SCAN_WITHOUT_LOCATION permission to @SystemApi This is used by the wifi mainline module & hence needs to be a formal API constant. Bug: 147396785 Test: Compiles Change-Id: I018bf6be1d1c33031d1cb24aa5ff36ee473c4602 --- api/system-current.txt | 1 + core/res/AndroidManifest.xml | 1 + 2 files changed, 2 insertions(+) diff --git a/api/system-current.txt b/api/system-current.txt index 384dc13ff567c..f41384c512a68 100755 --- a/api/system-current.txt +++ b/api/system-current.txt @@ -152,6 +152,7 @@ package android { field public static final String PROVIDE_RESOLVER_RANKER_SERVICE = "android.permission.PROVIDE_RESOLVER_RANKER_SERVICE"; field public static final String PROVIDE_TRUST_AGENT = "android.permission.PROVIDE_TRUST_AGENT"; field public static final String QUERY_TIME_ZONE_RULES = "android.permission.QUERY_TIME_ZONE_RULES"; + field public static final String RADIO_SCAN_WITHOUT_LOCATION = "android.permission.RADIO_SCAN_WITHOUT_LOCATION"; field public static final String READ_ACTIVE_EMERGENCY_SESSION = "android.permission.READ_ACTIVE_EMERGENCY_SESSION"; field public static final String READ_CELL_BROADCASTS = "android.permission.READ_CELL_BROADCASTS"; field public static final String READ_CONTENT_RATING_SYSTEMS = "android.permission.READ_CONTENT_RATING_SYSTEMS"; diff --git a/core/res/AndroidManifest.xml b/core/res/AndroidManifest.xml index a808ed8fcc811..eba30bad68119 100644 --- a/core/res/AndroidManifest.xml +++ b/core/res/AndroidManifest.xml @@ -1655,6 +1655,7 @@