Use upstream Device Tree

This commit is contained in:
Daniel Moran 2019-06-27 21:40:35 +01:00
parent 8b6acd8207
commit 8577f5d5e4
1 changed files with 6 additions and 4 deletions

View File

@ -112,10 +112,7 @@ steps:
ln -s /etc/systemd/system/rpi3-generate-ssh-host-keys.service "${ROOT?}/etc/systemd/system/multi-user.target.requires/rpi3-generate-ssh-host-keys.service" ln -s /etc/systemd/system/rpi3-generate-ssh-host-keys.service "${ROOT?}/etc/systemd/system/multi-user.target.requires/rpi3-generate-ssh-host-keys.service"
rm -f ${ROOT?}/etc/ssh/ssh_host_*_key* rm -f ${ROOT?}/etc/ssh/ssh_host_*_key*
wget https://github.com/raspberrypi/firmware/blob/master/boot/bcm2708-rpi-b.dtb -O "${ROOT?}/boot/bcm2708-rpi-0-w.dtb" cp "${ROOT?}/usr/lib/linux-image-4.19.0.5-rpi/bcm2835-rpi-zero-w.dtb" "${ROOT?}/boot/"
wget https://github.com/raspberrypi/firmware/blob/master/boot/bcm2708-rpi-b-plus.dtb -O "${ROOT?}/boot/bcm2708-rpi-0-w.dtb"
wget https://github.com/raspberrypi/firmware/blob/master/boot/bcm2708-rpi-0-w.dtb -O "${ROOT?}/boot/bcm2708-rpi-0-w.dtb"
wget https://github.com/raspberrypi/firmware/blob/master/boot/bcm2708-rpi-cm.dtb -O "${ROOT?}/boot/bcm2708-rpi-0-w.dtb"
cat >> "${ROOT?}/etc/motd" <<'EOT' cat >> "${ROOT?}/etc/motd" <<'EOT'
@ -134,12 +131,17 @@ steps:
# the partition labeled raspiroot instead of forcing it to mmcblk0p2 # the partition labeled raspiroot instead of forcing it to mmcblk0p2
# #
# Enable UART in the boot loader to debug # Enable UART in the boot loader to debug
#
# Tell start.elf that the kernel is upstream, so the BCM2835 dtb gets loaded
# From:
# https://www.raspberrypi.org/forums/viewtopic.php?p=1456353&sid=4fb9bf969c9ef5594f38e028b36e39c6#p1456353
# #
- chroot: / - chroot: /
shell: | shell: |
ls -aR /boot ls -aR /boot
sed -i 's/.dev.mmcblk0p2/LABEL=RASPIROOT/' /boot/firmware/cmdline.txt sed -i 's/.dev.mmcblk0p2/LABEL=RASPIROOT/' /boot/firmware/cmdline.txt
sed -i 's/BOOT_UART=0/BOOT_UART=1/' /boot/firmware/bootcode.bin sed -i 's/BOOT_UART=0/BOOT_UART=1/' /boot/firmware/bootcode.bin
sed -i '/enable_uart=1/a upstream_kernel=1' /boot/firmware/config.txt
# TODO(https://github.com/larswirzenius/vmdb2/issues/24): remove once vmdb # TODO(https://github.com/larswirzenius/vmdb2/issues/24): remove once vmdb
# clears /etc/resolv.conf on its own. # clears /etc/resolv.conf on its own.