aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/boot/wrapper
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc/boot/wrapper')
-rwxr-xr-xarch/powerpc/boot/wrapper32
1 files changed, 27 insertions, 5 deletions
diff --git a/arch/powerpc/boot/wrapper b/arch/powerpc/boot/wrapper
index d6c96d9ab29..644bf9d4ea0 100755
--- a/arch/powerpc/boot/wrapper
+++ b/arch/powerpc/boot/wrapper
@@ -138,14 +138,20 @@ objflags=-S
138tmp=$tmpdir/zImage.$$.o 138tmp=$tmpdir/zImage.$$.o
139ksection=.kernel:vmlinux.strip 139ksection=.kernel:vmlinux.strip
140isection=.kernel:initrd 140isection=.kernel:initrd
141link_address='0x400000'
141 142
142case "$platform" in 143case "$platform" in
143pmac|pseries|chrp) 144pseries)
145 platformo=$object/of.o
146 link_address='0x4000000'
147 ;;
148pmac|chrp)
144 platformo=$object/of.o 149 platformo=$object/of.o
145 ;; 150 ;;
146coff) 151coff)
147 platformo=$object/of.o 152 platformo=$object/of.o
148 lds=$object/zImage.coff.lds 153 lds=$object/zImage.coff.lds
154 link_address='0x500000'
149 ;; 155 ;;
150miboot|uboot) 156miboot|uboot)
151 # miboot and U-boot want just the bare bits, not an ELF binary 157 # miboot and U-boot want just the bare bits, not an ELF binary
@@ -171,13 +177,13 @@ cuboot*)
171 *-mpc824*) 177 *-mpc824*)
172 platformo=$object/cuboot-824x.o 178 platformo=$object/cuboot-824x.o
173 ;; 179 ;;
174 *-mpc83*) 180 *-mpc83*|*-asp834x*)
175 platformo=$object/cuboot-83xx.o 181 platformo=$object/cuboot-83xx.o
176 ;; 182 ;;
177 *-tqm8541|*-mpc8560*|*-tqm8560|*-tqm8555|*-ksi8560*) 183 *-tqm8541|*-mpc8560*|*-tqm8560|*-tqm8555|*-ksi8560*)
178 platformo=$object/cuboot-85xx-cpm2.o 184 platformo=$object/cuboot-85xx-cpm2.o
179 ;; 185 ;;
180 *-mpc85*|*-tqm8540|*-sbc85*) 186 *-mpc85*|*-tqm85*|*-sbc85*)
181 platformo=$object/cuboot-85xx.o 187 platformo=$object/cuboot-85xx.o
182 ;; 188 ;;
183 esac 189 esac
@@ -190,6 +196,7 @@ ps3)
190 objflags="-O binary --set-section-flags=.bss=contents,alloc,load,data" 196 objflags="-O binary --set-section-flags=.bss=contents,alloc,load,data"
191 ksection=.kernel:vmlinux.bin 197 ksection=.kernel:vmlinux.bin
192 isection=.kernel:initrd 198 isection=.kernel:initrd
199 link_address=''
193 ;; 200 ;;
194ep88xc|ep405|ep8248e) 201ep88xc|ep405|ep8248e)
195 platformo="$object/fixed-head.o $object/$platform.o" 202 platformo="$object/fixed-head.o $object/$platform.o"
@@ -200,7 +207,19 @@ adder875-redboot)
200 binary=y 207 binary=y
201 ;; 208 ;;
202simpleboot-virtex405-*) 209simpleboot-virtex405-*)
203 platformo="$object/virtex405-head.o $object/simpleboot.o" 210 platformo="$object/virtex405-head.o $object/simpleboot.o $object/virtex.o"
211 binary=y
212 ;;
213simpleboot-virtex440-*)
214 platformo="$object/simpleboot.o $object/virtex.o"
215 binary=y
216 ;;
217simpleboot-*)
218 platformo="$object/simpleboot.o"
219 binary=y
220 ;;
221asp834x-redboot)
222 platformo="$object/fixed-head.o $object/redboot-83xx.o"
204 binary=y 223 binary=y
205 ;; 224 ;;
206esac 225esac
@@ -268,7 +287,10 @@ if [ -n "$dtb" ]; then
268fi 287fi
269 288
270if [ "$platform" != "miboot" ]; then 289if [ "$platform" != "miboot" ]; then
271 ${CROSS}ld -m elf32ppc -T $lds -o "$ofile" \ 290 if [ -n "$link_address" ] ; then
291 text_start="-Ttext $link_address --defsym _start=$link_address"
292 fi
293 ${CROSS}ld -m elf32ppc -T $lds $text_start -o "$ofile" \
272 $platformo $tmp $object/wrapper.a 294 $platformo $tmp $object/wrapper.a
273 rm $tmp 295 rm $tmp
274fi 296fi