diff options
author | Renato Botelho <garga@FreeBSD.org> | 2015-04-10 16:21:57 -0300 |
---|---|---|
committer | Renato Botelho <garga@FreeBSD.org> | 2015-04-10 16:21:57 -0300 |
commit | 986e77a2eab30201b2820294e73f35536b00408a (patch) | |
tree | cdc656e04b11d2c8ae846b5ca835f8bb7016169a /etc/inc/pfsense-utils.inc | |
parent | 5fba3e9563b13150d666e639121f92483757f4dc (diff) | |
download | pfsense-986e77a2eab30201b2820294e73f35536b00408a.zip pfsense-986e77a2eab30201b2820294e73f35536b00408a.tar.gz |
Setup ADI boards to boot only using serial to avoid duplicated output when VGA redirection is enabled
Diffstat (limited to 'etc/inc/pfsense-utils.inc')
-rw-r--r-- | etc/inc/pfsense-utils.inc | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/etc/inc/pfsense-utils.inc b/etc/inc/pfsense-utils.inc index f969ada..7a3d378 100644 --- a/etc/inc/pfsense-utils.inc +++ b/etc/inc/pfsense-utils.inc @@ -1018,6 +1018,17 @@ function setup_serial_port($when="save", $path="") { $serialspeed = (is_numeric($config['system']['serialspeed'])) ? $config['system']['serialspeed'] : "115200"; if ($g['platform'] != "cdrom") { + $serial_only = false; + + if (($g['platform'] == "nanobsd") && !file_exists("/etc/nano_use_vga.txt")) { + $serial_only = true; + } else { + $specific_platform = system_identify_specific_platform(); + if ($specific_platform['name'] == 'RCC-VE') { + $serial_only = true; + } + } + $boot_config_split = explode("\n", $boot_config); $fd = fopen($boot_config_file,"w"); if ($fd) { @@ -1030,7 +1041,7 @@ function setup_serial_port($when="save", $path="") { } } } - if (($g['platform'] == "nanobsd") && !file_exists("/etc/nano_use_vga.txt")) { + if ($serial_only === true) { fwrite($fd, "-S{$serialspeed} -h"); } else if (is_serial_enabled()) { fwrite($fd, "-S{$serialspeed} -D"); @@ -1058,12 +1069,11 @@ function setup_serial_port($when="save", $path="") { } } - if (($g['platform'] == "nanobsd") && !file_exists("/etc/nano_use_vga.txt")) { - $new_boot_config[] = 'boot_serial="YES"'; + $new_boot_config[] = 'boot_serial="YES"'; + if ($serial_only === true) { $new_boot_config[] = 'console="comconsole"'; } else if (is_serial_enabled()) { $new_boot_config[] = 'boot_multicons="YES"'; - $new_boot_config[] = 'boot_serial="YES"'; $primaryconsole = isset($g['primaryconsole_force']) ? $g['primaryconsole_force'] : $config['system']['primaryconsole']; switch ($primaryconsole) { case "video": |