Home
last modified time | relevance | path

Searched +full:poll +full:- +full:timeout +full:- +full:ms (Results 1 – 25 of 183) sorted by relevance

12345678

/freebsd/sys/contrib/device-tree/Bindings/serial/
H A Dpl011.yaml1 # SPDX-License-Identifier: GPL-2.0
3 ---
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
10 - Rob Herring <robh@kernel.org>
13 - $ref: /schemas/arm/primecell.yaml#
14 - $ref: serial.yaml#
22 - arm,pl011
24 - compatible
29 - const: arm,pl011
30 - const: arm,primecell
[all …]
/freebsd/crypto/openssl/doc/designs/ddd/
H A Dddd-02-conn-nonblocking.c1 #include <sys/poll.h>
17 * simply calls back into this code when poll()/etc. indicates it is ready.
142 conn->ssl_bio = out; in new_conn()
147 * Non-blocking transmission.
149 * Returns -1 on error. Returns -2 if the function would block (corresponds to
156 conn->tx_need_rx = 0; in tx()
158 l = BIO_write(conn->ssl_bio, buf, buf_len); in tx()
160 if (BIO_should_retry(conn->ssl_bio)) { in tx()
161 conn->tx_need_rx = BIO_should_read(conn->ssl_bio); in tx()
162 return -2; in tx()
[all …]
H A Dddd-04-fd-nonblocking.c1 #include <sys/poll.h>
68 ssl = conn->ssl = SSL_new(ctx); in new_conn()
104 conn->fd = fd; in new_conn()
109 * Non-blocking transmission.
111 * Returns -1 on error. Returns -2 if the function would block (corresponds to
118 conn->tx_need_rx = 0; in tx()
120 l = SSL_write(conn->ssl, buf, buf_len); in tx()
122 rc = SSL_get_error(conn->ssl, l); in tx()
125 conn->tx_need_rx = 1; in tx()
128 return -2; in tx()
[all …]
H A Dddd-02-conn-nonblocking-threads.c1 #include <sys/poll.h>
17 * simply calls back into this code when poll()/etc. indicates it is ready.
130 conn->ssl_bio = out; in new_conn()
135 * Non-blocking transmission.
137 * Returns -1 on error. Returns -2 if the function would block (corresponds to
144 conn->tx_need_rx = 0; in tx()
146 l = BIO_write(conn->ssl_bio, buf, buf_len); in tx()
148 if (BIO_should_retry(conn->ssl_bio)) { in tx()
149 conn->tx_need_rx = BIO_should_read(conn->ssl_bio); in tx()
150 return -2; in tx()
[all …]
/freebsd/tests/sys/kern/
H A Dprace.c1 /*-
4 * SPDX-License-Identifier: BSD-2-Clause
9 * handler and repeatedly calls either ppoll() or pselect() with a 1 ms
10 * timeout, while the parent repeatedly sends SIGINT to the child at
22 #include <poll.h>
28 #include <atf-c.h>
39 child(int rd, bool poll) in child() argument
41 struct timespec timeout = { .tv_nsec = 1000000 }; in child() local
57 /* sleep for 1 ms with signals unblocked */ in child()
58 ret = poll ? ppoll(NULL, 0, &timeout, &set0) : in child()
[all …]
/freebsd/contrib/netbsd-tests/lib/libc/gen/
H A Dt_sleep.c3 /*-
34 #include <atf-c.h>
37 #include <poll.h>
46 #define BILLION 1000000000LL /* nano-seconds per second */
47 #define MILLION 1000000LL /* nano-seconds per milli-second */
51 #define KEVNT_TIMEOUT 10300 /* measured in milli-seconds */
52 #define FUZZ (40 * MILLION) /* scheduling fuzz accepted - 40 ms */
58 * starts at 1sec (since it cannot handle sub-second intervals).
102 if (nanosleep(delay, remain) == -1) in do_nanosleep()
116 if (select(0, NULL, NULL, NULL, &tv) == -1) in do_select()
[all …]
/freebsd/contrib/ntp/ntpd/
H A Drefclock_acts.c2 * refclock_acts - clock driver for the NIST/USNO/PTB/NPL Computer Time
33 * This driver requires a modem with a Hayes-compatible command set and
35 * modem setup string is hard-coded in the driver and may require
41 * followed by the number itself, including the long-distance prefix
43 * when (a) fudge flag1 is set by ntpdc, (b) at each poll interval
45 * poll interval whether or not other synchronization sources are
69 * driver will send a single character 'T' at each poll event. If
76 * Phone: (303) 494-4774 (Boulder, CO); (808) 335-4721 (Hawaii)
85 * 47999 90-0
[all...]
H A Drefclock_pst.c2 * refclock_pst - clock driver for PSTI/Traconex WWV/WWVH receivers
22 * but actual experience suggests that 10 ms would be a conservative
25 * The DIPswitches should be set for 9600 bps line speed, 24-hour day-
26 * of-year format and UTC time zone. Automatic correction for DST should
32 * be set only to within 11 ms, the fudge time1 parameter can be used
35 * Using the poll sequence QTQDQM, the response timecode is in three
41 * on-time = first <cr>
43 * a = AM/PM indicator (' ' for 24-hour mode)
46 * s = daylight-savin
[all...]
H A Drefclock_wwvb.c2 * refclock_wwvb - clock driver for Spectracom WWVB and GPS receivers
36 * The WWVB and GPS clocks should be configured for 24-hour display,
42 * to a 'T' poll character or left running continuously.
53 * on-time = first <cr>
65 * on-time = <cr>
77 * The q is normally ' ' when the time error is less than 1 ms and a
79 * 100, 500 and greater than 500 ms respectively. The l is normally ' ',
87 * This driver does not need to be told which format is in use - it
98 * the PPS signal fails for one or more poll intervals, the driver
99 * reverts to the timecode. If the timecode fails for one or more poll
[all...]
H A Drefclock_arbiter.c2 * refclock_arbiter - clock driver for Arbiter 1088A/B Satellite
31 * The timecode format supported by this driver is selected by the poll
33 * repeated once per second until turned off by the "B0" poll sequence.
39 * on-time = <cr>
53 * Format TQ (IEEE P1344 estimated worst-case time quality)
60 * 7 clock unlocked, accuracy < 1 ms
61 * 8 clock unlocked, accuracy < 10 ms
62 * 9 clock unlocked, accuracy < 100 ms
81 * deviation mode and connected to a 1-PPS signal, the last two numbers
93 #define PRECISION (-2
[all...]
H A Dntp_refclock.c2 * ntp_refclock - processing support for reference clocks
53 * In addition, there may be a driver-specific unit structure used for
57 * which is used for all peer-specific processing and contains a
82 #if MAXSTAGE & (MAXSTAGE - 1)
89 pp->coderecv = (pp->coderecv + 1) % MAXSTAGE; in clk_add_sample()
90 if (pp->coderecv == pp->codeproc) in clk_add_sample()
91 pp->codeproc = (pp->codepro in clk_add_sample()
1520 struct timespec timeout; refclock_pps() local
1667 struct timespec timeout; refclock_ppsaugment() local
[all...]
/freebsd/crypto/openssl/test/quic-openssl-docker/hq-interop/
H A Dquic-hq-interop.c2 * Copyright 2024-2025 The OpenSSL Project Authors. All Rights Reserved.
11 * @file quic-hq-interop.c
15 * interoperability with hq-interop servers. It handles connection setup,
20 * and uses non-blocking mode for QUIC operations.
30 * quic-hq-interop <host> <port> <reqfile>
31 * host - The hostname of the server to contact
32 * port - The port that the server is listening on
33 * reqfile - a text file containing a space separated list of paths to fetch
37 * SSLKEYLOGFILE - set to a file path to record keylog exchange with server
38 * SSL_SESSION_FILE - set to a file path to record ssl sessions and restore
[all …]
/freebsd/contrib/less/
H A Dos.c2 * Copyright (C) 1984-2025 Mark Nudelman
53 #include <poll.h>
122 /* In old versions of MacOS, poll() does not work with /dev/tty. */ in init_poll()
140 …int timeout = (waiting_for_data && !(scanning_eof && follow_mode == FOLLOW_NAME)) ? -1 : (ignore_e… in check_poll() local
154 poll(poller, 2, timeout); in check_poll()
170 /* Break out of F loop on HUP due to --exit-follow-on-close. */ in check_poll()
242 /* Non-interrupt signal like SIGWINCH. */ in iread()
264 if (select(fd+1, &readfds, 0, 0, 0) == -1) in iread()
304 * start returning 0 forever, instead of -1. in iread()
359 return -1; in iopen()
[all …]
/freebsd/crypto/openssl/demos/guide/
H A Dquic-server-non-block.c2 * Copyright 2024-2025 The OpenSSL Project Authors. All Rights Reserved.
12 * doc/man7/ossl-guide-quic-server-non-block.pod
66 * ALPN strings for TLS handshake. Only 'http/1.0' and 'hq-interop'
71 10, 'h', 'q', '-', 'i', 'n', 't', 'e', 'r', 'o', 'p',
95 * subsequent per-client connections. We specifically load a QUIC in create_ctx()
104 * not only the leaf (end-entity) server certificate, but also any in create_ctx()
105 * intermediate issuer-CA certificates. The leaf certificate must be the in create_ctx()
108 * In advanced use-cases this can be called multiple times, once per public in create_ctx()
124 * key matches the just loaded end-entity certificate. It does not check in create_ctx()
134 * Clients rarely employ certificate-based authentication, and so we don't in create_ctx()
[all …]
H A Dquic-client-non-block.c2 * Copyright 2023-2025 The OpenSSL Project Authors. All Rights Reserved.
12 * doc/man7/ossl-guide-quic-client-non-block.pod
33 int sock = -1; in create_socket_bio()
51 * Create a UDP socket. We could equally use non-OpenSSL calls such in create_socket_bio()
58 if (sock == -1) in create_socket_bio()
64 sock = -1; in create_socket_bio()
71 sock = -1; in create_socket_bio()
78 if (sock != -1) { in create_socket_bio()
89 /* If sock is -1 then we've been unable to connect to the server */ in create_socket_bio()
90 if (sock == -1) in create_socket_bio()
[all …]
/freebsd/sys/dev/ixgbe/
H A Dixgbe_82598.c2 SPDX-License-Identifier: BSD-3-Clause
4 Copyright (c) 2001-2020, Intel Corporation
71 * ixgbe_set_pcie_completion_timeout - set pci-e completion timeout
74 * The defaults for 82598 should be in the range of 50us to 50ms,
75 * however the hardware default for these parts is 500us to 1ms which is less
76 * than the 10ms recommended by the pci-e spec. To address this we need to
77 * increase the value to either 10ms to 250ms for capability version 1 config,
78 * or 16ms to 55ms for version 2.
85 /* only take action if timeout value is defaulted to 0 */ in ixgbe_set_pcie_completion_timeout()
91 * timeout of 10ms to 250ms through the GCR register in ixgbe_set_pcie_completion_timeout()
[all …]
/freebsd/usr.bin/whois/
H A Dwhois.c1 /*-
2 * SPDX-License-Identifier: BSD-3-Clause
34 #include <sys/poll.h>
52 #define DKNICHOST "whois.dk-hostmaster.dk"
62 #define QNICHOST_TAIL ".whois-servers.net"
64 #define VNICHOST "whois.verisign-grs.com"
74 #define ishost(h) (isalnum((unsigned char)h) || h == '.' || h == '-')
85 { "-ARIN", ANICHOST },
86 { "-NICAT", "at" QNICHOST_TAIL },
87 { "-NORID", "no" QNICHOST_TAIL },
[all …]
/freebsd/sys/dev/smartpqi/
H A Dsmartpqi_sis.c1 /*-
2 * Copyright 2016-2023 Microchip Technology, Inc. and/or its subsidiaries.
37 db_reg = PCI_MEM_GET32(softs, &softs->ioa_reg->host_to_ioa_db, in sis_disable_msix()
40 PCI_MEM_PUT32(softs, &softs->ioa_reg->host_to_ioa_db, in sis_disable_msix()
42 OS_SLEEP(1000); /* 1 ms delay for PCI W/R ordering issue */ in sis_disable_msix()
54 db_reg = PCI_MEM_GET32(softs, &softs->ioa_reg->host_to_ioa_db, in sis_enable_intx()
57 PCI_MEM_PUT32(softs, &softs->ioa_reg->host_to_ioa_db, in sis_enable_intx()
59 OS_SLEEP(1000); /* 1 ms delay for PCI W/R ordering issue */ in sis_enable_intx()
74 db_reg = PCI_MEM_GET32(softs, &softs->ioa_reg->host_to_ioa_db, in sis_disable_intx()
77 PCI_MEM_PUT32(softs, &softs->ioa_reg->host_to_ioa_db, in sis_disable_intx()
[all …]
/freebsd/libexec/getty/
H A Dsubr.c1 /*-
2 * SPDX-License-Identifier: BSD-3-Clause
39 #include <poll.h>
78 for (sp = gettystrs; sp->field; sp++) in gettable()
79 if (sp->value != NULL) { in gettable()
84 l = strlen(sp->value) + 1; in gettable()
86 strlcpy(p, sp->value, l); in gettable()
91 sp->value = p; in gettable()
102 case -1: in gettable()
105 case -2: in gettable()
[all …]
/freebsd/sys/dev/msk/
H A Dif_mskreg.h17 * are provided to you under the BSD-type license terms provided
22 * - Redistributions of source code must retain the above copyright
24 * - Redistributions in binary form must reproduce the above
28 * - Neither the name of Marvell nor the names of its contributors
48 /*-
49 * SPDX-License-Identifier: BSD-4-Clause AND BSD-3-Clause
65 * 4. Neither the name of the author nor the names of any co-contributors
82 /*-
110 * D-Link PCI vendor ID
154 * D-Link gigabit ethernet device ID
[all …]
/freebsd/sys/dev/ufshci/
H A Dufshci_ctrlr.c1 /*-
5 * SPDX-License-Identifier: BSD-2-Clause
18 ctrlr->is_failed = true; in ufshci_ctrlr_fail()
21 ctrlr->task_mgmt_req_queue.qops.get_hw_queue( in ufshci_ctrlr_fail()
22 &ctrlr->task_mgmt_req_queue)); in ufshci_ctrlr_fail()
24 ctrlr->transfer_req_queue.qops.get_hw_queue( in ufshci_ctrlr_fail()
25 &ctrlr->transfer_req_queue)); in ufshci_ctrlr_fail()
35 * Re-enable request queues here because ufshci_ctrlr_reset_task() in ufshci_ctrlr_start()
76 if (!(ctrlr->quirks & UFSHCI_QUIRK_IGNORE_UIC_POWER_MODE) && in ufshci_ctrlr_start()
104 * If the reset is due to a timeout, it is already attached to the SIM in ufshci_ctrlr_start()
[all …]
/freebsd/sys/dev/imcsmb/
H A Dimcsmb.c1 /*-
2 * SPDX-License-Identifier: BSD-2-Clause
6 * Copyright (c) 2017-2018 Panasas
87 sc->dev = dev; in imcsmb_attach()
88 sc->imcsmb_pci = device_get_parent(dev); in imcsmb_attach()
89 sc->regs = device_get_ivars(dev); in imcsmb_attach()
92 sc->smbus = device_add_child(dev, "smbus", DEVICE_UNIT_ANY); in imcsmb_attach()
93 if (sc->smbus == NULL) { in imcsmb_attach()
157 rc = imcsmb_pci_request_bus(sc->imcsmb_pci); in imcsmb_callback()
161 imcsmb_pci_release_bus(sc->imcsmb_pci); in imcsmb_callback()
[all …]
/freebsd/secure/lib/libcrypto/man/man7/
H A Dossl-guide-quic-server-non-block.71 .\" -*- mode: troff; coding: utf-8 -*-
57 .IX Title "OSSL-GUIDE-QUIC-SERVER-NON-BLOCK 7ossl"
58 .TH OSSL-GUIDE-QUIC-SERVER-NON-BLOCK 7ossl 2025-09-30 3.5.4 OpenSSL
64 ossl\-guide\-quic\-server\-non\-block
65 \&\- OpenSSL Guide: Writing a simple nonblocking QUIC server
69 simple, non-concurrent, QUIC "echo" server application which accepts one client
73 The server only accepts \f(CW\*(C`http/1.0\*(C'\fR and \f(CW\*(C`hq\-interop\*(C'\fR ALPN's and doe…
74 implement HTTP but only does a simple echo. This is non-standard and will not
77 There are various methods to test this server: \fBquic\-client\-block.c\fR and
78 \&\fBquic\-client\-non\-block.c\fR will send a basic HTTP/1.0 request, which the server
[all …]
/freebsd/usr.sbin/bhyve/
H A Dlibslirp.h1 /*-
2 * SPDX-License-Identifier: BSD-3-Clause
113 /* Modify a timer to expire at @expire_time (ms) */
119 /* Kick the io-thread, to signal that new events may be processed because some TCP buffer
219 * MAC address allocated for an out-of-band management controller, to be
220 * retrieved through NC-SI.
245 /* This is called by the application when it is about to sleep through poll().
246 * *timeout is set to the amount of virtual time (in ms) that the application intends to
253 void slirp_pollfds_fill(Slirp *slirp, uint32_t *timeout,
261 * select_error should be passed 1 if poll() returned an error. */
[all …]
/freebsd/crypto/openssh/
H A Dmisc.c4 * Copyright (c) 2005-2020 Damien Miller. All rights reserved.
37 #include <poll.h>
104 for (i--; i > 0; i--) { in rtrim()
131 /* set/unset filedescriptor to non-blocking */
138 if (val == -1) { in set_nonblock()
140 return (-1); in set_nonblock()
148 if (fcntl(fd, F_SETFL, val) == -1) { in set_nonblock()
151 return (-1); in set_nonblock()
162 if (val == -1) { in unset_nonblock()
164 return (-1); in unset_nonblock()
[all …]

12345678