Page MenuHomeFreeBSD

Update mq_open(2) to document an error case and mqueuefs(5) to document sysctl variables
AcceptedPublic

Authored by felix.the.red_gmail.com on Oct 16 2021, 5:28 AM.
Tags
None
Referenced Files
Unknown Object (File)
Dec 15 2023, 8:59 AM
Unknown Object (File)
Dec 12 2023, 11:47 AM
Unknown Object (File)
Sep 19 2023, 1:06 PM
Unknown Object (File)
Jul 5 2023, 11:44 PM
Unknown Object (File)
May 3 2023, 8:45 PM
Unknown Object (File)
Mar 5 2023, 7:48 AM
Unknown Object (File)
Feb 25 2023, 12:26 AM
Unknown Object (File)
Feb 16 2023, 11:46 AM
Subscribers

Details

Reviewers
markj
Summary

This documents a case where mq_open can fail and return EINVAL (see PR 243209)
if doing so would exceed limits specified by sysctl values.
Also, document the mqueue sysctls.

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

markj added inline comments.
lib/libc/sys/mq_open.2
281

I think this is ok but perhaps deserves some additional qualification: the limits are only relevant if O_CREAT is set, and maxmsgsize and maxmsg are only checked if the mq_open(O_CREAT) call also specifies a mq_attr.

314

mqueuefs(5) might be a better place to document these?

felix.the.red_gmail.com retitled this revision from Update mq_open(2) to document an error case and sysctl variables to Update mq_open(2) to document an error case and mqueuefs(5) to document sysctl variables.Oct 16 2021, 3:57 PM

Move sysctl documentation to mqueuefs(5).
Qualify description for EINVAL error to note the use of O_CREAT and attr.

markj added inline comments.
share/man/man5/mqueuefs.5
126

I am a bit skeptical that it is worth documenting default values: if they ever change, this document will be out of date, and users can find the default values simply by reading the sysctl.

This revision is now accepted and ready to land.Oct 16 2021, 5:33 PM