Author: yongari
Date: Wed May 15 00:58:45 2013
New Revision: 250644
URL: http://svnweb.freebsd.org/changeset/base/250644

Log:
  MFC r248227:
    Disable TX IP header checksum offloading on RL_HWREV_8168CP. The
    controller generates wrong checksummed frame if the IP packet has
    IP options.

Modified:
  stable/9/sys/dev/re/if_re.c
Directory Properties:
  stable/9/sys/   (props changed)
  stable/9/sys/dev/   (props changed)

Modified: stable/9/sys/dev/re/if_re.c
==============================================================================
--- stable/9/sys/dev/re/if_re.c Tue May 14 21:39:38 2013        (r250643)
+++ stable/9/sys/dev/re/if_re.c Wed May 15 00:58:45 2013        (r250644)
@@ -1587,7 +1587,8 @@ re_attach(device_t dev)
         * packet has IP options so disable TX IP checksum offloading.
         */
        if (sc->rl_hwrev->rl_rev == RL_HWREV_8168C ||
-           sc->rl_hwrev->rl_rev == RL_HWREV_8168C_SPIN2)
+           sc->rl_hwrev->rl_rev == RL_HWREV_8168C_SPIN2 ||
+           sc->rl_hwrev->rl_rev == RL_HWREV_8168CP)
                ifp->if_hwassist = CSUM_TCP | CSUM_UDP;
        else
                ifp->if_hwassist = CSUM_IP | CSUM_TCP | CSUM_UDP;
@@ -3415,7 +3416,8 @@ re_ioctl(struct ifnet *ifp, u_long comma
                        if ((ifp->if_capenable & IFCAP_TXCSUM) != 0) {
                                rev = sc->rl_hwrev->rl_rev;
                                if (rev == RL_HWREV_8168C ||
-                                   rev == RL_HWREV_8168C_SPIN2)
+                                   rev == RL_HWREV_8168C_SPIN2 ||
+                                   rev == RL_HWREV_8168CP)
                                        ifp->if_hwassist |= CSUM_TCP | CSUM_UDP;
                                else
                                        ifp->if_hwassist |= RE_CSUM_FEATURES;
_______________________________________________
svn-src-stable-9@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-stable-9
To unsubscribe, send any mail to "svn-src-stable-9-unsubscr...@freebsd.org"

Reply via email to