Lines Matching +full:big +full:- +full:endian +full:- +full:desc

1 /*-
41 #include <sys/endian.h>
74 len -= sizeof(struct r92c_rx_stat) + 2;
78 device_printf(sc->sc_dev,
87 __func__, rpt->txrptb0, rpt->macid, rpt->txrptb2,
88 rpt->queue_time_low, rpt->queue_time_high, rpt->final_rate,
89 rpt->reserved);
91 if (rpt->macid > sc->macid_limit) {
92 device_printf(sc->sc_dev,
93 "macid %u is too big; increase MACID_MAX limit\n",
94 rpt->macid);
98 ntries = MS(rpt->txrptb2, R12A_TXRPTB2_RETRY_CNT);
100 ni = sc->node_list[rpt->macid];
103 "%s sent (%d retries)\n", __func__, rpt->macid,
104 (rpt->txrptb0 & (R12A_TXRPTB0_RETRY_OVER |
110 if (RTWN_RATE_IS_HT(rpt->final_rate)) { /* MCS */
111 txs.final_rate = RTWN_RIDX_TO_MCS(rpt->final_rate);
114 txs.final_rate = ridx2rate[rpt->final_rate];
115 if (rpt->txrptb0 & R12A_TXRPTB0_RETRY_OVER)
117 else if (rpt->txrptb0 & R12A_TXRPTB0_LIFE_EXPIRE)
124 "%s: macid %u, ni is NULL\n", __func__, rpt->macid);
131 struct r12a_softc *rs = sc->sc_priv;
135 len -= sizeof(struct r92c_rx_stat);
138 device_printf(sc->sc_dev, "C2H report too short (len %d)\n",
142 len -= 2;
153 rs->rs_flags &= ~R12A_IQK_RUNNING;
156 device_printf(sc->sc_dev,
166 device_printf(sc->sc_dev, "%s: called\n", __func__);
173 device_printf(sc->sc_dev, "%s: called\n", __func__);
180 struct r12a_softc *rs = sc->sc_priv;
185 rxdw1 = le32toh(stat->rxdw1);
194 return (-1);
197 (rs->rs_flags & R12A_RXCKSUM6_EN) :
198 (rs->rs_flags & R12A_RXCKSUM_EN)) {
199 m->m_pkthdr.csum_flags = CSUM_IP_CHECKED |
201 m->m_pkthdr.csum_data = 0xffff;
214 if (!(stat->rxdw4 & htole32(R12A_RXDW4_SPLCP)))
216 rate = MS(le32toh(stat->rxdw3), R12A_RXDW3_RATE);
226 const void *desc, const void *physt_ptr)
228 const struct r92c_rx_stat *stat = desc;
233 rxdw0 = le32toh(stat->rxdw0);
234 rxdw1 = le32toh(stat->rxdw1);
235 rxdw3 = le32toh(stat->rxdw3);
236 rxdw4 = le32toh(stat->rxdw4);
241 rxs->c_pktflags |= IEEE80211_RX_F_LDPC;
244 rxs->c_pktflags |= IEEE80211_RX_F_AMPDU;
246 rxs->c_pktflags |= IEEE80211_RX_F_AMPDU_MORE;
251 rxs->c_pktflags |= IEEE80211_RX_F_SHORTGI;
255 rxs->c_width = IEEE80211_RX_FW_20MHZ;
258 rxs->c_width = IEEE80211_RX_FW_40MHZ;
261 rxs->c_width = IEEE80211_RX_FW_80MHZ;
268 rxs->c_phytype = IEEE80211_RX_FP_11B;
274 is5ghz = (physt->cfosho[2] != 0x01);
278 rxs->c_phytype = IEEE80211_RX_FP_11A;
280 rxs->c_phytype = IEEE80211_RX_FP_11G;
283 rxs->c_phytype = IEEE80211_RX_FP_11NA;
285 rxs->c_phytype = IEEE80211_RX_FP_11NG;
288 rxs->c_phytype = IEEE80211_RX_FP_11NA;
294 rxs->c_rate = ridx2rate[rate];
296 rxs->c_pktflags |= IEEE80211_RX_F_CCK;
298 rxs->c_pktflags |= IEEE80211_RX_F_OFDM;
300 rxs->c_rate =
302 rxs->c_pktflags |= IEEE80211_RX_F_HT;
305 rxs->c_vhtnss = (rate - RTWN_RIDX_VHT_MCS_SHIFT) / 10;
306 rxs->c_rate = (rate - RTWN_RIDX_VHT_MCS_SHIFT) % 10;
307 rxs->c_pktflags |= IEEE80211_RX_F_VHT;
315 rxs->r_flags |= IEEE80211_R_IEEE | IEEE80211_R_FREQ;
316 rxs->r_flags |= IEEE80211_R_BAND;
317 rxs->c_ieee = MS(le16toh(physt->phyw1), R12A_PHYW1_CHAN);
318 rxs->c_freq = ieee80211_ieee2mhz(rxs->c_ieee,
319 (rxs->c_ieee < 36) ? IEEE80211_CHAN_2GHZ : IEEE80211_CHAN_5GHZ);
320 rxs->c_band = (rxs->c_ieee < 36) ? IEEE80211_CHAN_2GHZ : IEEE80211_CHAN_5GHZ;