Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 23 Aug 2010 20:53:01 +0000 (UTC)
From:      John Baldwin <jhb@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org
Subject:   svn commit: r211719 - in stable/8: contrib/bsnmp/snmp_mibII sbin/ifconfig usr.sbin/ndp usr.sbin/ppp
Message-ID:  <201008232053.o7NKr1AF052607@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jhb
Date: Mon Aug 23 20:53:01 2010
New Revision: 211719
URL: http://svn.freebsd.org/changeset/base/211719

Log:
  MFC 210936,210946:
  Ethernet vlan(4) interfaces have valid Ethernet link layer addresses but
  use a different interface type (IFT_L2VLAN vs IFT_ETHER).  Treat IFT_L2VLAN
  interfaces like IFT_ETHER interfaces when handling link layer addresses.

Modified:
  stable/8/contrib/bsnmp/snmp_mibII/mibII.c
  stable/8/sbin/ifconfig/af_link.c
  stable/8/usr.sbin/ndp/ndp.c
  stable/8/usr.sbin/ppp/ipv6cp.c
Directory Properties:
  stable/8/contrib/bsnmp/   (props changed)
  stable/8/sbin/ifconfig/   (props changed)
  stable/8/usr.sbin/ndp/   (props changed)
  stable/8/usr.sbin/ppp/   (props changed)

Modified: stable/8/contrib/bsnmp/snmp_mibII/mibII.c
==============================================================================
--- stable/8/contrib/bsnmp/snmp_mibII/mibII.c	Mon Aug 23 20:19:17 2010	(r211718)
+++ stable/8/contrib/bsnmp/snmp_mibII/mibII.c	Mon Aug 23 20:53:01 2010	(r211719)
@@ -843,6 +843,7 @@ check_llbcast(struct mibif *ifp)
 	  case IFT_ETHER:
 	  case IFT_FDDI:
 	  case IFT_ISO88025:
+	  case IFT_L2VLAN:
 		if (mib_find_rcvaddr(ifp->index, ether_bcast, 6) == NULL &&
 		    (rcv = mib_rcvaddr_create(ifp, ether_bcast, 6)) != NULL)
 			rcv->flags |= MIBRCVADDR_BCAST;

Modified: stable/8/sbin/ifconfig/af_link.c
==============================================================================
--- stable/8/sbin/ifconfig/af_link.c	Mon Aug 23 20:19:17 2010	(r211718)
+++ stable/8/sbin/ifconfig/af_link.c	Mon Aug 23 20:53:01 2010	(r211719)
@@ -58,7 +58,9 @@ link_status(int s __unused, const struct
 	struct sockaddr_dl *sdl = (struct sockaddr_dl *) ifa->ifa_addr;
 
 	if (sdl != NULL && sdl->sdl_alen > 0) {
-		if (sdl->sdl_type == IFT_ETHER &&
+		if ((sdl->sdl_type == IFT_ETHER ||
+		    sdl->sdl_type == IFT_L2VLAN ||
+		    sdl->sdl_type == IFT_BRIDGE) &&
 		    sdl->sdl_alen == ETHER_ADDR_LEN)
 			printf("\tether %s\n",
 			    ether_ntoa((struct ether_addr *)LLADDR(sdl)));

Modified: stable/8/usr.sbin/ndp/ndp.c
==============================================================================
--- stable/8/usr.sbin/ndp/ndp.c	Mon Aug 23 20:19:17 2010	(r211718)
+++ stable/8/usr.sbin/ndp/ndp.c	Mon Aug 23 20:53:01 2010	(r211719)
@@ -437,6 +437,7 @@ set(argc, argv)
 			switch (sdl->sdl_type) {
 			case IFT_ETHER: case IFT_FDDI: case IFT_ISO88023:
 			case IFT_ISO88024: case IFT_ISO88025:
+			case IFT_L2VLAN: case IFT_BRIDGE:
 				goto overwrite;
 			}
 		}

Modified: stable/8/usr.sbin/ppp/ipv6cp.c
==============================================================================
--- stable/8/usr.sbin/ppp/ipv6cp.c	Mon Aug 23 20:19:17 2010	(r211718)
+++ stable/8/usr.sbin/ppp/ipv6cp.c	Mon Aug 23 20:53:01 2010	(r211719)
@@ -148,6 +148,7 @@ SetInterfaceID(u_char *ifid, int userand
     switch(sdl->sdl_type) {
     case IFT_ETHER:
     case IFT_FDDI:
+    case IFT_L2VLAN:
       /* XXX need more cases? */
       break;
     default:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201008232053.o7NKr1AF052607>