While sysctl(8)'s kern.audio.record knob (default: 0) controls whether audio recording is enabled by default at the kernel level, as noted in sysctl(2), "For individual devices, this setting can be overridden with the mixerctl(8) record.enable variable."
mixerctl(8) must be run as root, so we can't check whether individual audio devices have the value overridden if not run as root. However, it would be helpful for recordctl(8) to show individual audio(4) device recording state when run as root.
While recordctl(8) already has a record.audio control, audio(4) devices will be numbered audio0, audio1, etc., so I think it would be acceptable to expose them as record.audio0, record.audio1, etc., as there won't be any actual conflict. The possible values for mixerctl(8)'s record.enable control are off, on, or sysctl (see mixerctl -v record.enable), but they should probably be translated to 0 or 1 for recordctl(8) (for consistency with sysctl(8), sndioctl(1), et al.) That said, I'm unsure if I would prefer to leave a value of sysctl untranslated, a blank value, a value of record.audio (the equivalent to sysctl), or maybe even the current state (0 or 1) with (sysctl) appended unless it is overridden (e.g. record.audio0=0(sysctl) or maybe record.audio1=1(mixerctl).)
While sysctl(8)'s
kern.audio.recordknob (default:0) controls whether audio recording is enabled by default at the kernel level, as noted in sysctl(2), "For individual devices, this setting can be overridden with the mixerctl(8)record.enablevariable."mixerctl(8) must be run as root, so we can't check whether individual audio devices have the value overridden if not run as root. However, it would be helpful for recordctl(8) to show individual audio(4) device recording state when run as root.
While recordctl(8) already has a
record.audiocontrol, audio(4) devices will be numberedaudio0,audio1, etc., so I think it would be acceptable to expose them asrecord.audio0,record.audio1, etc., as there won't be any actual conflict. The possible values for mixerctl(8)'srecord.enablecontrol areoff,on, orsysctl(seemixerctl -v record.enable), but they should probably be translated to0or1for recordctl(8) (for consistency with sysctl(8), sndioctl(1), et al.) That said, I'm unsure if I would prefer to leave a value ofsysctluntranslated, a blank value, a value ofrecord.audio(the equivalent tosysctl), or maybe even the current state (0or1) with(sysctl)appended unless it is overridden (e.g.record.audio0=0(sysctl)or mayberecord.audio1=1(mixerctl).)