From owner-svn-src-head@FreeBSD.ORG Thu Jun 4 17:54:42 2015 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 7EC4E53A; Thu, 4 Jun 2015 17:54:42 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6D021169D; Thu, 4 Jun 2015 17:54:42 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id t54Hsg9m018780; Thu, 4 Jun 2015 17:54:42 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id t54HsgON018779; Thu, 4 Jun 2015 17:54:42 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201506041754.t54HsgON018779@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Thu, 4 Jun 2015 17:54:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r283994 - head/sys/net80211 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Jun 2015 17:54:42 -0000 Author: adrian Date: Thu Jun 4 17:54:41 2015 New Revision: 283994 URL: https://svnweb.freebsd.org/changeset/base/283994 Log: Tag outbound raw 802.11 frames with both the node and an mbuf tag with the transmit params. This allows raw 802.11 frames to be queued in the driver if necessary, rather than requiring it to be direct-dispatched into the hardware. Tested: * ath(4), STA mode * iwn(4), STA mode MFC after: 2 weeks Sponsored by: Norse Corp, Inc. Modified: head/sys/net80211/ieee80211_output.c Modified: head/sys/net80211/ieee80211_output.c ============================================================================== --- head/sys/net80211/ieee80211_output.c Thu Jun 4 17:05:51 2015 (r283993) +++ head/sys/net80211/ieee80211_output.c Thu Jun 4 17:54:41 2015 (r283994) @@ -508,6 +508,25 @@ ieee80211_raw_output(struct ieee80211vap { struct ieee80211com *ic = vap->iv_ic; + /* + * Set node - the caller has taken a reference, so ensure + * that the mbuf has the same node value that + * it would if it were going via the normal path. + */ + m->m_pkthdr.rcvif = (void *)ni; + + /* + * Attempt to add bpf transmit parameters. + * + * For now it's ok to fail; the raw_xmit api still takes + * them as an option. + * + * Later on when ic_raw_xmit() has params removed, + * they'll have to be added - so fail the transmit if + * they can't be. + */ + (void) ieee80211_add_xmit_params(m, params); + return (ic->ic_raw_xmit(ni, m, params)); }