diff options
author | Brad Smith <brad@cvs.openbsd.org> | 2005-04-18 00:04:12 +0000 |
---|---|---|
committer | Brad Smith <brad@cvs.openbsd.org> | 2005-04-18 00:04:12 +0000 |
commit | 84b94cc5f443e362f89cff711c3cb520358ec716 (patch) | |
tree | 39a7c117e6729a38f318462e67db971efaeb997d /sys/dev/pci/if_ti.c | |
parent | 7543a315d882308d72be69e1a207f521fad9bc02 (diff) |
- check for ETHERMIN with SIOCSIFMTU ioctl case
- don't need to trim off anything but the VLID bits in the driver anymore
Diffstat (limited to 'sys/dev/pci/if_ti.c')
-rw-r--r-- | sys/dev/pci/if_ti.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/dev/pci/if_ti.c b/sys/dev/pci/if_ti.c index 24cffee0735..93f02c5cc10 100644 --- a/sys/dev/pci/if_ti.c +++ b/sys/dev/pci/if_ti.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_ti.c,v 1.58 2004/12/08 07:04:12 jsg Exp $ */ +/* $OpenBSD: if_ti.c,v 1.59 2005/04/18 00:04:11 brad Exp $ */ /* * Copyright (c) 1997, 1998, 1999 @@ -1822,7 +1822,7 @@ void ti_rxeof(sc) #if NVLAN > 0 if (cur_rx->ti_flags & TI_BDFLAG_VLAN_TAG) { have_tag = 1; - vlan_tag = cur_rx->ti_vlan_tag & 0xfff; + vlan_tag = cur_rx->ti_vlan_tag; } #endif @@ -2139,7 +2139,7 @@ int ti_encap_tigon1(sc, m_head, txidx) #if NVLAN > 0 if (ifv != NULL) { txdesc.ti_flags |= TI_BDFLAG_VLAN_TAG; - txdesc.ti_vlan_tag = ifv->ifv_tag & 0xfff; + txdesc.ti_vlan_tag = ifv->ifv_tag; } #endif @@ -2227,7 +2227,7 @@ int ti_encap_tigon2(sc, m_head, txidx) #if NVLAN > 0 if (ifv != NULL) { f->ti_flags |= TI_BDFLAG_VLAN_TAG; - f->ti_vlan_tag = ifv->ifv_tag & 0xfff; + f->ti_vlan_tag = ifv->ifv_tag; } else { f->ti_vlan_tag = 0; } @@ -2584,7 +2584,7 @@ int ti_ioctl(ifp, command, data) } break; case SIOCSIFMTU: - if (ifr->ifr_mtu > ETHERMTU_JUMBO) { + if (ifr->ifr_mtu < ETHERMIN || ifr->ifr_mtu > ETHERMTU_JUMBO) { error = EINVAL; } else { ifp->if_mtu = ifr->ifr_mtu; |