HomeFreeBSD

dumpdev: respect kenv for stable branches

Description

dumpdev: respect kenv for stable branches

We have somewhat twisted logic to determine actions for dumpdev
considering three sources of information:

  • kenv "dumpdev" tunnable supposed to point to specific device;
  • /etc/defaults/rc.conf "dumpdev" variable;
  • /etc/rc.conf that may be unset or set to "NO", "AUTO" or device name.

For CURRENT without any setting in kenv or /etc/rc.conf
the default is "AUTO". For STABLE branches the default is "NO".

Current implementation breaks for STABLE branches if kenv points
to specific device but /etc/rc.conf does not set "dumpdev" at all.

Let us fix it commenting out "dumpdev" in /etc/defaults/rc.conf
for STABLE branches and making the code to consult kenv
if "dumpdev" is not set elsewhere.

MFC-after: 1 month

Details

Provenance
eugen_grosbein.netAuthored on Jul 2 2023, 7:54 AM
Parents
rG005aa1743b42: modules: bzero the modspecific_t
Branches
Unknown
Tags
Unknown