summaryrefslogtreecommitdiff
path: root/sys/dev/pci/if_vic.c
diff options
context:
space:
mode:
authorBrad Smith <brad@cvs.openbsd.org>2006-05-28 00:20:22 +0000
committerBrad Smith <brad@cvs.openbsd.org>2006-05-28 00:20:22 +0000
commitaf88527ffe750f4fc35af70bb81fbfd68e129ace (patch)
tree0ab28a440b9de954f9aed386febe09d2908b7f38 /sys/dev/pci/if_vic.c
parentf32ef14b7e0390d427153634ede40cc7b15599a4 (diff)
- remove ETHER_MAX_LEN_JUMBO and ETHERMTU_JUMBO.
- use if_hardmtu for MTU ioctl handlers. ok reyk@
Diffstat (limited to 'sys/dev/pci/if_vic.c')
-rw-r--r--sys/dev/pci/if_vic.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/pci/if_vic.c b/sys/dev/pci/if_vic.c
index 48b5a3ceb68..1f795490bcf 100644
--- a/sys/dev/pci/if_vic.c
+++ b/sys/dev/pci/if_vic.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_vic.c,v 1.7 2006/05/28 00:04:24 jason Exp $ */
+/* $OpenBSD: if_vic.c,v 1.8 2006/05/28 00:20:21 brad Exp $ */
/*
* Copyright (c) 2006 Reyk Floeter <reyk@openbsd.org>
@@ -191,6 +191,7 @@ vic_attach(struct device *parent, struct device *self, void *aux)
ifp->if_ioctl = vic_ioctl;
ifp->if_start = vic_start;
ifp->if_watchdog = vic_watchdog;
+ ifp->if_hardmtu = VIC_JUMBO_MTU;
strlcpy(ifp->if_xname, sc->sc_dev.dv_xname, IFNAMSIZ);
IFQ_SET_MAXLEN(&ifp->if_snd, ifqmaxlen);
IFQ_SET_READY(&ifp->if_snd);
@@ -664,7 +665,7 @@ vic_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
break;
case SIOCSIFMTU:
- if (ifr->ifr_mtu < ETHERMIN || ifr->ifr_mtu > ETHERMTU_JUMBO)
+ if (ifr->ifr_mtu < ETHERMIN || ifr->ifr_mtu > ifp->if_hardmtu)
error = EINVAL;
else if (ifp->if_mtu != ifr->ifr_mtu)
ifp->if_mtu = ifr->ifr_mtu;