diff --git a/sys/net80211/ieee80211_freebsd.c b/sys/net80211/ieee80211_freebsd.c index e685e1d37d60..bf0407c0b840 100644 --- a/sys/net80211/ieee80211_freebsd.c +++ b/sys/net80211/ieee80211_freebsd.c @@ -529,6 +529,21 @@ ieee80211_get_rx_params(struct mbuf *m, struct ieee80211_rx_stats *rxs) return (0); } +const struct ieee80211_rx_stats * +ieee80211_get_rx_params_ptr(struct mbuf *m) +{ + struct m_tag *mtag; + struct ieee80211_rx_params *rx; + + mtag = m_tag_locate(m, MTAG_ABI_NET80211, NET80211_TAG_RECV_PARAMS, + NULL); + if (mtag == NULL) + return (NULL); + rx = (struct ieee80211_rx_params *)(mtag + 1); + return (&rx->params); +} + + /* * Add TOA parameters to the given mbuf. */ diff --git a/sys/net80211/ieee80211_freebsd.h b/sys/net80211/ieee80211_freebsd.h index f21423c3e375..cbacc08b51cf 100644 --- a/sys/net80211/ieee80211_freebsd.h +++ b/sys/net80211/ieee80211_freebsd.h @@ -713,6 +713,7 @@ int ieee80211_add_rx_params(struct mbuf *m, const struct ieee80211_rx_stats *rxs); int ieee80211_get_rx_params(struct mbuf *m, struct ieee80211_rx_stats *rxs); +const struct ieee80211_rx_stats * ieee80211_get_rx_params_ptr(struct mbuf *m); struct ieee80211_toa_params { int request_id;