Page MenuHomeFreeBSD

Create a macro for the static modifier with VNET
ClosedPublic

Authored by andrew on Jul 5 2018, 6:48 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, May 13, 8:16 AM
Unknown Object (File)
Mon, May 13, 7:40 AM
Unknown Object (File)
Mon, May 13, 7:40 AM
Unknown Object (File)
Mon, May 13, 7:40 AM
Unknown Object (File)
Mon, May 13, 5:20 AM
Unknown Object (File)
Mon, May 13, 1:16 AM
Unknown Object (File)
Mar 20 2024, 4:06 PM
Unknown Object (File)
Mar 7 2024, 7:53 PM
Subscribers

Details

Summary

As with DPCPU create a _STATIC version of VNET_DEFINE. This will allow us
to change this on arm64 later and enable VIMAGE.

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 18202
Build 17934: arc lint + arc unit

Event Timeline

I still need to update vnet(9)

sys/net/vnet.h
273–277

I can add the same comment as DPCPU_DEFINE here

If you can sort out the pf_ioctl.c volatile issue first, and add the comment as you suggested this look good to me.

sys/net/vnet.h
273–277

Or a comment simply saying "/* See dpcpu for explanation. */".

sys/netpfil/pf/pf_ioctl.c
190

should this not fail to compile?

  • Rebase
  • Update the man page (date will be changed when committed)
sys/netpfil/pf/pf_ioctl.c
190

No, there is no struct _hack in the static macro. I'm not sure if the use of volatile is correct here, but haven't looked too deeply into it.

This revision is now accepted and ready to land.Jul 20 2018, 1:07 PM
This revision was automatically updated to reflect the committed changes.

Hi, Andrew, do you plan to merge this into stable/11? It would be nice to have these macros to be able make MFC.