Prevent loader.conf load failure due to unknown console entries
When processing loader.conf if console contained an entry for an unsupported
console then cons_set would return an error refusing to set any console.
This has two side effects:
- Forth would throw a syntax error and stop processing loader.conf at that point.
- The value of console is ignored.
#1 Means other important loader.conf entries may not be processed, which is
#2 Means the users preference for console aren't applied even if they did
contain valid options. Now we have support for multi boot paths from a single image e.g. bios and efi mode the console preference needs to deal with the need to set preference for more than one source.
Fix this by:
- Returning CMD_OK where possible from cons_set.
- Allowing set with at least one valid console to proceed.
Reviewed by: allanjude
MFC after: 1 week
Sponsored by: Multiplay
Differential Revision: https://reviews.freebsd.org/D5018