aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2019-03-22 19:55:07 +0200
committerNatanael Copa <ncopa@alpinelinux.org>2019-06-14 12:20:46 +0000
commitc786cb5c3cc3c9b1dcfd3ccda7f61abe81ae07da (patch)
tree8f48e9cad3691ed9a41b742a63defaf2179de97e
parentab756bda7e27818f70b9a0d813672285940006fd (diff)
downloadalpine-conf-c786cb5c3cc3c9b1dcfd3ccda7f61abe81ae07da.tar.bz2
alpine-conf-c786cb5c3cc3c9b1dcfd3ccda7f61abe81ae07da.tar.xz
update-kernel: include associated firmware files to modloop
Some drivers reference only the .bin but require additional files such as .$board.txt or .clm_blob. Include all files in modloop that might match. ref #9549
-rw-r--r--update-kernel.in8
1 files changed, 4 insertions, 4 deletions
diff --git a/update-kernel.in b/update-kernel.in
index eeb0716..0079182 100644
--- a/update-kernel.in
+++ b/update-kernel.in
@@ -278,10 +278,10 @@ mkdir -p $MODLOOP/modules/firmware
find $ROOT/lib/modules -type f -name "*.ko" | xargs modinfo -F firmware | sort -u | while read FW; do
if [ -e "$ROOT/lib/firmware/$FW" ]; then
install -pD $ROOT/lib/firmware/$FW $MODLOOP/modules/firmware/$FW
- # include nvram files if firmware is needed.
- if [ -e "$ROOT/lib/firmware/${FW%.*}.txt" ]; then
- install -pD $ROOT/lib/firmware/${FW%.*}.txt $MODLOOP/modules/firmware/${FW%.*}.txt
- fi
+ # copy also all potentially associated files
+ for _file in "$ROOT"/lib/firmware/"${FW%.*}".*; do
+ install -pD "$_file" "$MODLOOP/modules/firmware/${_file#*/lib/firmware/}"
+ done
fi
done