Home
last modified time | relevance | path

Searched refs:revents (Results 1 – 25 of 170) sorted by relevance

1234567

/freebsd/contrib/netbsd-tests/lib/libc/sys/
H A Dt_poll.c173 pfds[0].revents = -1; in ATF_TC_BODY()
174 pfds[1].revents = -1; in ATF_TC_BODY()
177 ATF_REQUIRE_EQ_MSG(pfds[0].revents, 0, "got: %d", pfds[0].revents); in ATF_TC_BODY()
178 ATF_REQUIRE_EQ_MSG(pfds[1].revents, -1, "got: %d", pfds[1].revents); in ATF_TC_BODY()
181 pfds[0].revents = -1; in ATF_TC_BODY()
182 pfds[1].revents = -1; in ATF_TC_BODY()
185 ATF_REQUIRE_EQ_MSG(pfds[0].revents, -1, "got: %d", pfds[0].revents); in ATF_TC_BODY()
186 ATF_REQUIRE_EQ_MSG(pfds[1].revents, POLLOUT, "got: %d",\ in ATF_TC_BODY()
187 pfds[1].revents); in ATF_TC_BODY()
190 pfds[0].revents = -1; in ATF_TC_BODY()
[all …]
/freebsd/tools/regression/poll/
H A Dsockpoll.c129 report(num++, "initial 0", POLLOUT, pfd0.revents); in main()
132 report(num++, "initial 1", POLLOUT, pfd1.revents); in main()
137 report(num++, "after large write", 0, pfd0.revents); in main()
140 report(num++, "other side after large write", POLLIN | POLLOUT, pfd1.revents); in main()
144 report(num++, "other side after close", POLLIN | POLLHUP, pfd1.revents); in main()
149 report(num++, "other side after reading input", POLLHUP, pfd1.revents); in main()
158 report(num++, "after shutdown(SHUT_WR)", POLLOUT, pfd0.revents); in main()
161 report(num++, "other side after shutdown(SHUT_WR)", POLLIN | POLLOUT, pfd1.revents); in main()
173 report(num++, "other side after reading EOF", POLLIN | POLLOUT, pfd1.revents); in main()
178 report(num++, "after data from other side", POLLIN | POLLOUT, pfd0.revents); in main()
[all …]
H A Dpipepoll.c106 report(num++, "0", 0, pfd.revents, res, 0); in child()
124 report(num++, "1", 0, pfd.revents, res, 0); in child()
132 report(num++, "2", POLLIN, pfd.revents, res, 1); in child()
137 report(num++, "2a", 0, pfd.revents, res, 0); in child()
145 report(num++, "3", POLLHUP, pfd.revents, res, 1); in child()
160 report(num++, "4", 0, pfd.revents, res, 0); in child()
168 report(num++, "5", POLLIN, pfd.revents, res, 1); in child()
186 report(num++, "6", POLLIN | POLLHUP, pfd.revents, res, 1); in child()
191 report(num++, "6a", POLLHUP, pfd.revents, res, 1); in child()
203 report(num++, "6b", POLLHUP, pfd.revents, res, 1); in child()
[all …]
/freebsd/tools/tools/netmap/
H A Dbridge.c321 pollfd[0].revents = pollfd[1].revents = 0; in main()
326 pollfd[1].revents = POLLOUT; in main()
331 pollfd[0].revents = POLLOUT; in main()
354 pollfd[0].revents, in main()
359 pollfd[1].revents, in main()
366 if (pollfd[0].revents & POLLERR) { in main()
371 if (pollfd[1].revents & POLLERR) { in main()
376 if (pollfd[0].revents & POLLOUT) { in main()
383 if (pollfd[1].revents & POLLOUT) { in main()
/freebsd/crypto/openssh/openbsd-compat/
H A Dbsd-poll.c83 fds[i].revents = 0; in ppoll()
87 fds[i].revents |= POLLIN; in ppoll()
89 fds[i].revents |= POLLOUT; in ppoll()
91 fds[i].revents |= POLLPRI; in ppoll()
/freebsd/cddl/usr.sbin/zfsd/
H A Dzfsd.cc345 fds[0].revents = 0; in EventLoop()
348 fds[1].revents = 0; in EventLoop()
359 if ((fds[0].revents & POLLIN) != 0) in EventLoop()
362 if ((fds[1].revents & POLLIN) != 0) { in EventLoop()
382 if ((fds[0].revents & POLLERR) != 0) { in EventLoop()
387 if ((fds[0].revents & POLLHUP) != 0) { in EventLoop()
/freebsd/lib/libsys/
H A Drecvmmsg.c50 pfd[0].revents = 0; in __ssp_real()
56 if (pfd[0].revents & POLLNVAL) { in __ssp_real()
60 if ((pfd[0].revents & ev) == 0) { in __ssp_real()
/freebsd/lib/libdevdctl/
H A Dconsumer.cc235 fds->revents = 0; in EventsPending()
242 if ((fds->revents & POLLERR) != 0) in EventsPending()
246 if ((fds->revents & POLLHUP) != 0) in EventsPending()
250 return ((fds->revents & POLLIN) != 0); in EventsPending()
/freebsd/contrib/bearssl/tools/
H A Dsslio.c550 pfd[u].revents = 0; in run_ssl_engine()
563 pfd[u].revents = 0; in run_ssl_engine()
570 pfd[u].revents = 0; in run_ssl_engine()
594 if (pfd[u].revents & (POLLERR | POLLHUP)) { in run_ssl_engine()
595 pfd[u].revents |= POLLIN | POLLOUT; in run_ssl_engine()
599 recvapp_ok = recvapp && (pfd[k_out].revents & POLLOUT) != 0; in run_ssl_engine()
600 sendrec_ok = sendrec && (pfd[k_fd].revents & POLLOUT) != 0; in run_ssl_engine()
601 recvrec_ok = recvrec && (pfd[k_fd].revents & POLLIN) != 0; in run_ssl_engine()
602 sendapp_ok = sendapp && (pfd[k_in].revents & POLLIN) != 0; in run_ssl_engine()
/freebsd/sys/kern/
H A Dsys_eventfd.c232 int revents; in eventfd_poll() local
235 revents = 0; in eventfd_poll()
238 revents |= events & (POLLIN | POLLRDNORM); in eventfd_poll()
241 revents |= events & (POLLOUT | POLLWRNORM); in eventfd_poll()
242 if (revents == 0) in eventfd_poll()
246 return (revents); in eventfd_poll()
H A Dsys_procdesc.c425 int revents; in procdesc_poll() local
427 revents = 0; in procdesc_poll()
431 revents |= POLLHUP; in procdesc_poll()
432 if (revents == 0) { in procdesc_poll()
437 return (revents); in procdesc_poll()
H A Dsubr_log.c180 int revents = 0; in logpoll() local
185 revents |= events & (POLLIN | POLLRDNORM); in logpoll()
190 return (revents); in logpoll()
/freebsd/sys/dev/snp/
H A Dsnp.c319 int revents; in snp_poll() local
325 revents = 0; in snp_poll()
332 revents |= events & (POLLIN | POLLRDNORM); in snp_poll()
337 if (revents == 0) in snp_poll()
340 return (revents); in snp_poll()
/freebsd/contrib/sendmail/libmilter/
H A Dlibmilter.h184 (rds).revents = 0
189 (wrs).revents = 0
192 (((rds).revents & (POLLERR | POLLHUP | POLLNVAL)) != 0)
195 (((wrs).revents & MI_POLL_WR_FLAGS) != 0)
198 (((rds).revents & MI_POLL_RD_FLAGS) != 0)
H A Dworker.c439 pfd[nfd].revents = 0;
489 pfd[nfd].revents = 0;
531 if (pfd[i].revents == 0)
546 pfd[i].events, pfd[i].revents));
549 while ((pfd[i].revents & MI_POLL_RD_FLAGS) != 0
559 if ((pfd[i].revents & ~MI_POLL_RD_FLAGS) != 0)
/freebsd/sys/netpfil/ipfilter/netinet/
H A Dmlfk_ipl.c440 int revents; in ipfpoll() local
445 revents = 0; in ipfpoll()
455 revents |= events & (POLLIN | POLLRDNORM); in ipfpoll()
460 revents |= events & (POLLIN | POLLRDNORM); in ipfpoll()
464 revents |= events & (POLLIN | POLLRDNORM); in ipfpoll()
466 revents |= events & (POLLOUT | POLLWRNORM); in ipfpoll()
474 if ((revents == 0) && ((events & (POLLIN|POLLRDNORM)) != 0)) in ipfpoll()
478 return (revents); in ipfpoll()
/freebsd/contrib/capsicum-test/
H A Dlinux.cc76 poll_fd.revents = 0; in TEST()
85 EXPECT_EQ(0, (poll_fd.revents & POLLIN)); in TEST()
86 EXPECT_NE(0, (poll_fd.revents & POLLNVAL)); in TEST()
91 EXPECT_NE(0, (poll_fd.revents & POLLIN)); in TEST()
92 EXPECT_EQ(0, (poll_fd.revents & POLLNVAL)); in TEST()
173 poll_fd.revents = 0; in FORK_TEST()
177 EXPECT_EQ(0, (poll_fd.revents & POLLIN)); in FORK_TEST()
178 EXPECT_NE(0, (poll_fd.revents & POLLNVAL)); in FORK_TEST()
182 EXPECT_NE(0, (poll_fd.revents & POLLIN)); in FORK_TEST()
183 EXPECT_EQ(0, (poll_fd.revents & POLLNVAL)); in FORK_TEST()
[all …]
/freebsd/sys/dev/tcp_log/
H A Dtcp_log_dev.c402 int revents; in tcp_log_dev_poll() local
412 revents = 0; in tcp_log_dev_poll()
424 revents = events & (POLLIN | POLLRDNORM); in tcp_log_dev_poll()
434 revents = events; in tcp_log_dev_poll()
436 return (revents); in tcp_log_dev_poll()
/freebsd/contrib/libpcap/testprogs/
H A Dselpolltest.c293 if (fd.revents & POLLIN) in main()
297 if (fd.revents & POLLERR) in main()
301 if (fd.revents & POLLHUP) in main()
305 if (fd.revents & POLLNVAL) in main()
/freebsd/usr.sbin/bhyve/
H A Dnet_backend_slirp.c318 pollfd->revents = 0; in slirp_addpoll_cb()
328 short revents; in slirp_poll_revents() local
337 revents = pollfd->revents; in slirp_poll_revents()
339 revents &= ~POLLHUP; in slirp_poll_revents()
340 return (pollev2slirpev(revents)); in slirp_poll_revents()
385 if ((pollfds[wakeup].revents & POLLIN) != 0) { in slirp_pollfd_td_loop()
/freebsd/contrib/ofed/infiniband-diags/src/
H A Drdma-ndd.c328 fds[0].revents = 0; in monitor()
332 fds[1].revents = 0; in monitor()
340 if (fds[0].revents != 0) in monitor()
343 if (fds[1].revents != 0) in monitor()
/freebsd/tools/regression/netinet/tcpfullwindowrst/
H A Dtcpfullwindowrsttest.c112 if (pfd[0].revents & POLLOUT) { in main()
119 if (pfd[1].revents & POLLOUT) { in main()
/freebsd/contrib/netcat/
H A Dnetcat.c935 if (pfd[n].revents & (POLLERR|POLLNVAL)) { in readwrite()
941 pfd[POLL_STDIN].revents & POLLHUP && in readwrite()
942 ! (pfd[POLL_STDIN].revents & POLLIN)) in readwrite()
946 pfd[POLL_NETIN].revents & POLLHUP && in readwrite()
947 ! (pfd[POLL_NETIN].revents & POLLIN)) in readwrite()
950 if (pfd[POLL_NETOUT].revents & POLLHUP) { in readwrite()
956 if (pfd[POLL_STDOUT].revents & POLLHUP) in readwrite()
969 if (pfd[POLL_STDIN].revents & POLLIN && stdinbufpos < BUFSIZE) { in readwrite()
983 if (pfd[POLL_NETOUT].revents & POLLOUT && stdinbufpos > 0) { in readwrite()
996 if (pfd[POLL_NETIN].revents & POLLIN && netinbufpos < BUFSIZE) { in readwrite()
[all …]
/freebsd/contrib/netbsd-tests/lib/librumphijack/
H A Dh_client.c113 if (pfd[1].revents != POLLNVAL || pfd[0].revents != 0) in main()
/freebsd/crypto/openssh/regress/
H A Dnetcat.c854 if (pfd[n].revents & (POLLERR|POLLNVAL)) { in readwrite()
860 pfd[POLL_STDIN].revents & POLLHUP && in readwrite()
861 ! (pfd[POLL_STDIN].revents & POLLIN)) in readwrite()
865 pfd[POLL_NETIN].revents & POLLHUP && in readwrite()
866 ! (pfd[POLL_NETIN].revents & POLLIN)) in readwrite()
869 if (pfd[POLL_NETOUT].revents & POLLHUP) { in readwrite()
875 if (pfd[POLL_STDOUT].revents & POLLHUP) in readwrite()
888 if (pfd[POLL_STDIN].revents & POLLIN && stdinbufpos < BUFSIZE) { in readwrite()
902 if (pfd[POLL_NETOUT].revents & POLLOUT && stdinbufpos > 0) { in readwrite()
915 if (pfd[POLL_NETIN].revents & POLLIN && netinbufpos < BUFSIZE) { in readwrite()
[all …]

1234567