/frameworks/base/core/tests/coretests/src/android/os/ |
D | ProcessTest.java | 29 @IgnoreUnderRavenwood(blockedBy = Process.class) 38 assertEquals(android.os.Process.SYSTEM_UID, Process.getUidForName("system")); in testProcessGetUidFromName() 39 assertEquals(Process.BLUETOOTH_UID, Process.getUidForName("bluetooth")); in testProcessGetUidFromName() 40 assertEquals(Process.FIRST_APPLICATION_UID, Process.getUidForName("u0_a0")); in testProcessGetUidFromName() 41 assertEquals(UserHandle.getUid(1, Process.SYSTEM_UID), Process.getUidForName("u1_system")); in testProcessGetUidFromName() 42 assertEquals(UserHandle.getUid(2, Process.FIRST_APP_ZYGOTE_ISOLATED_UID), in testProcessGetUidFromName() 43 Process.getUidForName("u2_i0")); in testProcessGetUidFromName() 44 assertEquals(UserHandle.getUid(2, Process.FIRST_ISOLATED_UID), in testProcessGetUidFromName() 45 Process.getUidForName("u2_i9000")); in testProcessGetUidFromName() 46 assertEquals(UserHandle.getUid(3, Process.FIRST_APPLICATION_UID + 100), in testProcessGetUidFromName() [all …]
|
D | BinderThreadPriorityTest.java | 97 mSavedPriority = Process.getThreadPriority(Process.myTid()); in setUp() 98 Process.setThreadPriority(mSavedPriority); // To realign priority & cgroup, if needed in setUp() 107 Process.setThreadPriority(Process.THREAD_PRIORITY_BACKGROUND); in tearDown() 108 Process.setThreadPriority(mSavedPriority); in tearDown() 109 assertEquals(mSavedPriority, Process.getThreadPriority(Process.myTid())); in tearDown() 116 String fn = "/proc/" + Process.myPid() + "/task/" + Process.myTid() + "/cgroup"; in getSchedulerGroup() 136 Process.setThreadPriority(prio); in testPassPriorityToService() 139 assertEquals(prio, Process.getThreadPriority(Process.myTid())); in testPassPriorityToService() 154 assertEquals(expected, Process.getThreadPriority(Process.myTid())); in testCallBackFromServiceWithPriority() 159 assertEquals(mSavedPriority, Process.getThreadPriority(Process.myTid())); in testCallBackFromServiceWithPriority()
|
D | SetPersistentVrThreadTest.java | 94 vr_thread = Process.myTid(); in testSetPersistentVrThreadAPISuccess() 98 policy = (int) Process.getThreadScheduler(vr_thread); in testSetPersistentVrThreadAPISuccess() 103 policy = (int) Process.getThreadScheduler(vr_thread); in testSetPersistentVrThreadAPISuccess() 113 policy = (int) Process.getThreadScheduler(vr_thread); in testSetPersistentVrThreadAPISuccess() 119 policy = (int) Process.getThreadScheduler(vr_thread); in testSetPersistentVrThreadAPISuccess() 130 vr_thread = Process.myTid(); in testSetPersistentVrThreadAPIFailure() 132 policy = (int) Process.getThreadScheduler(vr_thread); in testSetPersistentVrThreadAPIFailure() 144 vr_thread = Process.myTid(); in testSetVrThreadAPIFailsInPersistentMode() 148 policy = (int) Process.getThreadScheduler(vr_thread); in testSetVrThreadAPIFailsInPersistentMode() 155 policy = (int) Process.getThreadScheduler(vr_thread); in testSetVrThreadAPIFailsInPersistentMode() [all …]
|
/frameworks/base/services/core/java/com/android/server/os/ |
D | SchedulingPolicyService.java | 23 import android.os.Process; 70 int[] nativePids = Process.getPidsForCommands(MEDIA_PROCESS_NAMES); in SchedulingPolicyService() 92 prio > PRIORITY_MAX || Process.getThreadGroupLeader(tid) != pid) { in requestPriority() 97 if (Binder.getCallingUid() == Process.AUDIOSERVER_UID && !isForApp in requestPriority() 98 && Process.getUidForPid(tid) != Process.AUDIOSERVER_UID) { in requestPriority() 101 if (Binder.getCallingUid() != Process.BLUETOOTH_UID) { in requestPriority() 104 Process.setThreadGroup(tid, !isForApp ? in requestPriority() 105 Process.THREAD_GROUP_AUDIO_SYS : Process.THREAD_GROUP_RT_APP); in requestPriority() 113 Process.setThreadScheduler(tid, Process.SCHED_FIFO | Process.SCHED_RESET_ON_FORK, in requestPriority() 125 if (Binder.getCallingPid() != Process.myPid() && in requestCpusetBoost() [all …]
|
/frameworks/base/services/core/java/com/android/server/power/stats/ |
D | KernelWakelockReader.java | 18 import android.os.Process; 46 Process.PROC_TAB_TERM | Process.PROC_OUT_STRING // 0: name 47 | Process.PROC_QUOTES, 48 Process.PROC_TAB_TERM | Process.PROC_OUT_LONG, // 1: count 49 Process.PROC_TAB_TERM, 50 Process.PROC_TAB_TERM | Process.PROC_OUT_LONG, // 3: activeSince 51 Process.PROC_TAB_TERM, 52 Process.PROC_TAB_TERM | Process.PROC_OUT_LONG, // 5: totalTime 56 Process.PROC_TAB_TERM | Process.PROC_OUT_STRING, // 0: name 57 Process.PROC_TAB_TERM | Process.PROC_COMBINE [all …]
|
/frameworks/base/cmds/incident_helper/src/parsers/ |
D | PsParser.cpp | 36 …Table table(PsProto::Process::_FIELD_NAMES, PsProto::Process::_FIELD_IDS, PsProto::Process::_FIELD… in Parse() 38 …const int pcyValues[] = {PsProto::Process::POLICY_FG, PsProto::Process::POLICY_BG, PsProto::Proces… in Parse() 41 …Process::STATE_D, PsProto::Process::STATE_R, PsProto::Process::STATE_S, PsProto::Process::STATE_T,… in Parse()
|
/frameworks/base/services/core/java/com/android/server/pm/ |
D | AppIdSettingMap.java | 19 import android.os.Process; 42 private int mFirstAvailableAppId = Process.FIRST_APPLICATION_UID; 62 if (appId >= Process.FIRST_APPLICATION_UID) { in registerExistingAppId() 64 final int index = appId - Process.FIRST_APPLICATION_UID; in registerExistingAppId() 90 if (appId >= Process.FIRST_APPLICATION_UID) { in getSetting() 92 final int index = appId - Process.FIRST_APPLICATION_UID; in getSetting() 100 if (appId >= Process.FIRST_APPLICATION_UID) { in removeSetting() 102 final int index = appId - Process.FIRST_APPLICATION_UID; in removeSetting() 120 if (appId >= Process.FIRST_APPLICATION_UID) { in replaceSetting() 122 final int index = appId - Process.FIRST_APPLICATION_UID; in replaceSetting() [all …]
|
/frameworks/base/core/java/com/android/internal/os/ |
D | ProcTimeInStateReader.java | 20 import android.os.Process; 67 Process.PROC_OUT_LONG | Process.PROC_SPACE_TERM, 68 Process.PROC_NEWLINE_TERM 75 Process.PROC_SPACE_TERM, 76 Process.PROC_OUT_LONG | Process.PROC_NEWLINE_TERM 83 Process.PROC_NEWLINE_TERM 120 final boolean readSuccess = Process.readProcFile( in getUsageTimesMillis() 191 final boolean readSuccess = Process.parseProcLine( in initializeTimeInStateFormat()
|
/frameworks/base/core/java/android/os/ |
D | UserHandle.java | 181 public static final int AID_ROOT = android.os.Process.ROOT_UID; 184 public static final int AID_APP_START = android.os.Process.FIRST_APPLICATION_UID; 187 public static final int AID_APP_END = android.os.Process.LAST_APPLICATION_UID; 190 public static final int AID_SHARED_GID_START = android.os.Process.FIRST_SHARED_APPLICATION_GID; 193 public static final int AID_CACHE_GID_START = android.os.Process.FIRST_APPLICATION_CACHE_GID; 228 return Process.isIsolated(uid); in isIsolated() 244 return appId >= Process.FIRST_APPLICATION_UID && appId <= Process.LAST_APPLICATION_UID; in isApp() 257 return appId < Process.FIRST_APPLICATION_UID; in isCore() 410 return getUid(userId, Process.SHARED_USER_GID); in getUserGid() 440 final int appId = getAppId(gid) + Process.FIRST_APPLICATION_UID in getAppIdFromSharedAppGid() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/ |
D | ThreadPriorityBoosterTest.java | 19 import static android.os.Process.getThreadPriority; 20 import static android.os.Process.myTid; 21 import static android.os.Process.setThreadPriority; 25 import android.os.Process; 40 private static final int PRIORITY_BOOST = Process.THREAD_PRIORITY_FOREGROUND; 41 private static final int PRIORITY_BOOST_MORE = Process.THREAD_PRIORITY_DISPLAY; 49 final int origPriority = Process.THREAD_PRIORITY_DEFAULT; in testThreadPriorityBooster()
|
/frameworks/base/services/core/java/com/android/server/am/ |
D | PhantomProcessRecord.java | 19 import static android.os.Process.PROC_NEWLINE_TERM; 20 import static android.os.Process.PROC_OUT_LONG; 26 import android.os.Process; 87 if (Process.supportsPidFd()) { in PhantomProcessRecord() 90 mPidFd = Process.openPidFd(pid, 0); in PhantomProcessRecord() 109 long[] rss = Process.getRss(pid); in getRss() 124 if (!Process.supportsPidFd()) { in killLocked() 132 Process.killProcessQuiet(mPid); in killLocked() 157 if (Process.readProcFile("/proc/" + mPid + "/oom_score_adj", in updateAdjLocked() 189 if (mUid < Process.FIRST_APPLICATION_UID) { in toString() [all …]
|
D | AccessCheckDelegateHelper.java | 20 import android.os.Process; 73 if (UserHandle.getCallingAppId() != Process.SHELL_UID in startDelegateShellPermissionIdentity() 74 && UserHandle.getCallingAppId() != Process.ROOT_UID) { in startDelegateShellPermissionIdentity() 107 if (UserHandle.getCallingAppId() != Process.SHELL_UID in stopDelegateShellPermissionIdentity() 108 && UserHandle.getCallingAppId() != Process.ROOT_UID) { in stopDelegateShellPermissionIdentity() 130 if (UserHandle.getCallingAppId() != Process.SHELL_UID in getDelegatedShellPermissions() 131 && UserHandle.getCallingAppId() != Process.ROOT_UID) { in getDelegatedShellPermissions() 145 if (UserHandle.getCallingAppId() != Process.ROOT_UID) { in addOverridePermissionState() 158 if (instr.mSourceUid != Process.ROOT_UID || instr.mUiAutomationConnection == null) { in addOverridePermissionState() 178 if (UserHandle.getCallingAppId() != Process.ROOT_UID) { in removeOverridePermissionState() [all …]
|
/frameworks/base/cmds/incident_helper/tests/ |
D | PsParser_test.cpp | 58 PsProto::Process* record1 = expected.add_processes(); in TEST_F() 73 record1->set_pcy(PsProto::Process::POLICY_FG); in TEST_F() 77 PsProto::Process* record2 = expected.add_processes(); in TEST_F() 92 record2->set_pcy(PsProto::Process::POLICY_FG); in TEST_F() 96 PsProto::Process* record3 = expected.add_processes(); in TEST_F() 111 record3->set_pcy(PsProto::Process::POLICY_FG); in TEST_F() 115 PsProto::Process* record4 = expected.add_processes(); in TEST_F() 130 record4->set_pcy(PsProto::Process::POLICY_FG); in TEST_F() 134 PsProto::Process* record5 = expected.add_processes(); in TEST_F() 149 record5->set_pcy(PsProto::Process::POLICY_TA); in TEST_F() [all …]
|
D | ProcrankParser_test.cpp | 57 ProcrankProto::Process* process1 = expected.add_processes(); in TEST_F() 69 ProcrankProto::Process* process2 = expected.add_processes(); in TEST_F() 81 ProcrankProto::Process* total = expected.mutable_summary()->mutable_total(); in TEST_F() 109 ProcrankProto::Process* process1 = expected.add_processes(); in TEST_F() 117 ProcrankProto::Process* process2 = expected.add_processes(); in TEST_F() 125 ProcrankProto::Process* total = expected.mutable_summary()->mutable_total(); in TEST_F()
|
/frameworks/base/services/tests/uiservicestests/src/com/android/server/slice/ |
D | SliceManagerServiceTest.java | 40 import android.os.Process; 124 when(mContextSpy.checkPermission("perm1", Process.myPid(), Process.myUid())) in testCheckAutoGrantPermissions() 126 when(mContextSpy.checkPermission("perm2", Process.myPid(), Process.myUid())) in testCheckAutoGrantPermissions() 129 Process.myPid(), Process.myUid(), testPerms); in testCheckAutoGrantPermissions() 131 verify(mContextSpy).checkPermission(eq("perm1"), eq(Process.myPid()), eq(Process.myUid())); in testCheckAutoGrantPermissions() 132 verify(mContextSpy).checkPermission(eq("perm2"), eq(Process.myPid()), eq(Process.myUid())); in testCheckAutoGrantPermissions()
|
/frameworks/base/services/core/java/com/android/server/ |
D | UiThread.java | 21 import android.os.Process; 38 super("android.ui", Process.THREAD_PRIORITY_FOREGROUND, false /*allowIo*/); in UiThread() 44 Process.setThreadGroup(Process.myTid(), Process.THREAD_GROUP_TOP_APP); in run()
|
/frameworks/base/services/core/java/com/android/server/stats/pull/ |
D | ProcfsMemoryUtil.java | 18 import static android.os.Process.PROC_OUT_STRING; 21 import android.os.Process; 51 Process.readProcLines("/proc/" + pid + "/status", STATUS_KEYS, output); in readMemorySnapshotFromProcfs() 74 if (!Process.readProcFile("/proc/" + pid + "/cmdline", CMDLINE_OUT, cmdline, null, null)) { in readCmdlineFromProcfs() 85 pids = Process.getPids("/proc", pids); in getProcessCmdlines() 115 Process.readProcLines("/proc/vmstat", VMSTAT_KEYS, vmstat); in readVmStat()
|
/frameworks/base/core/java/android/service/textservice/ |
D | SpellCheckerService.java | 23 import android.os.Process; 270 int pri = Process.getThreadPriority(Process.myTid()); in onGetSuggestionsMultiple() 272 Process.setThreadPriority(Process.THREAD_PRIORITY_BACKGROUND); in onGetSuggestionsMultiple() 278 Process.setThreadPriority(pri); in onGetSuggestionsMultiple() 293 int pri = Process.getThreadPriority(Process.myTid()); in onCancel() 295 Process.setThreadPriority(Process.THREAD_PRIORITY_BACKGROUND); in onCancel() 298 Process.setThreadPriority(pri); in onCancel() 304 int pri = Process.getThreadPriority(Process.myTid()); in onClose() 306 Process.setThreadPriority(Process.THREAD_PRIORITY_BACKGROUND); in onClose() 309 Process.setThreadPriority(pri); in onClose()
|
/frameworks/base/core/java/android/webkit/ |
D | WebViewZygote.java | 24 import android.os.Process; 124 Process.killProcess(sZygote.getPid()); in stopZygoteLocked() 144 sZygote = Process.ZYGOTE_PROCESS.startChildZygote( in connectToZygoteIfNeededLocked() 147 Process.WEBVIEW_ZYGOTE_UID, in connectToZygoteIfNeededLocked() 148 Process.WEBVIEW_ZYGOTE_UID, in connectToZygoteIfNeededLocked() 155 Process.FIRST_ISOLATED_UID, in connectToZygoteIfNeededLocked()
|
/frameworks/base/services/core/java/com/android/server/pm/verify/domain/ |
D | DomainVerificationEnforcer.java | 26 import android.os.Process; 51 case Process.ROOT_UID: in assertInternal() 52 case Process.SHELL_UID: in assertInternal() 53 case Process.SYSTEM_UID: in assertInternal() 67 case Process.ROOT_UID: in assertApprovedQuerent() 68 case Process.SHELL_UID: in assertApprovedQuerent() 69 case Process.SYSTEM_UID: in assertApprovedQuerent() 95 case Process.ROOT_UID: in assertApprovedVerifier() 96 case Process.SHELL_UID: in assertApprovedVerifier() 97 case Process.SYSTEM_UID: in assertApprovedVerifier()
|
/frameworks/base/services/tests/servicestests/src/com/android/server/appop/ |
D | AppOpsNotedWatcherTest.java | 33 import android.os.Process; 68 appOpsManager.noteOp(AppOpsManager.OP_FINE_LOCATION, Process.myUid(), in testWatchNotedOps() 70 appOpsManager.noteOp(AppOpsManager.OP_CAMERA, Process.myUid(), in testWatchNotedOps() 77 eq(Process.myUid()), eq(getContext().getPackageName()), in testWatchNotedOps() 83 eq(Process.myUid()), eq(getContext().getPackageName()), in testWatchNotedOps() 103 appOpsManager.noteOp(AppOpsManager.OP_FINE_LOCATION, Process.myUid(), in testWatchNotedOps() 109 eq(Process.myUid()), eq(getContext().getPackageName()), in testWatchNotedOps() 132 AttributionSource attributionSource = new AttributionSource(Process.myUid(), in testWatchNotedOpsForExternalDevice() 144 eq(Process.myUid()), eq(getContext().getOpPackageName()), in testWatchNotedOpsForExternalDevice()
|
/frameworks/base/services/tests/powerstatstests/BstatsTestApp/src/com/android/coretests/apps/bstatstestapp/ |
D | IsolatedTestService.java | 21 import android.os.Process; 29 Log.d(TAG, "onCreate called. myUid=" + Process.myUid()); in onCreate() 34 Log.d(TAG, "onBind called. myUid=" + Process.myUid()); in onBind() 40 Log.d(TAG, "onDestroy called. myUid=" + Process.myUid()); in onDestroy()
|
/frameworks/base/services/tests/mockingservicestests/src/com/android/server/ |
D | AppStateTrackerTest.java | 59 import android.os.Process; 154 private static final int UID_1 = Process.FIRST_APPLICATION_UID + 1; 155 private static final int UID_2 = Process.FIRST_APPLICATION_UID + 2; 156 private static final int UID_3 = Process.FIRST_APPLICATION_UID + 3; 355 new int[] {UID_1, UID_2, UID_10_2, Process.SYSTEM_UID}, in testAll() 360 new int[] {UID_1, UID_2, UID_10_2, Process.SYSTEM_UID}, in testAll() 365 new int[] {UID_1, UID_2, UID_10_2, Process.SYSTEM_UID}, in testAll() 375 new int[] {UID_1, UID_2, UID_10_2, Process.SYSTEM_UID}, in testAll() 380 new int[] {UID_1, UID_2, UID_10_2, Process.SYSTEM_UID}, in testAll() 385 new int[] {UID_1, UID_2, UID_10_2, Process.SYSTEM_UID}, in testAll() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/pm/ |
D | ShortcutManagerTest7.java | 33 import android.os.Process; 96 mInjectedCallingUid = Process.SYSTEM_UID; in testNonShell() 106 mInjectedCallingUid = Process.ROOT_UID; in testRoot() 115 mInjectedCallingUid = Process.SHELL_UID; in testRestConfig() 124 mInjectedCallingUid = Process.SHELL_UID; in testOverrideConfig() 141 mInjectedCallingUid = Process.SHELL_UID; in testResetThrottling() 162 mInjectedCallingUid = Process.SHELL_UID; in testResetThrottling_user_not_running() 193 mInjectedCallingUid = Process.SHELL_UID; in testResetThrottling_user_running() 214 mInjectedCallingUid = Process.SHELL_UID; in testResetAllThrottling() 245 mInjectedCallingUid = Process.SHELL_UID; in testLauncherCommands() [all …]
|
/frameworks/base/services/tests/mockingservicestests/src/com/android/server/pm/ |
D | PackageManagerServiceBootTest.kt | 22 import android.os.Process in <lambda>() 74 Process.SYSTEM_UID, FLAG_SYSTEM, PRIVATE_FLAG_PRIVILEGED) in <lambda>() 76 Process.PHONE_UID, FLAG_SYSTEM, PRIVATE_FLAG_PRIVILEGED) in <lambda>() 78 Process.LOG_UID, FLAG_SYSTEM, PRIVATE_FLAG_PRIVILEGED) in <lambda>() 80 Process.NFC_UID, FLAG_SYSTEM, PRIVATE_FLAG_PRIVILEGED) in <lambda>() 82 Process.BLUETOOTH_UID, FLAG_SYSTEM, PRIVATE_FLAG_PRIVILEGED) in <lambda>() 84 Process.SHELL_UID, FLAG_SYSTEM, PRIVATE_FLAG_PRIVILEGED) in <lambda>() 86 Process.SE_UID, FLAG_SYSTEM, PRIVATE_FLAG_PRIVILEGED) in <lambda>() 88 Process.NETWORK_STACK_UID, FLAG_SYSTEM, PRIVATE_FLAG_PRIVILEGED) in <lambda>()
|