/ohos5.0/base/startup/init/interfaces/innerkits/control_fd/ |
H A D | control_fd_client.c | 172 int pfd = open("/dev/ptmx", O_RDWR | O_CLOEXEC); in InitPtyInterface() local 173 BEGET_ERROR_CHECK(pfd >= 0, return -1, "Failed open pty err=%d", errno); in InitPtyInterface() 174 BEGET_ERROR_CHECK(grantpt(pfd) >= 0, close(pfd); return -1, "Failed to call grantpt"); in InitPtyInterface() 175 BEGET_ERROR_CHECK(unlockpt(pfd) >= 0, close(pfd); return -1, "Failed to call unlockpt"); in InitPtyInterface() 177 ret = ptsname_r(pfd, ptsbuffer, sizeof(ptsbuffer)); in InitPtyInterface() 178 BEGET_ERROR_CHECK(ret >= 0, close(pfd); return -1, "Failed to get pts name err=%d", errno); in InitPtyInterface() 181 close(pfd); return -1, "Failed to chmod %s, err=%d", ptsbuffer, errno); in InitPtyInterface() 182 agent->ptyFd = pfd; in InitPtyInterface() 188 info.fd = pfd; // read ptmx in InitPtyInterface() 190 close(pfd); return -1, "[control_fd] Failed le_loop start watcher ptmx read"); in InitPtyInterface() [all …]
|
/ohos5.0/base/startup/appspawn/test/unittest/app_spawn_standard_test/ |
H A D | app_spawn_beget_test.cpp | 52 int pfd = open("/dev/ptmx", O_RDWR | O_CLOEXEC | O_NOCTTY | O_NONBLOCK); in InitPtyInterface() local 53 APPSPAWN_CHECK(pfd >= 0, return, "Failed open pty err=%{public}d", errno); in InitPtyInterface() 54 APPSPAWN_CHECK(grantpt(pfd) >= 0, close(pfd); return, "Failed to call grantpt"); in InitPtyInterface() 55 APPSPAWN_CHECK(unlockpt(pfd) >= 0, close(pfd); return, "Failed to call unlockpt"); in InitPtyInterface() 57 int ret = ptsname_r(pfd, ptsbuffer, sizeof(ptsbuffer)); in InitPtyInterface() 58 APPSPAWN_CHECK(ret >= 0, close(pfd); in InitPtyInterface() 61 … APPSPAWN_CHECK(chmod(ptsbuffer, S_IRWXU | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH) == 0, close(pfd); in InitPtyInterface()
|
/ohos5.0/base/hiviewdfx/faultloggerd/interfaces/innerkits/unwinder/include/ |
H A D | fp_unwinder.h | 90 int32_t pfd[PIPE_NUM_SZ] = {-1, -1}; variable 91 if (syscall(SYS_pipe2, pfd, O_CLOEXEC | O_NONBLOCK) != 0) { 103 if ((!ReadUptrSafe(prevFp, pfd[PIPE_WRITE], fp)) || 104 (!ReadUptrSafe(prevFp + sizeof(uintptr_t), pfd[PIPE_WRITE], pc))) { 111 syscall(SYS_close, pfd[PIPE_WRITE]); 112 syscall(SYS_close, pfd[PIPE_READ]);
|
/ohos5.0/base/startup/init/ueventd/ |
H A D | ueventd_main.c | 50 struct pollfd pfd = {}; in PollUeventdSocketTimeout() local 51 pfd.events = POLLIN; in PollUeventdSocketTimeout() 52 pfd.fd = ueventSockFd; in PollUeventdSocketTimeout() 57 pfd.revents = 0; in PollUeventdSocketTimeout() 58 ret = poll(&pfd, 1, timeout); in PollUeventdSocketTimeout() 69 if (pfd.revents & (POLLIN | POLLERR)) { in PollUeventdSocketTimeout()
|
/ohos5.0/base/security/device_auth/deps_adapter/os_adapter/impl/src/linux/ |
H A D | hc_file.c | 93 file->pfd = HcFileOpenRead(path); in HcFileOpen() 95 file->pfd = HcFileOpenWrite(path); in HcFileOpen() 97 if (file->pfd == NULL) { in HcFileOpen() 105 FILE *fp = (FILE *)file.pfd; in HcFileSize() 122 FILE *fp = (FILE *)file.pfd; in HcFileRead() 146 FILE *fp = (FILE *)file.pfd; in HcFileWrite() 177 FILE *fp = (FILE *)file.pfd; in HcFileClose()
|
/ohos5.0/foundation/graphic/graphic_3d/lume/LumeRender/src/gles/ |
H A D | wgl_state.cpp | 152 PIXELFORMATDESCRIPTOR pfd = { 0 }; in DoDummy() local 153 pfd.nSize = sizeof(pfd); in DoDummy() 154 pfd.nVersion = 1; in DoDummy() 156 pfd.iPixelType = PFD_TYPE_RGBA; in DoDummy() 157 pfd.cColorBits = 32; in DoDummy() 158 pfd.iLayerType = PFD_MAIN_PLANE; in DoDummy() 159 SetPixelFormat(dummyhDC, ChoosePixelFormat(dummyhDC, &pfd), &pfd); in DoDummy() 374 PIXELFORMATDESCRIPTOR pfd = { 0 }; in GetSurfaceInformation() local 375 DescribePixelFormat(plat_.display, configId, sizeof(pfd), &pfd); in GetSurfaceInformation() 483 PIXELFORMATDESCRIPTOR pfd = { 0 }; in CreateContext() local [all …]
|
/ohos5.0/foundation/communication/netmanager_base/test/netmanagernative/unittest/netsys_manager_test/ |
H A D | dns_proxy_listen_test.cpp | 94 struct pollfd pfd; variable 95 pfd.fd = proxySockFd; 96 pfd.events = POLLIN; 97 poll(&pfd, 1, 2000);
|
/ohos5.0/base/startup/init/services/modules/init_context/ |
H A D | init_context.c | 231 struct pollfd pfd = {}; in SubInitMain() local 232 pfd.events = POLLIN; in SubInitMain() 233 pfd.fd = readFd; in SubInitMain() 239 pfd.revents = 0; in SubInitMain() 240 int ret = poll(&pfd, 1, timeout); in SubInitMain() 248 if ((unsigned int)pfd.revents & POLLIN) { in SubInitMain()
|
/ohos5.0/base/startup/appspawn/test/moduletest/ |
H A D | appspawn_test_cmder.cpp | 600 int pfd = open("/dev/ptmx", O_RDWR | O_CLOEXEC | O_NOCTTY | O_NONBLOCK); in InitPtyInterface() local 601 APPSPAWN_CHECK(pfd >= 0, return -1, "Failed open pty err=%{public}d", errno); in InitPtyInterface() 602 APPSPAWN_CHECK(grantpt(pfd) >= 0, close(pfd); return -1, "Failed to call grantpt"); in InitPtyInterface() 603 APPSPAWN_CHECK(unlockpt(pfd) >= 0, close(pfd); return -1, "Failed to call unlockpt"); in InitPtyInterface() 605 int ret = ptsname_r(pfd, ptsbuffer, sizeof(ptsbuffer)); in InitPtyInterface() 606 APPSPAWN_CHECK(ret >= 0, close(pfd); in InitPtyInterface() 609 … APPSPAWN_CHECK(chmod(ptsbuffer, S_IRWXU | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH) == 0, close(pfd); in InitPtyInterface() 611 ptyFd_ = pfd; in InitPtyInterface()
|
/ohos5.0/foundation/communication/wifi/wifi/relation_services/wifi_hal_service/wifi_hal_module/hostapd_hal/ |
H A D | wifi_hostapd_hal.c | 136 struct pollfd pfd; in MyWpaCtrlPending() local 137 if (memset_s(&pfd, sizeof(pfd), 0, sizeof(pfd)) != EOK) { in MyWpaCtrlPending() 140 pfd.fd = wpa_ctrl_get_fd(ctrl); in MyWpaCtrlPending() 141 pfd.events = POLLIN; in MyWpaCtrlPending() 142 int ret = poll(&pfd, 1, 100); /* 100 ms */ in MyWpaCtrlPending()
|
/ohos5.0/base/update/updater/services/ |
H A D | updater.cpp | 444 int pfd[DEFAULT_PIPE_NUM]; /* communication between parent and child */ in StartUpdaterProc() local 445 if (pipe(pfd) < 0) { in StartUpdaterProc() 456 int pipeRead = pfd[0]; in StartUpdaterProc() 457 int pipeWrite = pfd[1]; in StartUpdaterProc()
|
/ohos5.0/base/security/device_auth/deps_adapter/os_adapter/interfaces/linux/ |
H A D | hc_file.h | 26 void *pfd; member
|
/ohos5.0/foundation/communication/wifi/wifi/relation_services/wifi_hal_service/wifi_hal_module/wpa_supplicant_hal/ |
H A D | wifi_wpa_hal.c | 792 struct pollfd pfd; in MyWpaCtrlPending() local 793 if (memset_s(&pfd, sizeof(pfd), 0, sizeof(pfd)) != EOK) { in MyWpaCtrlPending() 796 pfd.fd = wpa_ctrl_get_fd(ctrl); in MyWpaCtrlPending() 797 pfd.events = POLLIN; in MyWpaCtrlPending() 798 int ret = poll(&pfd, 1, 100); /* 100 ms */ in MyWpaCtrlPending()
|
/ohos5.0/base/security/device_auth/deps_adapter/os_adapter/interfaces/liteos/ |
H A D | hc_file.h | 29 void *pfd; member
|
/ohos5.0/drivers/peripheral/usb/ddk/device/src/ |
H A D | adapter_if_liteos.c | 880 struct FconfigPollFd *pfd = &pfds[0]; in UsbFnAdapterPollEvent() local 916 if (Ep0Event(event, pfd) < 0) { in UsbFnAdapterPollEvent() 920 if (EpEvent(event, pfd) < 0) { in UsbFnAdapterPollEvent()
|