Page MenuHomeFreeBSD

net80211: replace internal LE_READ_*/LE_WRITE_* macro with system le*dec / le*enc
ClosedPublic

Authored by avos on Apr 20 2016, 3:01 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Nov 19, 1:50 PM
Unknown Object (File)
Fri, Nov 1, 7:11 AM
Unknown Object (File)
Sep 25 2024, 1:00 PM
Unknown Object (File)
Sep 25 2024, 12:22 AM
Unknown Object (File)
Sep 17 2024, 5:27 PM
Unknown Object (File)
Sep 17 2024, 2:01 PM
Unknown Object (File)
Sep 11 2024, 11:45 AM
Unknown Object (File)
Sep 8 2024, 10:24 PM
Subscribers

Details

Summary

Replace net80211 specific macros with system-wide bytestream encoding/decoding functions:

  • LE_READ_2 -> le16dec
  • LE_READ_4 -> le32dec
  • LE_WRITE_2 -> le16enc
  • LE_WRITE_4 -> le32enc

+ drop ieee80211_input.h include, where it was included for these operations only.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

avos retitled this revision from to net80211: replace internal LE_READ_*/LE_WRITE_* macro with system le*dec / le*enc.
avos updated this object.
avos edited the test plan for this revision. (Show Details)
avos added a reviewer: adrian.
avos set the repository for this revision to rS FreeBSD src repository - subversion.

I'll check with dragonflybsd about the endian conversion routines to make sure they have the same ones in the same place.

I'd like to see a first pass be "remove all other definitions of LE_*" but I fear that'll introduce more ieee80211_input.h including.

I'll check with dragonflybsd about the endian conversion routines to make sure they have the same ones in the same place.

http://gitweb.dragonflybsd.org/dragonfly.git/blob/HEAD:/sys/sys/endian.h
le{16,32}{dec,enc} were added in 2004

I'd like to see a first pass be "remove all other definitions of LE_*" but I fear that'll introduce more ieee80211_input.h including.

Yes + LE_WRITE_* need to be moved to some appropriate header in this case.

P.S. there is another one definition of LE_READ_{2,4} in <dev/ath/ath_hal/ah_internal.h> (untouched because it is used by <contrib/dev/ath/ath_hal/ar9300>).

adrian edited edge metadata.

ok, let's do it then. We can always modify it later if someone comes along and complains about portability.

This revision is now accepted and ready to land.Apr 20 2016, 4:32 PM
This revision was automatically updated to reflect the committed changes.