Page MenuHomeFreeBSD

Export the current da flags as bitfield
ClosedPublic

Authored by imp on Jan 29 2020, 8:13 PM.
Tags
None
Referenced Files
Unknown Object (File)
Dec 22 2023, 11:53 PM
Unknown Object (File)
Sep 6 2023, 12:13 AM
Unknown Object (File)
Sep 6 2023, 12:11 AM
Unknown Object (File)
Sep 6 2023, 12:10 AM
Unknown Object (File)
Sep 6 2023, 12:08 AM
Unknown Object (File)
Aug 31 2023, 11:44 PM
Unknown Object (File)
Jun 28 2023, 12:40 AM
Unknown Object (File)
Jun 28 2023, 12:38 AM
Subscribers
None

Details

Summary

Export the current flags. They can be useful to other programs wanting to do
special thigns for removable or similar devices.

Convert rotating to a DA flag

Rotating is really a da flag. Convert it to a flag so it will be reported with
the other flags for the device. Deprecate the .rotating sysctl in FreeBSD 14.

Make unmapped I/O a flag as well

Although it's really a flag on the underlying disk, add it to the softc flags as
well since we report the unmapped status as a sysctl. This will let us retire
that as well in the future.

Diff Detail

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

Event Timeline

scottl requested changes to this revision.Jan 30 2020, 1:54 AM

My recommendation is to change the rotating and unmapped sysctls to be SYSCTL_PROC, and have them read the flag. That way you can retire the fields out of the softc now.

This revision now requires changes to proceed.Jan 30 2020, 1:54 AM

Also, this should be MFC'd to 12 and even 11. With that, you can remove in 13 instead of waiting for 14

Update, per scottl

Add a sysctl flag to int function. Maybe this should be in kern_sysctl.c

This revision was not accepted when it landed; it landed in state Needs Review.Feb 13 2020, 1:23 AM
This revision was automatically updated to reflect the committed changes.