Page MenuHomeFreeBSD

pf: use M_WAITOK where possible
ClosedPublic

Authored by kp on Jun 9 2021, 5:00 PM.
Tags
None
Referenced Files
Unknown Object (File)
Feb 6 2024, 1:30 PM
Unknown Object (File)
Jan 27 2024, 9:09 PM
Unknown Object (File)
Jan 13 2024, 2:39 PM
Unknown Object (File)
Jan 13 2024, 12:25 PM
Unknown Object (File)
Dec 27 2023, 1:01 AM
Unknown Object (File)
Dec 25 2023, 1:13 AM
Unknown Object (File)
Dec 20 2023, 2:09 AM
Unknown Object (File)
Dec 14 2023, 10:09 PM

Details

Summary

In the ioctl path use M_WAITOK allocations whereever possible. These are
less sensitive to memory pressure, and ioctl requests have no hard
deadlines.

MFC after: 1 week
Sponsored by: Rubicon Communications, LLC ("Netgate")

Diff Detail

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

Event Timeline

kp requested review of this revision.Jun 9 2021, 5:00 PM
sys/netpfil/pf/pf_ioctl.c
3774–3775

These NULL checks are dead code now with M_WAITOK.

Assume you meant to include only the sys/netpfil/pf/pf_ioctl.c changes?

Assume you meant to include only the sys/netpfil/pf/pf_ioctl.c changes?

Gha, yes. I had a few local, uncommitted, changes, and apparently git-arc picked those up as well. And then helpfully removed them from my tree.

  • Remove unrelated changes
  • Don't check for NULL after M_WAITOK
donner added a subscriber: donner.

As far as I can check, all those changes are outside of the hold lock, so this is fine.

This revision is now accepted and ready to land.Jun 9 2021, 7:21 PM
This revision was automatically updated to reflect the committed changes.