Page MenuHomeFreeBSD

bnxt: add guards around struct_group macros
ClosedPublic

Authored by bz on May 4 2025, 10:13 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Aug 8, 4:28 AM
Unknown Object (File)
Mon, Aug 4, 4:27 AM
Unknown Object (File)
Sun, Jul 27, 9:25 PM
Unknown Object (File)
Jul 12 2025, 4:29 PM
Unknown Object (File)
Jul 6 2025, 11:48 PM
Unknown Object (File)
Jul 6 2025, 12:03 PM
Unknown Object (File)
Jul 5 2025, 5:42 PM
Unknown Object (File)
Jul 1 2025, 9:15 PM
Subscribers
None

Details

Summary

The header file might be included after linux/stddef.h or others are
included and the macros would be re-defined.

Sponsored by: The FreeBSD Foundation
MFC after: 3 days

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

bz requested review of this revision.May 4 2025, 10:13 PM

I know the commit will say why, but this is or is close to relevant enough to deserve a comment. imho.

sys/dev/bnxt/bnxt_en/bnxt_dcb.h
43

Might not be a terrible idea to add a comment about why, otherwise this looks weird.
People might think it's for supporting older FreeBSD, since that's what we do sometimes
for drivers that need new features on old branches we're not ready to merge the feature
to.

This revision is now accepted and ready to land.May 4 2025, 10:25 PM
In D50156#1143986, @imp wrote:

I know the commit will say why, but this is or is close to relevant enough to deserve a comment. imho.

It's already done the same way in other headers of the driver.
The proper answer would be once the LinuxKPI change landed to remove all these bits in a next step.
But I am not sure if broadcom or we maintain this driver so I don't want to do that currently.

Please feel free to add people to the review or let me know whom to contact for that in a next step.

This revision was automatically updated to reflect the committed changes.