From cbaf10c16ec5863bbc2f1d237aacdf57427f616d Mon Sep 17 00:00:00 2001 From: Dom Cobley Date: Wed, 30 Aug 2023 20:15:11 +0100 Subject: [PATCH] rpi-update: Default to /boot/firmware if mountpoint exists Future packaging of the linux kernel results in the mountpoint of the boot partition moving to /boot/firmware. Lets handle that. --- rpi-update | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/rpi-update b/rpi-update index 880942b..05dedf3 100755 --- a/rpi-update +++ b/rpi-update @@ -48,7 +48,11 @@ if [[ "${FW_SUBDIR}" != "" ]]; then FW_SUBDIR=${FW_SUBDIR: : -1} fi fi -BOOT_PATH=${BOOT_PATH:-"/boot"} +if mountpoint -q /boot/firmware ; then + BOOT_PATH=${BOOT_PATH:-"/boot/firmware"} +else + BOOT_PATH=${BOOT_PATH:-"/boot"} +fi WORK_PATH=${WORK_PATH:-"${ROOT_PATH}/root"} SKIP_KERNEL=${SKIP_KERNEL:-0} SKIP_FIRMWARE=${SKIP_FIRMWARE:-0}