if_iwi.c (158651) | if_iwi.c (159180) |
---|---|
1/*- 2 * Copyright (c) 2004, 2005 3 * Damien Bergamini <damien.bergamini@free.fr>. All rights reserved. 4 * Copyright (c) 2005-2006 Sam Leffler, Errno Consulting 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 13 unchanged lines hidden (view full) --- 22 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26 * SUCH DAMAGE. 27 */ 28 29#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2004, 2005 3 * Damien Bergamini <damien.bergamini@free.fr>. All rights reserved. 4 * Copyright (c) 2005-2006 Sam Leffler, Errno Consulting 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 13 unchanged lines hidden (view full) --- 22 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26 * SUCH DAMAGE. 27 */ 28 29#include <sys/cdefs.h> |
30__FBSDID("$FreeBSD: head/sys/dev/iwi/if_iwi.c 158651 2006-05-16 14:37:58Z phk $"); | 30__FBSDID("$FreeBSD: head/sys/dev/iwi/if_iwi.c 159180 2006-06-02 19:59:33Z csjp $"); |
31 32/*- 33 * Intel(R) PRO/Wireless 2200BG/2225BG/2915ABG driver 34 * http://www.intel.com/network/connectivity/products/wireless/prowireless_mobile.htm 35 */ 36 37#include <sys/param.h> 38#include <sys/sysctl.h> --- 1256 unchanged lines hidden (view full) --- 1295 1296 /* finalize mbuf */ 1297 m->m_pkthdr.rcvif = ifp; 1298 m->m_pkthdr.len = m->m_len = sizeof (struct iwi_hdr) + 1299 sizeof (struct iwi_frame) + framelen; 1300 1301 m_adj(m, sizeof (struct iwi_hdr) + sizeof (struct iwi_frame)); 1302 | 31 32/*- 33 * Intel(R) PRO/Wireless 2200BG/2225BG/2915ABG driver 34 * http://www.intel.com/network/connectivity/products/wireless/prowireless_mobile.htm 35 */ 36 37#include <sys/param.h> 38#include <sys/sysctl.h> --- 1256 unchanged lines hidden (view full) --- 1295 1296 /* finalize mbuf */ 1297 m->m_pkthdr.rcvif = ifp; 1298 m->m_pkthdr.len = m->m_len = sizeof (struct iwi_hdr) + 1299 sizeof (struct iwi_frame) + framelen; 1300 1301 m_adj(m, sizeof (struct iwi_hdr) + sizeof (struct iwi_frame)); 1302 |
1303 if (sc->sc_drvbpf != NULL) { | 1303 if (bpf_peers_present(sc->sc_drvbpf)) { |
1304 struct iwi_rx_radiotap_header *tap = &sc->sc_rxtap; 1305 1306 tap->wr_flags = 0; 1307 tap->wr_rate = iwi_cvtrate(frame->rate); 1308 tap->wr_antsignal = frame->signal; 1309 tap->wr_antenna = frame->antenna; 1310 1311 bpf_mtap2(sc->sc_drvbpf, tap, sc->sc_rxtap_len, m); --- 512 unchanged lines hidden (view full) --- 1824 m_freem(m0); 1825 return ENOBUFS; 1826 } 1827 1828 /* packet header may have moved, reset our local pointer */ 1829 wh = mtod(m0, struct ieee80211_frame *); 1830 } 1831 | 1304 struct iwi_rx_radiotap_header *tap = &sc->sc_rxtap; 1305 1306 tap->wr_flags = 0; 1307 tap->wr_rate = iwi_cvtrate(frame->rate); 1308 tap->wr_antsignal = frame->signal; 1309 tap->wr_antenna = frame->antenna; 1310 1311 bpf_mtap2(sc->sc_drvbpf, tap, sc->sc_rxtap_len, m); --- 512 unchanged lines hidden (view full) --- 1824 m_freem(m0); 1825 return ENOBUFS; 1826 } 1827 1828 /* packet header may have moved, reset our local pointer */ 1829 wh = mtod(m0, struct ieee80211_frame *); 1830 } 1831 |
1832 if (sc->sc_drvbpf != NULL) { | 1832 if (bpf_peers_present(sc->sc_drvbpf)) { |
1833 struct iwi_tx_radiotap_header *tap = &sc->sc_txtap; 1834 1835 tap->wt_flags = 0; 1836 1837 bpf_mtap2(sc->sc_drvbpf, tap, sc->sc_txtap_len, m0); 1838 } 1839 1840 data = &txq->data[txq->cur]; --- 1680 unchanged lines hidden --- | 1833 struct iwi_tx_radiotap_header *tap = &sc->sc_txtap; 1834 1835 tap->wt_flags = 0; 1836 1837 bpf_mtap2(sc->sc_drvbpf, tap, sc->sc_txtap_len, m0); 1838 } 1839 1840 data = &txq->data[txq->cur]; --- 1680 unchanged lines hidden --- |