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)
Sun, Oct 12, 12:53 PM
Unknown Object (File)
Fri, Oct 3, 1:46 AM
Unknown Object (File)
Wed, Sep 17, 10:47 PM
Unknown Object (File)
Sep 11 2025, 12:53 AM
Unknown Object (File)
Aug 18 2025, 6:35 AM
Unknown Object (File)
Jun 28 2025, 12:21 PM
Unknown Object (File)
Jun 24 2025, 2:53 PM
Unknown Object (File)
Jun 23 2025, 8:10 PM
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.