Remove new console devices with cnremove before initializing them in

cninit.  This allows a console driver to replace the existing console
by calling cninit again, eg during the device probe.  Otherwise the
multiple console code sends output to both, which is unfortunate if
they're using the same hardware.
This commit is contained in:
Jake Burkholder 2002-08-06 18:56:41 +00:00
parent ae9e184e5e
commit a520b73cdc
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=101436

View File

@ -148,6 +148,7 @@ cninit(void)
best_cn = NULL;
SET_FOREACH(list, cons_set) {
cn = *list;
cnremove(cn);
if (cn->cn_probe == NULL)
continue;
cn->cn_probe(cn);