Commit ccf37718 authored by Nikita Ermakov's avatar Nikita Ermakov Committed by Anton Midyukov

uboot: Allow to not specify an fdtdir in extlinux.conf

QEMU for riscv virt machine passes its own DTB. Overriding DTB breaks Linux loading.
parent 741d59ab
...@@ -9,6 +9,7 @@ endif ...@@ -9,6 +9,7 @@ endif
ifeq (,$(filter-out riscv64,$(ARCH))) ifeq (,$(filter-out riscv64,$(ARCH)))
ifeq (,$(filter-out qcow2 qcow2c,$(IMAGE_TYPE))) ifeq (,$(filter-out qcow2 qcow2c,$(IMAGE_TYPE)))
UBOOT_TTY := use/tty/S0 UBOOT_TTY := use/tty/S0
UBOOT_NOFDTDIR := 1
else else
UBOOT_TTY := use/tty/SIF0 UBOOT_TTY := use/tty/SIF0
endif endif
...@@ -24,6 +25,7 @@ endif ...@@ -24,6 +25,7 @@ endif
@$(call try,UBOOT_TIMEOUT,50) @$(call try,UBOOT_TIMEOUT,50)
@$(call xport,UBOOT_BOOTARGS) @$(call xport,UBOOT_BOOTARGS)
@$(call xport,UBOOT_TIMEOUT) @$(call xport,UBOOT_TIMEOUT)
@$(call xport,UBOOT_NOFDTDIR)
else else
use/uboot: ; @: use/uboot: ; @:
endif endif
...@@ -19,3 +19,5 @@ label linux ...@@ -19,3 +19,5 @@ label linux
fdtdir /boot/dtb fdtdir /boot/dtb
append root=LABEL=ROOT ro $GLOBAL_BASE_BOOTARGS $GLOBAL_UBOOT_BOOTARGS $TTY append root=LABEL=ROOT ro $GLOBAL_BASE_BOOTARGS $GLOBAL_UBOOT_BOOTARGS $TTY
EOF EOF
[ -z "${GLOBAL_UBOOT_NOFDTDIR:-}" ] || sed -i -e '/^[\t]*fdtdir \/boot\/dtb$/d' /boot/extlinux/extlinux.conf
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment