mirror of
https://github.com/opnsense/src.git
synced 2026-04-04 08:55:18 -04:00
The timespecadd(3) family of macros were imported from NetBSD back in r35029. However, they were initially guarded by #ifdef _KERNEL. In the meantime, we have grown at least 28 syscalls that use timespecs in some way, leading many programs both inside and outside of the base system to redefine those macros. It's better just to make the definitions public. Our kernel currently defines two-argument versions of timespecadd and timespecsub. NetBSD, OpenBSD, and FreeDesktop.org's libbsd, however, define three-argument versions. Solaris also defines a three-argument version, but only in its kernel. This revision changes our definition to match the common three-argument version. Bump _FreeBSD_version due to the breaking KPI change. Discussed with: cem, jilles, ian, bde Differential Revision: https://reviews.freebsd.org/D14725 |
||
|---|---|---|
| .. | ||
| http | ||
| httpd | ||
| juggle | ||
| netblast | ||
| netreceive | ||
| netsend | ||
| tcpconnect | ||
| tcpp | ||
| tcpreceive | ||
| Makefile | ||
| Makefile.inc | ||
| README | ||
Netsend and Netreceive ---------------------- This pair of binaries is used to fixed rate UDP performance testing. The netreceive tool consists solely of a UDP packet sink bound to a specified UDP port. Packets received on its port are copied to user space and discarded. The netsend tool acts as a packet source, generating packets of the specified size at the specified rate to a target IP address and port number: netsend [ip] [port] [payloadsize] [rate] [duration] The payloadsize field specifies the size of the UDP payload, not the total packet size, which will also include a variety of headers (typically, ethernet, IP, and UDP). The rate indicates the number of packets/second to attempt to deliver. The duration is the duration of the run in seconds. The netsend tool will wait for around two seconds to synchronize with the wall clock for timing purposes. It will then busy-wait between packet transmits. The netsend/netreceive tools are under the following copyright and license: /*- * Copyright (c) 2004 Robert N. M. Watson * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. */ $FreeBSD$