Page MenuHomeFreeBSD

kern: mac: sprinkle a bit of const correctness
ClosedPublic

Authored by kevans on Mar 7 2026, 3:59 AM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Jul 15, 7:11 AM
Unknown Object (File)
Wed, Jul 15, 7:11 AM
Unknown Object (File)
Sat, Jul 4, 12:50 PM
Unknown Object (File)
Tue, Jun 30, 10:59 PM
Unknown Object (File)
Tue, Jun 30, 6:15 PM
Unknown Object (File)
Sat, Jun 27, 4:15 PM
Unknown Object (File)
Jun 7 2026, 2:48 PM
Unknown Object (File)
May 27 2026, 12:47 AM
Subscribers

Details

Summary

mpc_name and mpc_fullname are string literals in correct usage, so they
should really be const instead.

mpc_ops aren't typically const, but the framework shouldn't be doing
anything to clobber it; thus, good to constify it as a reminder.

Switch to using a slightly more semantically correct void ** in the
fastpath bits while we're here, since we only do arithmetic on the outer
layer of pointer and compare the inner to a pointer-typed (NULL).

Diff Detail

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