Page MenuHomeFreeBSD

LinuxKPI: byteorder.h
ClosedPublic

Authored by bz on May 24 2021, 6:08 PM.

Details

Summary

Add a few more le<n>_{tp,add}_cpu*() #defines/functions found in
wireless drivers.

Sponsored by: The FreeBSD Foundation
MFC After: 2 weeks
Reviewed by:
Differential Revision:

Diff Detail

Repository
rG FreeBSD src repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

bz requested review of this revision.May 24 2021, 6:08 PM
sys/compat/linuxkpi/common/include/asm/byteorder.h
66–68

minor pedantic point, should these sort beside their other existing names, e.g. __le16_to_cpu following le16_to_cpu?

hselasky added inline comments.
sys/compat/linuxkpi/common/include/asm/byteorder.h
119

No need for extra parenthesis here!

((x)) -> (x)

sys/compat/linuxkpi/common/include/asm/byteorder.h
66–68

Should we just add all combinations whether or not Linux does or we'll need them and be done?

Reshuffle and fill all the gaps as (partialy) suggested by @emaste
(as I understood it at least).

bz marked 2 inline comments as done.May 24 2021, 10:02 PM
This revision is now accepted and ready to land.May 25 2021, 7:40 AM
sys/compat/linuxkpi/common/include/asm/byteorder.h
48

There's a bug here. I'll fix that before committing.

This revision was automatically updated to reflect the committed changes.