Lines Matching defs:fds
180 static int PollfdToSystem(struct pollfd *fds, nfds_t nfds, int **pollFdsBak)
182 if ((nfds != 0 && fds == NULL) || (pollFdsBak == NULL)) {
195 struct pollfd *p_fds = &fds[i];
208 static void RestorePollfd(struct pollfd *fds, nfds_t nfds, const int *pollFds)
210 if ((fds == NULL) || (pollFds == NULL)) {
214 struct pollfd *p_fds = &fds[i];
219 static int UserPoll(struct pollfd *fds, nfds_t nfds, int timeout)
222 int ret = PollfdToSystem(fds, nfds, &pollFds);
227 ret = poll(fds, nfds, timeout);
229 RestorePollfd(fds, nfds, pollFds);
1028 int SysPipe(int pipefd[2]) /* 2 : pipe fds for read and write */
1031 int pipeFdIntr[2] = {0}; /* 2 : pipe fds for read and write */
1552 int SysPoll(struct pollfd *fds, nfds_t nfds, int timeout)
1557 if ((nfds >= MAX_POLL_NFDS) || (nfds == 0) || (fds == NULL)) {
1563 if (LOS_ArchCopyFromUser(kfds, fds, sizeof(struct pollfd) * nfds) != 0) {
1584 if (LOS_ArchCopyToUser(fds, kfds, sizeof(struct pollfd) * nfds) != 0) {
2657 int SysPpoll(struct pollfd *fds, nfds_t nfds, const struct timespec *tmo_p, const sigset_t *sigMask, int nsig)
2685 retVal = SysPoll(fds, nfds, timeout);