From a5820ecb77182475ae2e27f72a981d53fc739a99 Mon Sep 17 00:00:00 2001 From: Yaroslav Tykhiy Date: Sun, 23 May 2004 20:22:40 +0000 Subject: [PATCH] According to the design of checksum offloading framework, if_hwassist should be in accord with the IFCAP_TXCSUM bit of if_capenable. --- sys/dev/nge/if_nge.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/dev/nge/if_nge.c b/sys/dev/nge/if_nge.c index e8453b37a28..82b654d334d 100644 --- a/sys/dev/nge/if_nge.c +++ b/sys/dev/nge/if_nge.c @@ -2114,10 +2114,13 @@ nge_ioctl(ifp, command, data) * 8152 (TX FIFO size minus 64 minus 18), turn off * TX checksum offloading. */ - if (ifr->ifr_mtu >= 8152) + if (ifr->ifr_mtu >= 8152) { + ifp->if_capenable &= ~IFCAP_TXCSUM; ifp->if_hwassist = 0; - else + } else { + ifp->if_capenable |= IFCAP_TXCSUM; ifp->if_hwassist = NGE_CSUM_FEATURES; + } } break; case SIOCSIFFLAGS: