Page MenuHomeFreeBSD

Make p1003_1b.aio_listio_max a tunable
ClosedPublic

Authored by asomers on Jul 14 2017, 4:31 PM.
Tags
None
Referenced Files
Unknown Object (File)
Feb 22 2024, 10:47 PM
Unknown Object (File)
Jan 11 2024, 9:47 PM
Unknown Object (File)
Jan 9 2024, 12:01 PM
Unknown Object (File)
Dec 22 2023, 11:02 PM
Unknown Object (File)
Nov 22 2023, 5:49 PM
Unknown Object (File)
Nov 15 2023, 10:00 AM
Unknown Object (File)
Nov 14 2023, 8:31 AM
Unknown Object (File)
Oct 29 2023, 11:00 PM
Subscribers

Details

Summary

Make AIO_LISTIO_MAX a tunable

p1003_1b.aio_listio_max is now a tunable. Its value is reflected in the
sysctl of the same name, and the sysconf(3) variable _SC_AIO_LISTIO_MAX.
Its value will be bounded from below by the compile-time constant
AIO_LISTIO_MAX and from above by the compile-time constant
MAX_AIO_QUEUE_PER_PROC and the tunable vfs.aio.max_aio_queue.

Test Plan

sys/aio/lio_kqueue_test with different values for IOCBS_PER_LIO and
p1003_1b.aio_listio_max

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

sys/kern/posix4_mib.c
80 ↗(On Diff #30790)

Even though this is not enabled, probably best to still add the macro here as well. Eventually we should probably just remove the disabled code.

sys/kern/vfs_aio.c
393 ↗(On Diff #30790)

Blank line before comment (bde@ would probably say the comment is banal and can just be removed)

418 ↗(On Diff #30790)

Add missing spaces around '*' while here.

1955 ↗(On Diff #30790)

I'd rather make aio_listio_max a static global variable in vfs_aio.c and not call p31b_getcfg() in all these places.

2161 ↗(On Diff #30790)

Extra blank line?

asomers marked 5 inline comments as done.

Store aio_listio_max as a static variable in vfs_aio.c instead of in
posix4_mib.c's facility array.

sys/kern/vfs_aio.c
172 ↗(On Diff #30885)

Hmm, I think I do like this approach and would be a fan of moving all the AIO-related MIBs into this file. However, I think it would be useful to check in with kib@ and possibly bde@ before moving away from p1b_*().

kib added a subscriber: kib.

I am fine with the move of all aio-related sysctls.

This revision is now accepted and ready to land.Aug 3 2017, 4:12 PM
This revision was automatically updated to reflect the committed changes.