Page MenuHomeFreeBSD

sys/acl.h: move main typedefs to sys/_types.h
ClosedPublic

Authored by brooks on Mar 15 2024, 10:46 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, May 19, 2:42 PM
Unknown Object (File)
Tue, May 19, 10:39 AM
Unknown Object (File)
Tue, May 19, 6:15 AM
Unknown Object (File)
Mon, May 18, 4:03 AM
Unknown Object (File)
Mon, May 18, 4:03 AM
Unknown Object (File)
Sun, May 17, 4:44 AM
Unknown Object (File)
Thu, May 14, 4:15 PM
Unknown Object (File)
Sun, May 10, 9:58 PM
Subscribers

Details

Summary

Make __ prefixed versions available without the pollution of sys/acl.h
(and by extension sys/param.h).

Diff Detail

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

Event Timeline

Why not define __acl_type_t in sys/_types.h instead?

In D44382#1012183, @kib wrote:

Why not define __acl_type_t in sys/_types.h instead?

I could do that (presumably declaring all of them), but that doesn't solve the problem of needing to include sys/acl.h unless I s/acl_type_t/__acl_type_t/ in syscalls.master or do a bit of macro magic in _libsys.h. I was particularly trying to avoid pulling in sys/param.h since that significantly increases the polution in libc_private.h (for example it requires removing the MIN macro in qsort.c). I'm fine with other solutions, but this one was low impact.

I was briefly tempted to either use macros or just edit syscalls.master adding __ prefixes to make it work with sys/_types.h instead of sys/types.h, but that seemed a fair bit of churn and would also require expanding u_int and u_long. We could still go that way (or use macros to do it) if that makes sense.

The intent was to use __acl_type_t in syscalls.master (and leaving it with sys/_types.h).

brooks retitled this revision from Define acl_type_t in sys/_acl_type_t.h to sys/acl.h: move main typedefs to sys/_types.h.Mar 18 2024, 9:29 PM
brooks edited the summary of this revision. (Show Details)

Declare __acl types in sys/_types.h

This revision is now accepted and ready to land.Mar 18 2024, 9:30 PM