From owner-p4-projects@FreeBSD.ORG Mon Nov 24 18:09:39 2008 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 8BC941065678; Mon, 24 Nov 2008 18:09:39 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4F40B1065676 for ; Mon, 24 Nov 2008 18:09:39 +0000 (UTC) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 41B8F8FC1B for ; Mon, 24 Nov 2008 18:09:39 +0000 (UTC) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.3/8.14.3) with ESMTP id mAOI9dHL047791 for ; Mon, 24 Nov 2008 18:09:39 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.14.3/8.14.3/Submit) id mAOI9dnN047789 for perforce@freebsd.org; Mon, 24 Nov 2008 18:09:39 GMT (envelope-from sam@freebsd.org) Date: Mon, 24 Nov 2008 18:09:39 GMT Message-Id: <200811241809.mAOI9dnN047789@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Cc: Subject: PERFORCE change 153454 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 24 Nov 2008 18:09:39 -0000 http://perforce.freebsd.org/chv.cgi?CH=153454 Change 153454 by sam@sam_ebb on 2008/11/24 18:09:36 restore INET/INET6 #ifdef's; this is temporary as I've got a better idea how to handle this stuff Affected files ... .. //depot/projects/arp-v2/src/sys/net/if_llatbl.c#8 edit Differences ... ==== //depot/projects/arp-v2/src/sys/net/if_llatbl.c#8 (text+ko) ==== @@ -326,14 +326,16 @@ ifp = llt->llt_ifp; switch (l3addr->sa_family) { +#ifdef INET case AF_INET: hashkey = ((struct sockaddr_in *)l3addr)->sin_addr.s_addr; break; - +#endif +#ifdef INET6 case AF_INET6: hashkey = ((struct sockaddr_in6 *)l3addr)->sin6_addr.s6_addr32[3]; break; - +#endif default: return NULL; } @@ -357,6 +359,7 @@ if (!(flags & LLE_IFADDR)) { rt = rtalloc1(l3addr, 0, 0); if ((rt == NULL) || (rt->rt_flags & RTF_GATEWAY) || (rt->rt_ifp != ifp)) { +#ifdef INET6 if (l3addr->sa_family == AF_INET6) { /* * Creating a ND6 cache for an IPv6 neighbor @@ -370,11 +373,14 @@ goto lla_lookup_1; } } +#endif switch (l3addr->sa_family) { +#ifdef INET case AF_INET: log(LOG_INFO, "IPv4 address: \"%s\" is not on the network\n", \ inet_ntoa(((struct sockaddr_in *)l3addr)->sin_addr)); break; +#endif #ifdef INET6 case AF_INET6: log(LOG_INFO, "IPv6 address: \"%s\" is not on the network\n", \ @@ -389,7 +395,9 @@ } rtfree(rt); } +#ifdef INET6 lla_lookup_1: +#endif lle = uma_zalloc(llezone, M_DONTWAIT | M_ZERO); if (lle == NULL) { log(LOG_INFO, "lla_lookup: new lle malloc failed\n");