Commit fbded57c authored by Christophe Leroy's avatar Christophe Leroy Committed by Michael Ellerman

powerpc/boot: don't force gzipped uImage

This patch modifies the generation of uImage by handing over
the selected compression type instead of forcing gzip
Signed-off-by: default avatarChristophe Leroy <christophe.leroy@c-s.fr>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
parent 43db76f4
...@@ -41,6 +41,7 @@ dts= ...@@ -41,6 +41,7 @@ dts=
cacheit= cacheit=
binary= binary=
compression=.gz compression=.gz
uboot_comp=gzip
pie= pie=
format= format=
...@@ -131,6 +132,7 @@ while [ "$#" -gt 0 ]; do ...@@ -131,6 +132,7 @@ while [ "$#" -gt 0 ]; do
;; ;;
-z) -z)
compression=.gz compression=.gz
uboot_comp=gzip
;; ;;
-Z) -Z)
shift shift
...@@ -138,15 +140,21 @@ while [ "$#" -gt 0 ]; do ...@@ -138,15 +140,21 @@ while [ "$#" -gt 0 ]; do
[ "$1" != "gz" -o "$1" != "xz" -o "$1" != "none" ] || usage [ "$1" != "gz" -o "$1" != "xz" -o "$1" != "none" ] || usage
compression=".$1" compression=".$1"
uboot_comp=$1
if [ $compression = ".none" ]; then if [ $compression = ".none" ]; then
compression= compression=
uboot_comp=none
fi
if [ $uboot_comp = "gz" ]; then
uboot_comp=gzip
fi fi
;; ;;
--no-gzip) --no-gzip)
# a "feature" of the the wrapper script is that it can be used outside # a "feature" of the the wrapper script is that it can be used outside
# the kernel tree. So keeping this around for backwards compatibility. # the kernel tree. So keeping this around for backwards compatibility.
compression= compression=
uboot_comp=none
;; ;;
-?) -?)
usage usage
...@@ -369,6 +377,7 @@ if [ -z "$cacheit" -o ! -f "$vmz$compression" -o "$vmz$compression" -ot "$kernel ...@@ -369,6 +377,7 @@ if [ -z "$cacheit" -o ! -f "$vmz$compression" -o "$vmz$compression" -ot "$kernel
*) *)
# drop the compression suffix so the stripped vmlinux is used # drop the compression suffix so the stripped vmlinux is used
compression= compression=
uboot_comp=none
;; ;;
esac esac
...@@ -412,7 +421,7 @@ membase=`${CROSS}objdump -p "$kernel" | grep -m 1 LOAD | awk '{print $7}'` ...@@ -412,7 +421,7 @@ membase=`${CROSS}objdump -p "$kernel" | grep -m 1 LOAD | awk '{print $7}'`
case "$platform" in case "$platform" in
uboot) uboot)
rm -f "$ofile" rm -f "$ofile"
${MKIMAGE} -A ppc -O linux -T kernel -C gzip -a $membase -e $membase \ ${MKIMAGE} -A ppc -O linux -T kernel -C $uboot_comp -a $membase -e $membase \
$uboot_version -d "$vmz" "$ofile" $uboot_version -d "$vmz" "$ofile"
if [ -z "$cacheit" ]; then if [ -z "$cacheit" ]; then
rm -f "$vmz" rm -f "$vmz"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment