Author: hselasky
Date: Mon Feb  2 17:32:50 2015
New Revision: 278103
URL: https://svnweb.freebsd.org/changeset/base/278103

Log:
  The flowid and hashtype should be copied from the originating packet
  when fragmenting IP packets to preserve the order of the packets in a
  stream. Else the resulting fragments can be sent out of order when the
  hardware supports multiple transmit rings.
  
  Reviewed by:  glebius @
  MFC after:    1 week
  Sponsored by: Mellanox Technologies

Modified:
  head/sys/netinet/ip_output.c

Modified: head/sys/netinet/ip_output.c
==============================================================================
--- head/sys/netinet/ip_output.c        Mon Feb  2 16:19:11 2015        
(r278102)
+++ head/sys/netinet/ip_output.c        Mon Feb  2 17:32:50 2015        
(r278103)
@@ -789,6 +789,10 @@ smart_frag_failure:
                        IPSTAT_INC(ips_odropped);
                        goto done;
                }
+               /* make sure the flowid is the same for the fragmented mbufs */
+               M_HASHTYPE_SET(m, M_HASHTYPE_GET(m0));
+               m->m_pkthdr.flowid = m0->m_pkthdr.flowid;
+               /* copy multicast flag, if any */
                m->m_flags |= (m0->m_flags & M_MCAST);
                /*
                 * In the first mbuf, leave room for the link header, then
_______________________________________________
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to