move {tcp,udp}_do_loopback_cksum back to tcp/udp
so that they can be referenced by ipv6.
This commit is contained in:
parent
8220c378e6
commit
f02551ec2d
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: in_offload.h,v 1.1 2005/04/18 21:55:06 yamt Exp $ */
|
||||
/* $NetBSD: in_offload.h,v 1.2 2005/08/10 13:06:49 yamt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c)2005 YAMAMOTO Takashi,
|
||||
@ -26,13 +26,23 @@
|
||||
* SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#if !defined(_NETINET_IN_OFFLOAD_H_)
|
||||
#define _NETINET_IN_OFFLOAD_H_
|
||||
|
||||
/*
|
||||
* subroutines to do software-only equivalent of h/w offloading.
|
||||
*/
|
||||
|
||||
#if !defined(_NETINET_IN_OFFLOAD_H_)
|
||||
#define _NETINET_IN_OFFLOAD_H_
|
||||
|
||||
int tcp4_segment(struct mbuf *, int (*)(void *, struct mbuf *), void *);
|
||||
|
||||
/*
|
||||
* offloading related sysctl variables.
|
||||
*
|
||||
* they are here because it violates protocol layering in unusual way.
|
||||
* ie. while they are TCP/UDP sysctls, they are used by IP layer.
|
||||
*/
|
||||
|
||||
extern int tcp_do_loopback_cksum; /* do TCP checksum on loopback? */
|
||||
extern int udp_do_loopback_cksum; /* do UDP checksum on loopback? */
|
||||
|
||||
#endif /* !defined(_NETINET_IN_OFFLOAD_H_) */
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: ip_output.c,v 1.153 2005/05/29 21:41:23 christos Exp $ */
|
||||
/* $NetBSD: ip_output.c,v 1.154 2005/08/10 13:06:49 yamt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
|
||||
@ -98,7 +98,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: ip_output.c,v 1.153 2005/05/29 21:41:23 christos Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: ip_output.c,v 1.154 2005/08/10 13:06:49 yamt Exp $");
|
||||
|
||||
#include "opt_pfil_hooks.h"
|
||||
#include "opt_inet.h"
|
||||
@ -159,8 +159,6 @@ static void ip_mloopback(struct ifnet *, struct mbuf *, struct sockaddr_in *);
|
||||
extern struct pfil_head inet_pfil_hook; /* XXX */
|
||||
#endif
|
||||
|
||||
int udp_do_loopback_cksum = 0;
|
||||
int tcp_do_loopback_cksum = 0;
|
||||
int ip_do_loopback_cksum = 0;
|
||||
|
||||
#define IN_NEED_CHECKSUM(ifp, csum_flags) \
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: tcp_input.c,v 1.232 2005/08/10 13:05:16 yamt Exp $ */
|
||||
/* $NetBSD: tcp_input.c,v 1.233 2005/08/10 13:06:49 yamt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
|
||||
@ -150,7 +150,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: tcp_input.c,v 1.232 2005/08/10 13:05:16 yamt Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: tcp_input.c,v 1.233 2005/08/10 13:06:49 yamt Exp $");
|
||||
|
||||
#include "opt_inet.h"
|
||||
#include "opt_ipsec.h"
|
||||
@ -183,6 +183,7 @@ __KERNEL_RCSID(0, "$NetBSD: tcp_input.c,v 1.232 2005/08/10 13:05:16 yamt Exp $")
|
||||
#include <netinet/in_pcb.h>
|
||||
#include <netinet/in_var.h>
|
||||
#include <netinet/ip_var.h>
|
||||
#include <netinet/in_offload.h>
|
||||
|
||||
#ifdef INET6
|
||||
#ifndef INET
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: tcp_subr.c,v 1.194 2005/08/10 13:05:16 yamt Exp $ */
|
||||
/* $NetBSD: tcp_subr.c,v 1.195 2005/08/10 13:06:49 yamt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
|
||||
@ -98,7 +98,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: tcp_subr.c,v 1.194 2005/08/10 13:05:16 yamt Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: tcp_subr.c,v 1.195 2005/08/10 13:06:49 yamt Exp $");
|
||||
|
||||
#include "opt_inet.h"
|
||||
#include "opt_ipsec.h"
|
||||
@ -200,6 +200,7 @@ int tcp_compat_42 = 0;
|
||||
#endif
|
||||
int tcp_rst_ppslim = 100; /* 100pps */
|
||||
int tcp_ackdrop_ppslim = 100; /* 100pps */
|
||||
int tcp_do_loopback_cksum = 0;
|
||||
int tcp_sack_tp_maxholes = 32;
|
||||
int tcp_sack_globalmaxholes = 1024;
|
||||
int tcp_sack_globalholes = 0;
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: tcp_usrreq.c,v 1.107 2005/08/05 09:21:26 elad Exp $ */
|
||||
/* $NetBSD: tcp_usrreq.c,v 1.108 2005/08/10 13:06:49 yamt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
|
||||
@ -100,7 +100,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: tcp_usrreq.c,v 1.107 2005/08/05 09:21:26 elad Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: tcp_usrreq.c,v 1.108 2005/08/10 13:06:49 yamt Exp $");
|
||||
|
||||
#include "opt_inet.h"
|
||||
#include "opt_ipsec.h"
|
||||
@ -130,6 +130,7 @@ __KERNEL_RCSID(0, "$NetBSD: tcp_usrreq.c,v 1.107 2005/08/05 09:21:26 elad Exp $"
|
||||
#include <netinet/ip.h>
|
||||
#include <netinet/in_pcb.h>
|
||||
#include <netinet/ip_var.h>
|
||||
#include <netinet/in_offload.h>
|
||||
|
||||
#ifdef INET6
|
||||
#ifndef INET
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: tcp_var.h,v 1.128 2005/08/05 09:21:26 elad Exp $ */
|
||||
/* $NetBSD: tcp_var.h,v 1.129 2005/08/10 13:06:49 yamt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
|
||||
@ -729,7 +729,6 @@ extern int tcp_ack_on_push; /* ACK immediately on PUSH */
|
||||
extern int tcp_syn_cache_limit; /* max entries for compressed state engine */
|
||||
extern int tcp_syn_bucket_limit;/* max entries per hash bucket */
|
||||
extern int tcp_log_refused; /* log refused connections */
|
||||
extern int tcp_do_loopback_cksum;/* do TCP checksum on loopback? */
|
||||
extern int tcp_sack_tp_maxholes; /* Max holes per connection. */
|
||||
extern int tcp_sack_globalmaxholes; /* Max holes per system. */
|
||||
extern int tcp_sack_globalholes; /* Number of holes present. */
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: udp_usrreq.c,v 1.140 2005/08/10 13:05:17 yamt Exp $ */
|
||||
/* $NetBSD: udp_usrreq.c,v 1.141 2005/08/10 13:06:49 yamt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
|
||||
@ -61,7 +61,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: udp_usrreq.c,v 1.140 2005/08/10 13:05:17 yamt Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: udp_usrreq.c,v 1.141 2005/08/10 13:06:49 yamt Exp $");
|
||||
|
||||
#include "opt_inet.h"
|
||||
#include "opt_ipsec.h"
|
||||
@ -146,6 +146,7 @@ int udpcksum = 1;
|
||||
#else
|
||||
int udpcksum = 0; /* XXX */
|
||||
#endif
|
||||
int udp_do_loopback_cksum = 0;
|
||||
|
||||
struct inpcbtable udbtable;
|
||||
struct udpstat udpstat;
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: udp_var.h,v 1.28 2005/08/05 09:21:26 elad Exp $ */
|
||||
/* $NetBSD: udp_var.h,v 1.29 2005/08/10 13:06:49 yamt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1982, 1986, 1989, 1993
|
||||
@ -87,7 +87,6 @@ struct udpstat {
|
||||
#ifdef _KERNEL
|
||||
extern struct inpcbtable udbtable;
|
||||
extern struct udpstat udpstat;
|
||||
extern int udp_do_loopback_cksum;
|
||||
|
||||
#ifdef __NO_STRICT_ALIGNMENT
|
||||
#define UDP_HDR_ALIGNED_P(uh) 1
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: udp6_usrreq.c,v 1.68 2005/05/29 21:43:51 christos Exp $ */
|
||||
/* $NetBSD: udp6_usrreq.c,v 1.69 2005/08/10 13:06:49 yamt Exp $ */
|
||||
/* $KAME: udp6_usrreq.c,v 1.86 2001/05/27 17:33:00 itojun Exp $ */
|
||||
|
||||
/*
|
||||
@ -62,7 +62,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: udp6_usrreq.c,v 1.68 2005/05/29 21:43:51 christos Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: udp6_usrreq.c,v 1.69 2005/08/10 13:06:49 yamt Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/malloc.h>
|
||||
@ -95,6 +95,7 @@ __KERNEL_RCSID(0, "$NetBSD: udp6_usrreq.c,v 1.68 2005/05/29 21:43:51 christos Ex
|
||||
#include <netinet/icmp6.h>
|
||||
#include <netinet6/udp6_var.h>
|
||||
#include <netinet6/ip6protosw.h>
|
||||
#include <netinet/in_offload.h>
|
||||
|
||||
#include "faith.h"
|
||||
#if defined(NFAITH) && NFAITH > 0
|
||||
|
Loading…
Reference in New Issue
Block a user