From owner-p4-projects@FreeBSD.ORG Fri Apr 25 20:09:51 2008 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 72E561065673; Fri, 25 Apr 2008 20:09:51 +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 356D21065670 for ; Fri, 25 Apr 2008 20:09:51 +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 23F558FC14 for ; Fri, 25 Apr 2008 20:09:51 +0000 (UTC) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.1/8.14.1) with ESMTP id m3PK9poa087407 for ; Fri, 25 Apr 2008 20:09:51 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.14.1/8.14.1/Submit) id m3PK9pr5087405 for perforce@freebsd.org; Fri, 25 Apr 2008 20:09:51 GMT (envelope-from sam@freebsd.org) Date: Fri, 25 Apr 2008 20:09:51 GMT Message-Id: <200804252009.m3PK9pr5087405@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 140635 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: Fri, 25 Apr 2008 20:09:51 -0000 http://perforce.freebsd.org/chv.cgi?CH=140635 Change 140635 by sam@sam_ebb on 2008/04/25 20:09:46 IFC @ 140634 Affected files ... .. //depot/projects/vap/sys/net80211/ieee80211.c#40 edit Differences ... ==== //depot/projects/vap/sys/net80211/ieee80211.c#40 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/net80211/ieee80211.c,v 1.46 2008/04/20 20:35:43 sam Exp $"); +__FBSDID("$FreeBSD: src/sys/net80211/ieee80211.c,v 1.47 2008/04/25 19:45:42 sam Exp $"); /* * IEEE 802.11 generic handler @@ -181,6 +181,22 @@ if_printf(ifp, "need promiscuous mode update callback\n"); } +static int +null_output(struct ifnet *ifp, struct mbuf *m, + struct sockaddr *dst, struct rtentry *rt0) +{ + if_printf(ifp, "discard raw packet\n"); + m_freem(m); + return EIO; +} + +static void +null_input(struct ifnet *ifp, struct mbuf *m) +{ + if_printf(ifp, "if_input should not be called\n"); + m_freem(m); +} + /* * Attach/setup the common net80211 state. Called by * the driver on attach to prior to creating any vap's. @@ -225,6 +241,9 @@ if_attach(ifp); ifp->if_mtu = IEEE80211_MTU_MAX; ifp->if_broadcastaddr = ieee80211broadcastaddr; + ifp->if_output = null_output; + ifp->if_input = null_input; /* just in case */ + ifp->if_resolvemulti = NULL; /* NB: callers check */ ifa = ifaddr_byindex(ifp->if_index); KASSERT(ifa != NULL, ("%s: no lladdr!\n", __func__));