bridgestp.c (174493) | bridgestp.c (181803) |
---|---|
1/* $NetBSD: bridgestp.c,v 1.5 2003/11/28 08:56:48 keihan Exp $ */ 2 3/* 4 * Copyright (c) 2000 Jason L. Wright (jason@thought.net) 5 * Copyright (c) 2006 Andrew Thompson (thompsa@FreeBSD.org) 6 * All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 21 unchanged lines hidden (view full) --- 30 */ 31 32/* 33 * Implementation of the spanning tree protocol as defined in 34 * ISO/IEC 802.1D-2004, June 9, 2004. 35 */ 36 37#include <sys/cdefs.h> | 1/* $NetBSD: bridgestp.c,v 1.5 2003/11/28 08:56:48 keihan Exp $ */ 2 3/* 4 * Copyright (c) 2000 Jason L. Wright (jason@thought.net) 5 * Copyright (c) 2006 Andrew Thompson (thompsa@FreeBSD.org) 6 * All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 21 unchanged lines hidden (view full) --- 30 */ 31 32/* 33 * Implementation of the spanning tree protocol as defined in 34 * ISO/IEC 802.1D-2004, June 9, 2004. 35 */ 36 37#include <sys/cdefs.h> |
38__FBSDID("$FreeBSD: head/sys/net/bridgestp.c 174493 2007-12-09 20:47:12Z thompsa $"); | 38__FBSDID("$FreeBSD: head/sys/net/bridgestp.c 181803 2008-08-17 23:27:27Z bz $"); |
39 40#include <sys/param.h> 41#include <sys/systm.h> 42#include <sys/mbuf.h> 43#include <sys/socket.h> 44#include <sys/sockio.h> 45#include <sys/kernel.h> 46#include <sys/callout.h> 47#include <sys/module.h> 48#include <sys/proc.h> 49#include <sys/lock.h> 50#include <sys/mutex.h> 51#include <sys/taskqueue.h> | 39 40#include <sys/param.h> 41#include <sys/systm.h> 42#include <sys/mbuf.h> 43#include <sys/socket.h> 44#include <sys/sockio.h> 45#include <sys/kernel.h> 46#include <sys/callout.h> 47#include <sys/module.h> 48#include <sys/proc.h> 49#include <sys/lock.h> 50#include <sys/mutex.h> 51#include <sys/taskqueue.h> |
52#include <sys/vimage.h> |
|
52 53#include <net/if.h> 54#include <net/if_dl.h> 55#include <net/if_types.h> 56#include <net/if_llc.h> 57#include <net/if_media.h> 58 59#include <netinet/in.h> --- 1966 unchanged lines hidden (view full) --- 2026 mif = NULL; 2027 /* 2028 * Search through the Ethernet adapters and find the one with the 2029 * lowest value. The adapter which we take the MAC address from does 2030 * not need to be part of the bridge, it just needs to be a unique 2031 * value. 2032 */ 2033 IFNET_RLOCK(); | 53 54#include <net/if.h> 55#include <net/if_dl.h> 56#include <net/if_types.h> 57#include <net/if_llc.h> 58#include <net/if_media.h> 59 60#include <netinet/in.h> --- 1966 unchanged lines hidden (view full) --- 2027 mif = NULL; 2028 /* 2029 * Search through the Ethernet adapters and find the one with the 2030 * lowest value. The adapter which we take the MAC address from does 2031 * not need to be part of the bridge, it just needs to be a unique 2032 * value. 2033 */ 2034 IFNET_RLOCK(); |
2034 TAILQ_FOREACH(ifp, &ifnet, if_link) { | 2035 TAILQ_FOREACH(ifp, &V_ifnet, if_link) { |
2035 if (ifp->if_type != IFT_ETHER) 2036 continue; 2037 2038 if (bstp_addr_cmp(IF_LLADDR(ifp), llzero) == 0) 2039 continue; 2040 2041 if (mif == NULL) { 2042 mif = ifp; --- 217 unchanged lines hidden --- | 2036 if (ifp->if_type != IFT_ETHER) 2037 continue; 2038 2039 if (bstp_addr_cmp(IF_LLADDR(ifp), llzero) == 0) 2040 continue; 2041 2042 if (mif == NULL) { 2043 mif = ifp; --- 217 unchanged lines hidden --- |