diff options
author | kmacy <kmacy@FreeBSD.org> | 2007-04-12 03:07:24 +0000 |
---|---|---|
committer | kmacy <kmacy@FreeBSD.org> | 2007-04-12 03:07:24 +0000 |
commit | 560360bd840c02c145c5d592347a189451e6c20c (patch) | |
tree | f2dc270bee1a1673b87d6f9e40d6996dde3669ad /sys/dev | |
parent | e143d4410166510509c5502bbf81f75c582c0ba0 (diff) | |
download | FreeBSD-src-560360bd840c02c145c5d592347a189451e6c20c.zip FreeBSD-src-560360bd840c02c145c5d592347a189451e6c20c.tar.gz |
Add ETHER_HDR_LEN to hardware accepted mtu
MFC after: 3 days
Diffstat (limited to 'sys/dev')
-rw-r--r-- | sys/dev/cxgb/cxgb_main.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/cxgb/cxgb_main.c b/sys/dev/cxgb/cxgb_main.c index 49084e4..937fb10 100644 --- a/sys/dev/cxgb/cxgb_main.c +++ b/sys/dev/cxgb/cxgb_main.c @@ -1015,7 +1015,7 @@ cxgb_link_start(struct port_info *p) t3_init_rx_mode(&rm, p); t3_mac_reset(mac); - t3_mac_set_mtu(mac, ifp->if_mtu); + t3_mac_set_mtu(mac, ifp->if_mtu + ETHER_HDR_LEN); t3_mac_set_address(mac, 0, p->hw_addr); t3_mac_set_rx_mode(mac, &rm); t3_link_start(&p->phy, mac, &p->link_config); @@ -1196,7 +1196,7 @@ cxgb_ioctl(struct ifnet *ifp, unsigned long command, caddr_t data) else if (ifp->if_mtu != ifr->ifr_mtu) { PORT_LOCK(p); ifp->if_mtu = ifr->ifr_mtu; - t3_mac_set_mtu(&p->mac, ifp->if_mtu); + t3_mac_set_mtu(&p->mac, ifp->if_mtu + ETHER_HDR_LEN); PORT_UNLOCK(p); } break; @@ -1470,7 +1470,7 @@ check_t3b2_mac(struct adapter *adapter) else if (status == 2) { struct cmac *mac = &p->mac; - t3_mac_set_mtu(mac, ifp->if_mtu); + t3_mac_set_mtu(mac, ifp->if_mtu + ETHER_HDR_LEN); t3_mac_set_address(mac, 0, p->hw_addr); cxgb_set_rxmode(p); t3_link_start(&p->phy, mac, &p->link_config); |