summaryrefslogtreecommitdiffstats
path: root/images
diff options
context:
space:
mode:
Diffstat (limited to 'images')
-rwxr-xr-ximages/make_boot_img26
1 files changed, 15 insertions, 11 deletions
diff --git a/images/make_boot_img b/images/make_boot_img
index 7c81cecb3..f35bbe4c5 100755
--- a/images/make_boot_img
+++ b/images/make_boot_img
@@ -165,17 +165,22 @@ sub initrd {
};
output("$tmp_initrd/hotplug", q{#!/bin/sh -e
+echo "Loading firmware" > /tmp/log.$FIRMWARE
+echo "SUBSYSTEM: $SUBSYSTEM" > /tmp/log.$FIRMWARE
+echo "ACTION: $ACTION" >> /tmp/log.$FIRMWARE
+echo "/sys/DEVPATH/loading: /sys/$DEVPATH/loading" >> /tmp/log.$FIRMWARE
+echo "/firmware/FIRMWARE: /firmware/$FIRMWARE" >> /tmp/log.$FIRMWARE
if [ "$SUBSYSTEM" = firmware ] && [ "$ACTION" = add ] && [ -n "$FIRMWARE" ] ; then
- if [ ! -e /sys$DEVPATH/loading ]; then
+ if [ ! -e /sys/$DEVPATH/loading ]; then
exit 1
fi
- if [ -e "/lib/firmware/$FIRMWARE" ]; then
- echo 1 > /sys$DEVPATH/loading
- cat "/lib/firmware/$FIRMWARE" > /sys$DEVPATH/data
- echo 0 > /sys$DEVPATH/loading
+ if [ -e "/firmware/$FIRMWARE" ]; then
+ echo 1 > /sys/$DEVPATH/loading
+ cat "/firmware/$FIRMWARE" > /sys/$DEVPATH/data
+ echo 0 > /sys/$DEVPATH/loading
exit 0
fi
- echo -1 > /sys$DEVPATH/loading
+ echo -1 > /sys/$DEVPATH/loading
exit 1
fi
});
@@ -201,12 +206,11 @@ fi
}
# ka deploy need some files in all.rdz
{
- mkdir_p("$tmp_initrd/$_") foreach qw(sbin dev ka proc sbin var/tmp);
+ mkdir_p("$tmp_initrd/$_") foreach qw(dev ka proc var/tmp tmp/stage2);
symlink("/sbin", "$tmp_initrd/bin");
cp_af("/usr/bin/ka-d-client", "$tmp_initrd/ka/ka-d-client");
- cp_af("/usr/bin/mke2fs_diet", "$tmp_initrd/sbin/mke2fs");
- cp_af("/usr/bin/busybox", "$tmp_initrd/sbin/busybox");
- my @funct = map { /functions:/ .. /^$/ ? do { s/\s//g; split /,/ } : () } `busybox`;
+ cp_af("/bin/busybox.static", "$tmp_initrd/sbin/busybox");
+ my @funct = map { /functions:/ .. /^$/ ? do { s/\s//g; split /,/ } : () } `busybox.static`;
shift @funct;
symlink('busybox', $tmp_initrd . "/sbin/$_") foreach @funct;
}
@@ -220,7 +224,7 @@ fi
_ "splash -s -f $o_bootsplash_cfg > $tmp_initrd/bootsplash";
}
- my $devs = sprintf "ls /dev/{%s}", join(',', qw(console fb0 fd0 loop3 mem null ppp ptyp0 ram3 tty[0-7] ttyp0 ttyS0));
+ my $devs = sprintf "ls /dev/{%s}", join(',', qw(console fb0 fd0 loop3 mem null ppp ptmx ptyp0 ram3 random tty[0-7] ttyp0 ttyS0 urandom));
_ "(cd $tmp_initrd; (find . ; $devs) | cpio -o -c --quiet) | gzip -9 > $img";
_ "rm -rf $tmp_initrd";