/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/nanosleep/ |
H A D | 7-2.c | 34 int pid; in main() local 42 if ((pid = fork()) == 0) { in main() 87 if (kill(pid, SIGABRT) != 0) { in main()
|
H A D | 1-3.c | 28 int pid; in main() local 36 if ((pid = fork()) == 0) { in main() 58 if (kill(pid, SIGABRT) != 0) { in main()
|
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/sigwaitinfo/ |
H A D | 8-1.c | 43 int pid, i; in main() local 54 pid = getpid(); in main() 60 if (sigqueue(pid, SIGTOTEST, value) != 0) { in main()
|
H A D | 7-1.c | 44 int pid, i; in main() local 55 pid = getpid(); in main() 61 if (sigqueue(pid, SIGTOTEST, value) != 0) { in main()
|
/third_party/ltp/testcases/open_posix_testsuite/functional/semaphores/ |
H A D | sem_lock.c | 32 pid_t pid = 0; in main() local 55 switch ((pid = fork())) { in main() 68 (long)getppid(), (long)pid); in main()
|
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/sigqueue/ |
H A D | 7-1.c | 48 int pid, rtsig; in main() local 65 pid = getpid(); in main() 70 if (sigqueue(pid, rtsig, value) != 0) { in main()
|
/third_party/pulseaudio/src/pulsecore/ |
H A D | start-child.c | 45 int pa_start_child_for_read(const char *name, const char *argv1, pid_t *pid) { in pa_start_child_for_read() argument 64 if (pid) in pa_start_child_for_read() 65 *pid = child; in pa_start_child_for_read()
|
/third_party/toybox/toys/posix/ |
H A D | time.c | 29 pid_t pid; in time_main() local 33 if (!(pid = XVFORK())) xexec(toys.optargs); in time_main() 39 wait4(pid, &stat, 0, &ru); in time_main()
|
/third_party/rust/crates/rustix/src/backend/libc/termios/ |
H A D | syscalls.rs | 33 let pid = ret_pid_t(c::tcgetpgrp(borrowed_fd(fd)))?; 34 debug_assert_ne!(pid, 0); 35 Ok(Pid::from_raw_nonzero(RawNonZeroPid::new_unchecked(pid))) 40 pub(crate) fn tcsetpgrp(fd: BorrowedFd<'_>, pid: Pid) -> io::Result<()> { 41 unsafe { ret(c::tcsetpgrp(borrowed_fd(fd), pid.as_raw_nonzero().get())) } 82 let pid = ret_pid_t(c::tcgetsid(borrowed_fd(fd)))?; 83 debug_assert_ne!(pid, 0); 84 Ok(Pid::from_raw_nonzero(RawNonZeroPid::new_unchecked(pid)))
|
/foundation/communication/wifi/wifi/services/wifi_standard/wifi_framework/wifi_manage/wifi_common/ |
H A D | wifi_internal_event_dispatcher.cpp | 133 const sptr<IRemoteObject> &remote, const sptr<IWifiDeviceCallBack> &callback, int pid, in AddStaCallback() 166 callbackInfo.callingPid = pid; in AddStaCallback() 170 WIFI_LOGD("%{public}s, add uid: %{public}d, pid: %{public}d, callback event:%{public}d," in AddStaCallback() 182 callbackInfo.callingPid = pid; in AddStaCallback() 238 const sptr<IRemoteObject> &remote, const sptr<IWifiScanCallback> &callback, int pid, in AddScanCallback() 271 callbackInfo.callingPid = pid; in AddScanCallback() 275 WIFI_LOGD("%{public}s, add uid: %{public}d, pid: %{public}d, callback event:%{public}d," in AddScanCallback() 287 callbackInfo.callingPid = pid; in AddScanCallback() 456 const sptr<IRemoteObject> &remote, const sptr<IWifiP2pCallback> &callback, int pid, in AddP2pCallback() 483 callbackInfo.callingPid = pid; in AddP2pCallback() 132 AddStaCallback( const sptr<IRemoteObject> &remote, const sptr<IWifiDeviceCallBack> &callback, int pid, const std::string &eventName, int tokenId, int instId) AddStaCallback() argument 237 AddScanCallback( const sptr<IRemoteObject> &remote, const sptr<IWifiScanCallback> &callback, int pid, const std::string &eventName, int tokenId, int instId) AddScanCallback() argument 455 AddP2pCallback( const sptr<IRemoteObject> &remote, const sptr<IWifiP2pCallback> &callback, int pid, const std::string &eventName, int tokenId) AddP2pCallback() argument 659 int pid = mScanCallBackInfo[msg.id][remote].callingPid; InvokeScanCallbacks() local 702 int pid = mStaCallBackInfo[msg.id][remote].callingPid; InvokeDeviceCallbacks() local 816 int pid = mP2pCallbackInfo[remote].callingPid; InvokeP2pCallbacks() local 866 SendP2pCallbackMsg(sptr<IWifiP2pCallback> &callback, const WifiEventCallbackMsg &msg, int pid, int uid, int tokenId) SendP2pCallbackMsg() argument 1065 IsAppFrozen(int pid) IsAppFrozen() argument [all...] |
/kernel/linux/linux-5.10/kernel/ |
H A D | fork.c | 1165 * This changes mm's executable file (shown as symlink /proc/[pid]/exe). 1699 init_task_pid(struct task_struct *task, enum pid_type type, struct pid *pid) in init_task_pid() argument 1702 task->thread_pid = pid; in init_task_pid() 1704 task->signal->pids[type] = pid; in init_task_pid() 1727 struct pid *pidfd_pid(const struct file *file) in pidfd_pid() 1737 struct pid *pid = file->private_data; in pidfd_release() local 1740 put_pid(pid); in pidfd_release() 1751 * This function will print the pid tha 1782 struct pid *pid = f->private_data; pidfd_show_fdinfo() local 1816 struct pid *pid = file->private_data; pidfd_poll() local 1882 copy_process( struct pid *pid, int trace, int node, struct kernel_clone_args *args) copy_process() argument 2493 struct pid *pid; kernel_clone() local [all...] |
/foundation/distributeddatamgr/datamgr_service/services/distributeddataservice/service/rdb/ |
H A D | rdb_service_impl.cpp | 187 int32_t RdbServiceImpl::OnAppExit(pid_t uid, pid_t pid, uint32_t tokenId, const std::string &bundleName) in OnAppExit() argument 189 ZLOGI("client dead, tokenId:%{public}d, pid:%{public}d ", tokenId, pid); in OnAppExit() 191 syncAgents_.ComputeIfPresent(tokenId, [pid, &destroyed](auto &key, SyncAgents &agents) { in OnAppExit() 192 auto it = agents.find(pid); in OnAppExit() 212 heartbeatTaskIds_.Erase(pid); in OnAppExit() 250 pid_t pid = IPCSkeleton::GetCallingPid(); in InitNotifier() local 252 syncAgents_.Compute(tokenId, [bundleName = param.bundleName_, notifierProxy, pid](auto, SyncAgents &agents) { in InitNotifier() 253 auto [it, success] = agents.try_emplace(pid, SyncAgent(bundleName)); in InitNotifier() 260 ZLOGI("success tokenId:%{public}x, pid in InitNotifier() 323 OnAsyncComplete(uint32_t tokenId, pid_t pid, uint32_t seqNum, Details &&result) OnAsyncComplete() argument [all...] |
/foundation/ability/ability_runtime/test/mock/services_appmgr_test/include/ |
H A D | mock_app_mgr_service.h | 38 MOCK_METHOD2(DumpHeapMemory, int(const int32_t pid, OHOS::AppExecFwk::MallocInfo &mallocInfo)); 74 MOCK_METHOD2(GetAbilityRecordsByProcessID, int(const int pid, std::vector<sptr<IRemoteObject>>& tokens)); 87 MOCK_METHOD3(GetBundleNameByPid, int32_t(const int pid, std::string &bundleName, int32_t &uid)); 91 MOCK_METHOD2(GetProcessMemoryByPid, int32_t(const int32_t pid, int32_t & memorySize)); 112 MOCK_METHOD2(SetSupportedProcessCache, int32_t(int32_t pid, bool isSupport)); 119 MOCK_METHOD2(CheckIsKiaProcess, int32_t(pid_t pid, bool &isKia)); 182 virtual int32_t JudgeSandboxByPid(pid_t pid, bool &isSandbox) in JudgeSandboxByPid() argument 213 processData.pid = 1; in UpdateState() 238 virtual bool SetAppFreezeFilter(int32_t pid) in SetAppFreezeFilter() argument 243 virtual int32_t ChangeAppGcState(pid_t pid, int32_ argument [all...] |
/foundation/ability/ability_runtime/test/unittest/multi_app_utils_test/include/ |
H A D | mock_app_mgr_service.h | 37 MOCK_METHOD2(DumpHeapMemory, int(const int32_t pid, OHOS::AppExecFwk::MallocInfo &mallocInfo)); 73 MOCK_METHOD2(GetAbilityRecordsByProcessID, int(const int pid, std::vector<sptr<IRemoteObject>>& tokens)); 86 MOCK_METHOD3(GetBundleNameByPid, int32_t(const int pid, std::string &bundleName, int32_t &uid)); 90 MOCK_METHOD2(GetProcessMemoryByPid, int32_t(const int32_t pid, int32_t & memorySize)); 109 MOCK_METHOD2(SetSupportedProcessCache, int32_t(int32_t pid, bool isSupport)); 116 MOCK_METHOD2(CheckIsKiaProcess, int32_t(pid_t pid, bool &isKia)); 179 virtual int32_t JudgeSandboxByPid(pid_t pid, bool &isSandbox) in JudgeSandboxByPid() argument 210 processData.pid = 1; in UpdateState() 235 virtual bool SetAppFreezeFilter(int32_t pid) in SetAppFreezeFilter() argument 240 virtual int32_t ChangeAppGcState(pid_t pid, int32_ argument [all...] |
/foundation/multimedia/camera_framework/services/camera_service/src/dfx/ |
H A D | camera_report_uitls.cpp | 98 "CALLER_PID", caller_.pid, in ReportOpenCameraPerf() 163 "CALLER_PID", caller_.pid, in ReportModeChangePerf() 206 "CALLER_PID", captureInfo.caller.pid, in ReportCapturePerf() 250 "CALLER_PID", caller_.pid, in ReportSwitchCameraPerf() 264 callerInfo.pid = IPCSkeleton::GetCallingPid(); in GetCallerInfo() 268 MEDIA_DEBUG_LOG("CameraReportUtils::GetCallerInfo pid:%{public}d uid:%{public}d", callerInfo.pid, callerInfo.uid); in GetCallerInfo() 274 if (preCaller.pid != curCaller.pid || in IsCallerChanged() 294 str += " caller pid in ReportCameraError() [all...] |
/foundation/multimodalinput/input/frameworks/proxy/events/test/ |
H A D | input_manager_filter_manual_test.cpp | 137 int32_t StopExecutable(pid_t pid) const in StopExecutable() 139 if (pid != INVALID_PID) { in StopExecutable() 140 MMI_HILOGI("Kill pid = %{public}d, before", pid); in StopExecutable() 141 kill(pid, SIG_KILL); in StopExecutable() 142 MMI_HILOGI("Kill pid = %{public}d, finished", pid); in StopExecutable() 148 pid_t pid = getpid(); in GetProcessPidByName() local 156 pid = atoi(buf); in GetProcessPidByName() 160 return pid; in GetProcessPidByName() 179 pid_t pid = getpid(); GetSelfHidumperFilter() local [all...] |
/foundation/communication/dsoftbus/tests/core/connection/ble/ |
H A D | connection_ble_trans_test.cpp | 33 uint32_t connectionId, uint32_t len, int32_t pid, int32_t flag, int32_t module, int64_t seq, int32_t error) in OnPostBytesFinished() 37 (void)pid; in OnPostBytesFinished() 197 int32_t pid = 0; in HWTEST_F() local 201 int32_t ret = ConnBlePostBytesInner(connectionId, data, 0, pid, flag, module, seq, NULL); in HWTEST_F() 205 ret = ConnBlePostBytesInner(connectionId, value, MAX_DATA_LEN + 1, pid, flag, module, seq, NULL); in HWTEST_F() 211 ret = ConnBlePostBytesInner(connectionId, value1, dataLen, pid, flag, module, seq, NULL); in HWTEST_F() 220 ret = ConnBlePostBytesInner(connectionId, value2, dataLen, pid, flag, MODULE_AUTH_MSG, seq, NULL); in HWTEST_F() 230 ret = ConnBlePostBytesInner(connectionId, value3, dataLen, pid, flag, MODULE_AUTH_MSG, seq, NULL); in HWTEST_F() 352 queueNode.pid = 0; in HWTEST_F() 361 queueNode.pid in HWTEST_F() 32 OnPostBytesFinished( uint32_t connectionId, uint32_t len, int32_t pid, int32_t flag, int32_t module, int64_t seq, int32_t error) OnPostBytesFinished() argument [all...] |
/kernel/liteos_a/kernel/base/include/ |
H A D | los_process_pri.h | 383 #define OS_PID_CHECK_INVALID(pid) (((UINT32)(pid)) >= g_processMaxNum) 385 STATIC INLINE BOOL OsProcessIDUserCheckInvalid(UINT32 pid) in OsProcessIDUserCheckInvalid() argument 387 return ((pid >= g_processMaxNum) || (pid == 0)); in OsProcessIDUserCheckInvalid() 510 * Wait for the child process specified by the pid to finish 538 extern INT32 OsSetProcessScheduler(INT32 which, INT32 pid, UINT16 policy, const LosSchedParam *param); 539 extern INT32 OsGetProcessPriority(INT32 which, INT32 pid); 542 extern INT32 OsSetProcessGroupID(UINT32 pid, UINT32 gid); 548 extern INT32 OsSendSignalToProcessGroup(INT32 pid, siginfo_ [all...] |
/kernel/liteos_a/kernel/base/misc/ |
H A D | task_shellcmd.c | 144 SHOW("%5u%6u%5d%6d%7s%8s%7s%9u%5u%7u", processInfo->pid, processInfo->ppid, processInfo->pgroupID, in ProcessDataShow() 172 for (UINT32 pid = 1; pid < g_processMaxNum; ++pid) { in AllProcessDataShow() 173 const ProcessInfo *processInfo = pcbArray + pid; in AllProcessDataShow() 184 UINT32 pid = OS_KERNEL_IDLE_PROCESS_ID; in ProcessInfoShow() local 185 UINT32 sysUsage = LOS_CPUP_PRECISION - pcbArray[pid].cpup10sUsage; in ProcessInfoShow() 187 pcbArray[pid].cpup10sUsage / CPUP_MULT, pcbArray[pid].cpup10sUsage % CPUP_MULT); in ProcessInfoShow() 316 SHOW(" %4u%5u", taskInfo->tid, taskInfo->pid); in TaskInfoDataShow() [all...] |
/kernel/liteos_a/testsuites/unittest/security/reugid/smoke/ |
H A D | reugid_test_001.cpp | 374 pid_t pid = fork(); in Child() local 375 if (pid == 0) { in Child() 381 ret = waitpid(pid, &status, 0); in Child() 382 ICUNIT_GOTO_EQUAL(ret, pid, ret, EXIT); in Child() 421 pid_t pid = fork(); in TestCase() local 422 ICUNIT_GOTO_WITHIN_EQUAL(pid, 0, 100000, pid, EXIT); // assume pid is between 0 and 100000 in TestCase() 423 if (pid == 0) { in TestCase() 428 ret = waitpid(pid, in TestCase() [all...] |
/third_party/alsa-utils/alsactl/ |
H A D | daemon.c | 316 long pid; in state_daemon_kill() local 333 pid = read_pid_file(pidfile); in state_daemon_kill() 334 if (pid > 0) { in state_daemon_kill() 335 if (kill(pid, sig) >= 0) in state_daemon_kill() 344 long pid; in check_another_instance() local 346 pid = read_pid_file(pidfile); in check_another_instance() 347 if (pid >= 0) { in check_another_instance() 349 if (kill(pid, SIGUSR1) >= 0) { in check_another_instance() 351 pid = read_pid_file(pidfile); in check_another_instance() 352 if (pid > in check_another_instance() [all...] |
/third_party/python/Lib/ |
H A D | socketserver.py | 573 pid, _ = os.waitpid(-1, 0) 574 self.active_children.discard(pid) 582 for pid in self.active_children.copy(): 585 pid, _ = os.waitpid(pid, flags) 586 # if the child hasn't exited yet, pid will be 0 and ignored by 588 self.active_children.discard(pid) 591 self.active_children.discard(pid) 611 pid = os.fork() 612 if pid [all...] |
/third_party/toybox/toys/pending/ |
H A D | tcpsvd.c | 56 int pid; member 89 // Insert pid, ip and fd in the list. 90 static void insert(struct list_pid **l, int pid, char *addr) in insert() argument 93 newnode->pid = pid; in insert() 123 static char *delete(struct list_pid **pids, int pid) in delete() argument 131 if (head->pid == pid) { in delete() 268 pid_t pid; in tcpsvd_main() local 354 if (!(pid in tcpsvd_main() [all...] |
/foundation/ability/ability_lite/services/abilitymgr_lite/src/client/ |
H A D | app_spawn_client.cpp | 76 pid_t pid = -1;
in CallingInnerSpawnProcess() local 77 int result = spawnClient_->Invoke(spawnClient_, ID_CALL_CREATE_SERVICE, &request, &pid, Notify);
in CallingInnerSpawnProcess() 83 result = spawnClient_->Invoke(spawnClient_, ID_CALL_CREATE_SERVICE, &request, &pid, Notify);
in CallingInnerSpawnProcess() 88 appRecord.SetPid(pid);
in CallingInnerSpawnProcess()
|
/foundation/ability/ability_runtime/test/unittest/ams_app_state_callback_test/ |
H A D | ams_app_state_callback_test.cpp | 65 processData.pid = 1; in HWTEST_F() 158 processData.pid = 1; in HWTEST_F() 172 EXPECT_EQ(processData.pid, newProcessData->pid); in HWTEST_F()
|