1 /*- 2 * SPDX-License-Identifier: BSD-3-Clause 3 * 4 * Copyright (c) 2008-2012, by Randall Stewart. All rights reserved. 5 * Copyright (c) 2008-2012, by Michael Tuexen. All rights reserved. 6 * 7 * Redistribution and use in source and binary forms, with or without 8 * modification, are permitted provided that the following conditions are met: 9 * 10 * a) Redistributions of source code must retain the above copyright notice, 11 * this list of conditions and the following disclaimer. 12 * 13 * b) Redistributions in binary form must reproduce the above copyright 14 * notice, this list of conditions and the following disclaimer in 15 * the documentation and/or other materials provided with the distribution. 16 * 17 * c) Neither the name of Cisco Systems, Inc. nor the names of its 18 * contributors may be used to endorse or promote products derived 19 * from this software without specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 22 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 23 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE 25 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 34 #include <sys/cdefs.h> 35 #ifndef _NETINET_SCTP_KDTRACE_H_ 36 #define _NETINET_SCTP_KDTRACE_H_ 37 38 #include <sys/kernel.h> 39 #include <sys/sdt.h> 40 41 #define SCTP_PROBE1(probe, arg0) \ 42 SDT_PROBE1(sctp, , , probe, arg0) 43 #define SCTP_PROBE2(probe, arg0, arg1) \ 44 SDT_PROBE2(sctp, , , probe, arg0, arg1) 45 #define SCTP_PROBE3(probe, arg0, arg1, arg2) \ 46 SDT_PROBE3(sctp, , , probe, arg0, arg1, arg2) 47 #define SCTP_PROBE4(probe, arg0, arg1, arg2, arg3) \ 48 SDT_PROBE4(sctp, , , probe, arg0, arg1, arg2, arg3) 49 #define SCTP_PROBE5(probe, arg0, arg1, arg2, arg3, arg4) \ 50 SDT_PROBE5(sctp, , , probe, arg0, arg1, arg2, arg3, arg4) 51 #define SCTP_PROBE6(probe, arg0, arg1, arg2, arg3, arg4, arg5) \ 52 SDT_PROBE6(sctp, , , probe, arg0, arg1, arg2, arg3, arg4, arg5) 53 54 /* Declare the SCTP provider */ 55 SDT_PROVIDER_DECLARE(sctp); 56 57 /* The probes we have so far: */ 58 59 /* One to track a net's cwnd */ 60 /* initial */ 61 SDT_PROBE_DECLARE(sctp, cwnd, net, init); 62 /* update at a ack -- increase */ 63 SDT_PROBE_DECLARE(sctp, cwnd, net, ack); 64 /* update at a fast retransmit -- decrease */ 65 SDT_PROBE_DECLARE(sctp, cwnd, net, fr); 66 /* update at a time-out -- decrease */ 67 SDT_PROBE_DECLARE(sctp, cwnd, net, to); 68 /* update at a burst-limit -- decrease */ 69 SDT_PROBE_DECLARE(sctp, cwnd, net, bl); 70 /* update at a ECN -- decrease */ 71 SDT_PROBE_DECLARE(sctp, cwnd, net, ecn); 72 /* update at a Packet-Drop -- decrease */ 73 SDT_PROBE_DECLARE(sctp, cwnd, net, pd); 74 /* Rttvar probe declaration */ 75 SDT_PROBE_DECLARE(sctp, cwnd, net, rttvar); 76 SDT_PROBE_DECLARE(sctp, cwnd, net, rttstep); 77 /* One to track an associations rwnd */ 78 SDT_PROBE_DECLARE(sctp, rwnd, assoc, val); 79 /* One to track a net's flight size */ 80 SDT_PROBE_DECLARE(sctp, flightsize, net, val); 81 /* One to track an associations flight size */ 82 SDT_PROBE_DECLARE(sctp, flightsize, assoc, val); 83 /* Standard Solaris compatible probes */ 84 SDT_PROBE_DECLARE(sctp,,, receive); 85 SDT_PROBE_DECLARE(sctp,,, send); 86 SDT_PROBE_DECLARE(sctp,,, state__change); 87 88 #endif 89