FreeBSD Bugzilla – Attachment 134808 Details for
Bug 179532
wireless networking on ARM
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
if_run_2013_01_19_vnet_plus_radiotap_fix.diff
if_run_2013_01_19_vnet_plus_radiotap_fix.diff (text/x-diff; charset="iso 8859-15"), 1.65 KB, created by
Daan Vreeken [PA4DAN]
on 2013-06-14 09:33:51 UTC
(
hide
)
Description:
if_run_2013_01_19_vnet_plus_radiotap_fix.diff
Filename:
MIME Type:
Creator:
Daan Vreeken [PA4DAN]
Created:
2013-06-14 09:33:51 UTC
Size:
1.65 KB
patch
obsolete
>Index: if_run.c >=================================================================== >--- if_run.c (revision 251736) >+++ if_run.c (working copy) >@@ -52,6 +52,7 @@ > #include <net/if_dl.h> > #include <net/if_media.h> > #include <net/if_types.h> >+#include <net/vnet.h> > > #include <netinet/in.h> > #include <netinet/in_systm.h> >@@ -606,9 +607,12 @@ > > RUN_UNLOCK(sc); > >+ CURVNET_SET(vnet0); >+ > ifp = sc->sc_ifp = if_alloc(IFT_IEEE80211); > if (ifp == NULL) { > device_printf(sc->sc_dev, "can not if_alloc()\n"); >+ CURVNET_RESTORE(); > goto detach; > } > ic = ifp->if_l2com; >@@ -702,6 +706,8 @@ > if (bootverbose) > ieee80211_announce(ic); > >+ CURVNET_RESTORE(); >+ > return (0); > > detach: >@@ -739,8 +745,10 @@ > usb_callout_drain(&sc->ratectl_ch); > ieee80211_draintask(ic, &sc->cmdq_task); > ieee80211_draintask(ic, &sc->ratectl_task); >+ CURVNET_SET(ifp->if_vnet); > ieee80211_ifdetach(ic); > if_free(ifp); >+ CURVNET_RESTORE(); > } > > mtx_destroy(&sc->sc_mtx); >@@ -2528,13 +2536,10 @@ > m->m_pkthdr.rcvif = ifp; > m->m_pkthdr.len = m->m_len = len; > >- if (ni != NULL) { >- (void)ieee80211_input(ni, m, rssi, nf); >- ieee80211_free_node(ni); >- } else { >- (void)ieee80211_input_all(ic, m, rssi, nf); >- } >- >+ /* >+ * DAAN: fill-in tap header BEFORE calling ieee80211_input*() so the >+ * user will see the actual data that belongs to THIS packet.. >+ */ > if (__predict_false(ieee80211_radiotap_active(ic))) { > struct run_rx_radiotap_header *tap = &sc->sc_rxtap; > >@@ -2571,6 +2576,13 @@ > break; > } > } >+ >+ if (ni != NULL) { >+ (void)ieee80211_input(ni, m, rssi, nf); >+ ieee80211_free_node(ni); >+ } else { >+ (void)ieee80211_input_all(ic, m, rssi, nf); >+ } > } > > static void
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 179532
:
134806
|
134807
| 134808