fix a TX issue on big endian machines like powerpc or sparc64. Now

zyd(4) should work on all architectures.

Obtained from:	OpenBSD
This commit is contained in:
Weongyo Jeong 2009-09-04 05:28:09 +00:00
parent 18e5fe2840
commit a6b8e0e915

View File

@ -2547,7 +2547,7 @@ zyd_tx_start(struct zyd_softc *sc, struct mbuf *m0, struct ieee80211_node *ni)
bits = (rate == 11) ? (totlen * 16) + 10 :
((rate == 22) ? (totlen * 8) + 10 : (totlen * 8));
desc->plcp_length = bits / ratediv[phy];
desc->plcp_length = htole16(bits / ratediv[phy]);
desc->plcp_service = 0;
if (rate == 22 && (bits % 11) > 0 && (bits % 11) <= 3)
desc->plcp_service |= ZYD_PLCP_LENGEXT;