svn commit: r242354 - in user/andre/tcp_workqueue/sys: dev/bce dev/bxe net netinet netpfil/pf sys
Andre Oppermann
andre at FreeBSD.org
Tue Oct 30 11:15:37 UTC 2012
Author: andre
Date: Tue Oct 30 11:15:36 2012
New Revision: 242354
URL: http://svn.freebsd.org/changeset/base/242354
Log:
Rename unused CSUM_FRAGMENT offload capability to CSUM_IPFRAG to
make clear is an IPv4 feature.
No driver currently in the tree supports IP fragmentation offloading.
It should be implementable in some of them though.
Modified:
user/andre/tcp_workqueue/sys/dev/bce/if_bce.c
user/andre/tcp_workqueue/sys/dev/bxe/if_bxe.c
user/andre/tcp_workqueue/sys/net/if_vlan.c
user/andre/tcp_workqueue/sys/netinet/ip_fastfwd.c
user/andre/tcp_workqueue/sys/netinet/ip_output.c
user/andre/tcp_workqueue/sys/netpfil/pf/pf.c
user/andre/tcp_workqueue/sys/sys/mbuf.h
Modified: user/andre/tcp_workqueue/sys/dev/bce/if_bce.c
==============================================================================
--- user/andre/tcp_workqueue/sys/dev/bce/if_bce.c Tue Oct 30 11:01:25 2012 (r242353)
+++ user/andre/tcp_workqueue/sys/dev/bce/if_bce.c Tue Oct 30 11:15:36 2012 (r242354)
@@ -9881,7 +9881,7 @@ bce_dump_mbuf(struct bce_softc *sc, stru
"\22M_PROMISC\23M_NOFREE",
mp->m_pkthdr.csum_flags,
"\20\1CSUM_IP\2CSUM_TCP\3CSUM_UDP\4CSUM_IP_FRAGS"
- "\5CSUM_FRAGMENT\6CSUM_TSO\11CSUM_IP_CHECKED"
+ "\6CSUM_TSO\11CSUM_IP_CHECKED"
"\12CSUM_IP_VALID\13CSUM_DATA_VALID"
"\14CSUM_PSEUDO_HDR");
}
Modified: user/andre/tcp_workqueue/sys/dev/bxe/if_bxe.c
==============================================================================
--- user/andre/tcp_workqueue/sys/dev/bxe/if_bxe.c Tue Oct 30 11:01:25 2012 (r242353)
+++ user/andre/tcp_workqueue/sys/dev/bxe/if_bxe.c Tue Oct 30 11:15:36 2012 (r242354)
@@ -16282,7 +16282,7 @@ void bxe_dump_mbuf(struct bxe_softc *sc,
"\22M_PROMISC\23M_NOFREE",
m->m_pkthdr.csum_flags,
"\20\1CSUM_IP\2CSUM_TCP\3CSUM_UDP\4CSUM_IP_FRAGS"
- "\5CSUM_FRAGMENT\6CSUM_TSO\11CSUM_IP_CHECKED"
+ "\6CSUM_TSO\11CSUM_IP_CHECKED"
"\12CSUM_IP_VALID\13CSUM_DATA_VALID"
"\14CSUM_PSEUDO_HDR");
}
Modified: user/andre/tcp_workqueue/sys/net/if_vlan.c
==============================================================================
--- user/andre/tcp_workqueue/sys/net/if_vlan.c Tue Oct 30 11:01:25 2012 (r242353)
+++ user/andre/tcp_workqueue/sys/net/if_vlan.c Tue Oct 30 11:15:36 2012 (r242354)
@@ -1493,7 +1493,7 @@ vlan_capabilities(struct ifvlan *ifv)
p->if_capenable & IFCAP_VLAN_HWTAGGING) {
ifp->if_capenable = p->if_capenable & IFCAP_HWCSUM;
ifp->if_hwassist = p->if_hwassist & (CSUM_IP | CSUM_TCP |
- CSUM_UDP | CSUM_SCTP | CSUM_FRAGMENT);
+ CSUM_UDP | CSUM_SCTP | CSUM_IPFRAG);
} else {
ifp->if_capenable = 0;
ifp->if_hwassist = 0;
Modified: user/andre/tcp_workqueue/sys/netinet/ip_fastfwd.c
==============================================================================
--- user/andre/tcp_workqueue/sys/netinet/ip_fastfwd.c Tue Oct 30 11:01:25 2012 (r242353)
+++ user/andre/tcp_workqueue/sys/netinet/ip_fastfwd.c Tue Oct 30 11:15:36 2012 (r242354)
@@ -522,7 +522,7 @@ passout:
mtu = ifp->if_mtu;
if (ip_len <= mtu ||
- (ifp->if_hwassist & CSUM_FRAGMENT && (ip_off & IP_DF) == 0)) {
+ (ifp->if_hwassist & CSUM_IPFRAG && (ip_off & IP_DF) == 0)) {
/*
* Send off the packet via outgoing interface
*/
Modified: user/andre/tcp_workqueue/sys/netinet/ip_output.c
==============================================================================
--- user/andre/tcp_workqueue/sys/netinet/ip_output.c Tue Oct 30 11:01:25 2012 (r242353)
+++ user/andre/tcp_workqueue/sys/netinet/ip_output.c Tue Oct 30 11:15:36 2012 (r242354)
@@ -601,7 +601,7 @@ passout:
*/
if (ip_len <= mtu ||
(m->m_pkthdr.csum_flags & ifp->if_hwassist & CSUM_TSO) != 0 ||
- ((ip_off & IP_DF) == 0 && (ifp->if_hwassist & CSUM_FRAGMENT))) {
+ ((ip_off & IP_DF) == 0 && (ifp->if_hwassist & CSUM_IPFRAG))) {
ip->ip_sum = 0;
if (m->m_pkthdr.csum_flags & CSUM_IP & ~ifp->if_hwassist) {
ip->ip_sum = in_cksum(m, hlen);
Modified: user/andre/tcp_workqueue/sys/netpfil/pf/pf.c
==============================================================================
--- user/andre/tcp_workqueue/sys/netpfil/pf/pf.c Tue Oct 30 11:01:25 2012 (r242353)
+++ user/andre/tcp_workqueue/sys/netpfil/pf/pf.c Tue Oct 30 11:15:36 2012 (r242354)
@@ -5257,7 +5257,7 @@ pf_route(struct mbuf **m, struct pf_rule
*/
if (ip_len <= ifp->if_mtu ||
(m0->m_pkthdr.csum_flags & ifp->if_hwassist & CSUM_TSO) != 0 ||
- ((ip_off & IP_DF) == 0 && (ifp->if_hwassist & CSUM_FRAGMENT))) {
+ ((ip_off & IP_DF) == 0 && (ifp->if_hwassist & CSUM_IPFRAG))) {
ip->ip_sum = 0;
if (m0->m_pkthdr.csum_flags & CSUM_IP & ~ifp->if_hwassist) {
ip->ip_sum = in_cksum(m0, ip->ip_hl << 2);
Modified: user/andre/tcp_workqueue/sys/sys/mbuf.h
==============================================================================
--- user/andre/tcp_workqueue/sys/sys/mbuf.h Tue Oct 30 11:01:25 2012 (r242353)
+++ user/andre/tcp_workqueue/sys/sys/mbuf.h Tue Oct 30 11:15:36 2012 (r242354)
@@ -279,8 +279,8 @@ struct mbuf {
#define CSUM_IP 0x0001 /* will csum IP */
#define CSUM_TCP 0x0002 /* will csum TCP */
#define CSUM_UDP 0x0004 /* will csum UDP */
-/* 0x0008 */
-#define CSUM_FRAGMENT 0x0010 /* will do IP fragmentation */
+#define CSUM_IPFRAG 0x0008 /* IP fragmentation offload */
+/* 0x0010 */
#define CSUM_TSO 0x0020 /* will do TSO */
#define CSUM_SCTP 0x0040 /* will csum SCTP */
#define CSUM_SCTP_IPV6 0x0080 /* will csum IPv6/SCTP */
More information about the svn-src-user
mailing list