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)
Sun, Jun 16, 2:18 PM
Unknown Object (File)
Apr 30 2024, 1:02 PM
Unknown Object (File)
Apr 23 2024, 5:42 AM
Unknown Object (File)
Mar 5 2024, 6:46 AM
Unknown Object (File)
Feb 1 2024, 8:08 AM
Unknown Object (File)
Jan 29 2024, 11:07 PM
Unknown Object (File)
Jan 23 2024, 5:24 AM
Unknown Object (File)
Jan 14 2024, 9:20 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.