udp_var.h (266990) | udp_var.h (269699) |
---|---|
1/*- 2 * Copyright (c) 1982, 1986, 1989, 1993 3 * The Regents of the University of California. 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 14 unchanged lines hidden (view full) --- 23 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 24 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 25 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 26 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 27 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 28 * SUCH DAMAGE. 29 * 30 * @(#)udp_var.h 8.1 (Berkeley) 6/10/93 | 1/*- 2 * Copyright (c) 1982, 1986, 1989, 1993 3 * The Regents of the University of California. 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 14 unchanged lines hidden (view full) --- 23 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 24 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 25 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 26 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 27 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 28 * SUCH DAMAGE. 29 * 30 * @(#)udp_var.h 8.1 (Berkeley) 6/10/93 |
31 * $FreeBSD: head/sys/netinet/udp_var.h 266990 2014-06-03 01:30:32Z kevlo $ | 31 * $FreeBSD: head/sys/netinet/udp_var.h 269699 2014-08-08 01:57:15Z kevlo $ |
32 */ 33 34#ifndef _NETINET_UDP_VAR_H_ 35#define _NETINET_UDP_VAR_H_ 36 37/* 38 * UDP kernel structures and variables. 39 */ --- 103 unchanged lines hidden (view full) --- 143extern u_long udp_recvspace; 144VNET_DECLARE(int, udp_cksum); 145VNET_DECLARE(int, udp_blackhole); 146#define V_udp_cksum VNET(udp_cksum) 147#define V_udp_blackhole VNET(udp_blackhole) 148extern int udp_log_in_vain; 149 150static __inline struct inpcbinfo * | 32 */ 33 34#ifndef _NETINET_UDP_VAR_H_ 35#define _NETINET_UDP_VAR_H_ 36 37/* 38 * UDP kernel structures and variables. 39 */ --- 103 unchanged lines hidden (view full) --- 143extern u_long udp_recvspace; 144VNET_DECLARE(int, udp_cksum); 145VNET_DECLARE(int, udp_blackhole); 146#define V_udp_cksum VNET(udp_cksum) 147#define V_udp_blackhole VNET(udp_blackhole) 148extern int udp_log_in_vain; 149 150static __inline struct inpcbinfo * |
151get_inpcbinfo(uint8_t protocol) | 151get_inpcbinfo(int protocol) |
152{ 153 return (protocol == IPPROTO_UDP) ? &V_udbinfo : &V_ulitecbinfo; 154} 155 156static __inline struct inpcbhead * | 152{ 153 return (protocol == IPPROTO_UDP) ? &V_udbinfo : &V_ulitecbinfo; 154} 155 156static __inline struct inpcbhead * |
157get_pcblist(uint8_t protocol) | 157get_pcblist(int protocol) |
158{ 159 return (protocol == IPPROTO_UDP) ? &V_udb : &V_ulitecb; 160} 161 162int udp_newudpcb(struct inpcb *); 163void udp_discardcb(struct udpcb *); 164 165void udp_ctlinput(int, struct sockaddr *, void *); 166void udplite_ctlinput(int, struct sockaddr *, void *); 167int udp_ctloutput(struct socket *, struct sockopt *); 168void udp_init(void); 169void udplite_init(void); 170#ifdef VIMAGE 171void udp_destroy(void); 172void udplite_destroy(void); 173#endif | 158{ 159 return (protocol == IPPROTO_UDP) ? &V_udb : &V_ulitecb; 160} 161 162int udp_newudpcb(struct inpcb *); 163void udp_discardcb(struct udpcb *); 164 165void udp_ctlinput(int, struct sockaddr *, void *); 166void udplite_ctlinput(int, struct sockaddr *, void *); 167int udp_ctloutput(struct socket *, struct sockopt *); 168void udp_init(void); 169void udplite_init(void); 170#ifdef VIMAGE 171void udp_destroy(void); 172void udplite_destroy(void); 173#endif |
174void udp_input(struct mbuf *, int); | 174int udp_input(struct mbuf **, int *, int); |
175void udplite_input(struct mbuf *, int); 176struct inpcb *udp_notify(struct inpcb *inp, int errno); 177int udp_shutdown(struct socket *so); 178 179int udp_set_kernel_tunneling(struct socket *so, udp_tun_func_t f); 180 181#endif /* _KERNEL */ 182 183#endif /* _NETINET_UDP_VAR_H_ */ | 175void udplite_input(struct mbuf *, int); 176struct inpcb *udp_notify(struct inpcb *inp, int errno); 177int udp_shutdown(struct socket *so); 178 179int udp_set_kernel_tunneling(struct socket *so, udp_tun_func_t f); 180 181#endif /* _KERNEL */ 182 183#endif /* _NETINET_UDP_VAR_H_ */ |