HomeFreeBSD

MFC r326769:

Description

MFC r326769:

Remove hard coded number of lun definition

The number of lun exposed is now exposed via sysctl by the kernel.
Use that number in ctlstat instead of the hardcoded version
Add a backward compatibility in case the sysctl(2) request fails.

This also allows ctlstat -l 1118 to actually work when having more than
1024 luns.

Reviewed by: avg, manu (both before the backward compatibility addition)
Approved by: avg, manu (both before the backward compatibility addition)
Sponsored by: Gandi.net
Differential Revision: https://reviews.freebsd.org/D13446

Details

Provenance
baptAuthored on
Reviewer
avg
Differential Revision
D13446: Remove hard coded number of lun definition
Parents
rS327672: stddef.h is not used by cat.c, remove the include.
Branches
Unknown
Tags
Unknown