Skip to content

Commit 5dad80b

Browse files
committed
bootable: u-boot (extlinux/boot.scr): always include tty0 console
- otherwise only serial output Signed-off-by: Ricardo Pardini <[email protected]>
1 parent 3f245eb commit 5dad80b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

bash/bootable/armbian-u-boot.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -187,6 +187,8 @@ function write_uboot_script_or_extlinux() {
187187
function write_uboot_script() {
188188
declare fat32_root_dir="${1}"
189189
declare boot_cmd_file="${fat32_root_dir}/boot.cmd"
190+
191+
declare console_extra_args="${bootable_info['CONSOLE_EXTRA_ARGS']:-""}"
190192
cat <<- BOOT_CMD > "${boot_cmd_file}"
191193
# Hook u-boot bootscript; mkimage -C none -A arm -T script -d /boot.cmd /boot.scr
192194
echo "Starting Tinkerbell Hook boot script..."
@@ -195,7 +197,7 @@ function write_uboot_script() {
195197
setenv ramdisk_addr_r "0x40000000"
196198
test -n "\${distro_bootpart}" || distro_bootpart=1
197199
echo "Boot script loaded from \${devtype} \${devnum}:\${distro_bootpart}"
198-
setenv bootargs "${UBOOT_EXTLINUX_CMDLINE}"
200+
setenv bootargs "${UBOOT_EXTLINUX_CMDLINE} console=tty0 console=${UBOOT_KERNEL_SERIALCON}${console_extra_args}"
199201
echo "Booting with: \${bootargs}"
200202
201203
echo "Loading initramfs... \${ramdisk_addr_r} /uinitrd"
@@ -221,7 +223,7 @@ function write_uboot_extlinux() {
221223
declare fat32_root_dir="${1}"
222224

223225
declare console_extra_args="${bootable_info['CONSOLE_EXTRA_ARGS']:-""}"
224-
declare bootargs="${UBOOT_EXTLINUX_CMDLINE} console=${UBOOT_KERNEL_SERIALCON}${console_extra_args}"
226+
declare bootargs="${UBOOT_EXTLINUX_CMDLINE} console=tty0 console=${UBOOT_KERNEL_SERIALCON}${console_extra_args}"
225227
log info "Writing extlinux.conf; kernel cmdline: ${bootargs}"
226228

227229
declare -g -a bootable_tinkerbell_kernel_params=()

0 commit comments

Comments
 (0)