summaryrefslogtreecommitdiff
path: root/sys/net
diff options
context:
space:
mode:
authorHenning Brauer <henning@cvs.openbsd.org>2014-05-05 10:00:46 +0000
committerHenning Brauer <henning@cvs.openbsd.org>2014-05-05 10:00:46 +0000
commitcab29488d153d7baf53b5bcc325170124da381a6 (patch)
tree1978f9c7546cc0e85306873bea827579b1d36069 /sys/net
parent75d9a121d99dc142fb7877379257a8b848f1dfe2 (diff)
remove dead code: calling ether_attach which sets if_type to IFT_ETHER,
just to set it to IFT_L2VLAN right afterwards, just to set if_type to the parent's if_type which can be anything as long as it is IFT_ETHER at config time doesn't make any sense and has zero effect. stop fiddling with if_type alltogether. also remove a question in a comment that has been answered by the last 14 years. from Marrakesh airport, ok reyk
Diffstat (limited to 'sys/net')
-rw-r--r--sys/net/if_vlan.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/sys/net/if_vlan.c b/sys/net/if_vlan.c
index 2c9bb1284cf..3a58d4d6e3f 100644
--- a/sys/net/if_vlan.c
+++ b/sys/net/if_vlan.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_vlan.c,v 1.103 2014/04/22 11:43:07 henning Exp $ */
+/* $OpenBSD: if_vlan.c,v 1.104 2014/05/05 10:00:45 henning Exp $ */
/*
* Copyright 1998 Massachusetts Institute of Technology
@@ -151,8 +151,6 @@ vlan_clone_create(struct if_clone *ifc, int unit)
IFQ_SET_READY(&ifp->if_snd);
if_attach(ifp);
ether_ifattach(ifp);
- /* Now undo some of the damage... */
- ifp->if_type = IFT_L2VLAN;
ifp->if_hdrlen = EVL_ENCAPLEN;
ifp->if_output = vlan_output;
@@ -374,12 +372,6 @@ vlan_config(struct ifvlan *ifv, struct ifnet *p, u_int16_t tag)
}
/*
- * Inherit the if_type from the parent. This allows us to
- * participate in bridges of that type.
- */
- ifv->ifv_if.if_type = p->if_type;
-
- /*
* Inherit baudrate from the parent. An SNMP agent would use this
* information.
*/
@@ -392,9 +384,6 @@ vlan_config(struct ifvlan *ifv, struct ifnet *p, u_int16_t tag)
*
* If the card cannot handle hardware tagging, it cannot
* possibly compute the correct checksums for tagged packets.
- *
- * This brings up another possibility, do cards exist which
- * have all of these capabilities but cannot utilize them together?
*/
if (p->if_capabilities & IFCAP_VLAN_HWTAGGING)
ifv->ifv_if.if_capabilities = p->if_capabilities &