Subject: [alpine-aports] [PATCH] linux-rpi: Installing dtb-files into /boot

From: Marian Buschsieweke <[email-masked]>
Date: Fri, 15 Apr 2016 17:15:46 +0200

Instead of "/usr/lib/linux-${_abi_release}/" the dtb-files will be installed
into "/boot/", as these are required to be stored on the boot partition along
with the kernel, which is installed into "/boot/". With this change a kernel
update on a Pi will work fully automatically, as the user no longer needs to
take care to copy the .dtb-Files manually into her boot partition.
---
 main/linux-rpi/APKBUILD | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/main/linux-rpi/APKBUILD b/main/linux-rpi/APKBUILD
index 80183d8b..bc94310 100644
--- a/main/linux-rpi/APKBUILD
+++ b/main/linux-rpi/APKBUILD
@@ -108,7 +108,7 @@ _package() {
 	local _install
 	case "$CARCH" in
 	arm*)
-		local _dtbdir="$_outdir"/usr/lib/linux-${_abi_release}
+		local _dtbdir="$_outdir"/boot
 		cd "$srcdir"/build-$_buildflavor/arch/arm/boot/dts || return 1
 		mkdir -p "$_dtbdir"
 		find . -name "*.dtb" -type f | cpio -pdm "$_dtbdir"
-- 
2.8.1

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---

---

From: Timo Teras <[email-masked]>
Date: Tue, 19 Apr 2016 16:16:35 +0300

On Fri, 15 Apr 2016 17:15:46 +0200
Marian Buschsieweke <[email-masked]> wrote:

> Instead of "/usr/lib/linux-${_abi_release}/" the dtb-files will be
> installed into "/boot/", as these are required to be stored on the
> boot partition along with the kernel, which is installed into
> "/boot/". With this change a kernel update on a Pi will work fully
> automatically, as the user no longer needs to take care to copy
> the .dtb-Files manually into her boot partition. ---

If this changes, we need to fix also the alpine-iso image building
scripts, and update-kernel script.

But I don't fully like this. The problem is that you can't then have
several kernels installed as the dtb's would overlap. It's not
currently a problem, but might become one.

I do understand the issue at hand. I wonder if we could symlink things,
or just ship config.txt so the dtbs are looked up from other place. Or
potentially just ship script that copies the latest dtbs to /boot.

But generally the dtbs and the kernel should match.

> -		local
> _dtbdir="$_outdir"/usr/lib/linux-${_abi_release}
>  		cd "$srcdir"/build-$_buildflavor/arch/arm/boot/dts
> || return 1 mkdir -p "$_dtbdir"

---