Deleted Added
full compact
if_vlan.c (129748) if_vlan.c (130549)
1/*
2 * Copyright 1998 Massachusetts Institute of Technology
3 *
4 * Permission to use, copy, modify, and distribute this software and
5 * its documentation for any purpose and without fee is hereby
6 * granted, provided that both the above copyright notice and this
7 * permission notice appear in all copies, that both the above
8 * copyright notice and this permission notice appear in all

--- 12 unchanged lines hidden (view full) ---

21 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
22 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
23 * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
24 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
25 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
26 * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 * SUCH DAMAGE.
28 *
1/*
2 * Copyright 1998 Massachusetts Institute of Technology
3 *
4 * Permission to use, copy, modify, and distribute this software and
5 * its documentation for any purpose and without fee is hereby
6 * granted, provided that both the above copyright notice and this
7 * permission notice appear in all copies, that both the above
8 * copyright notice and this permission notice appear in all

--- 12 unchanged lines hidden (view full) ---

21 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
22 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
23 * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
24 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
25 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
26 * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 * SUCH DAMAGE.
28 *
29 * $FreeBSD: head/sys/net/if_vlan.c 129748 2004-05-26 11:41:26Z yar $
29 * $FreeBSD: head/sys/net/if_vlan.c 130549 2004-06-15 23:57:42Z mlaier $
30 */
31
32/*
33 * if_vlan.c - pseudo-device driver for IEEE 802.1Q virtual LANs.
34 * Might be extended some day to also handle IEEE 802.1p priority
35 * tagging. This is sort of sneaky in the implementation, since
36 * we need to pretend to be enough of an Ethernet implementation
37 * to make arp work. The way we do this is by telling everyone

--- 266 unchanged lines hidden (view full) ---

304
305static void
306vlan_start(struct ifnet *ifp)
307{
308 struct ifvlan *ifv;
309 struct ifnet *p;
310 struct ether_vlan_header *evl;
311 struct mbuf *m;
30 */
31
32/*
33 * if_vlan.c - pseudo-device driver for IEEE 802.1Q virtual LANs.
34 * Might be extended some day to also handle IEEE 802.1p priority
35 * tagging. This is sort of sneaky in the implementation, since
36 * we need to pretend to be enough of an Ethernet implementation
37 * to make arp work. The way we do this is by telling everyone

--- 266 unchanged lines hidden (view full) ---

304
305static void
306vlan_start(struct ifnet *ifp)
307{
308 struct ifvlan *ifv;
309 struct ifnet *p;
310 struct ether_vlan_header *evl;
311 struct mbuf *m;
312 int error;
312
313 ifv = ifp->if_softc;
314 p = ifv->ifv_p;
315
316 ifp->if_flags |= IFF_OACTIVE;
317 for (;;) {
318 IF_DEQUEUE(&ifp->if_snd, m);
319 if (m == 0)

--- 65 unchanged lines hidden (view full) ---

385 (unsigned char *)evl, ":");
386#endif
387 }
388
389 /*
390 * Send it, precisely as ether_output() would have.
391 * We are already running at splimp.
392 */
313
314 ifv = ifp->if_softc;
315 p = ifv->ifv_p;
316
317 ifp->if_flags |= IFF_OACTIVE;
318 for (;;) {
319 IF_DEQUEUE(&ifp->if_snd, m);
320 if (m == 0)

--- 65 unchanged lines hidden (view full) ---

386 (unsigned char *)evl, ":");
387#endif
388 }
389
390 /*
391 * Send it, precisely as ether_output() would have.
392 * We are already running at splimp.
393 */
393 if (IF_HANDOFF(&p->if_snd, m, p))
394 IFQ_HANDOFF(p, m, error);
395 if (!error)
394 ifp->if_opackets++;
395 else
396 ifp->if_oerrors++;
397 }
398 ifp->if_flags &= ~IFF_OACTIVE;
399
400 return;
401}

--- 448 unchanged lines hidden ---
396 ifp->if_opackets++;
397 else
398 ifp->if_oerrors++;
399 }
400 ifp->if_flags &= ~IFF_OACTIVE;
401
402 return;
403}

--- 448 unchanged lines hidden ---