From: Paul Mackerras <paulus@samba.org>
      Olaf Hering <olh@suse.de>

This adds __kcrctab to the discard list for the link script for the boot
wrapper, and is needed if you compile with CONFIG_MODVERSIONS.

With this patch applied, we need to update makefile dependencies.  Otherwise
the bootfiles will remain untouched because they do not depend on the changed
linker script.


---

 25-akpm/arch/ppc/boot/ld.script             |    1 +
 25-akpm/arch/ppc/boot/openfirmware/Makefile |   12 ++++++------
 2 files changed, 7 insertions(+), 6 deletions(-)

diff -puN arch/ppc/boot/ld.script~ppc-fixes arch/ppc/boot/ld.script
--- 25/arch/ppc/boot/ld.script~ppc-fixes	2004-03-21 00:03:44.088593408 -0800
+++ 25-akpm/arch/ppc/boot/ld.script	2004-03-21 00:03:44.090593104 -0800
@@ -82,6 +82,7 @@ SECTIONS
     *(__ksymtab)
     *(__ksymtab_strings)
     *(__bug_table)
+    *(__kcrctab)
   }
 
 }
diff -puN arch/ppc/boot/openfirmware/Makefile~ppc-fixes arch/ppc/boot/openfirmware/Makefile
--- 25/arch/ppc/boot/openfirmware/Makefile~ppc-fixes	2004-03-21 00:03:48.540916552 -0800
+++ 25-akpm/arch/ppc/boot/openfirmware/Makefile	2004-03-21 00:03:48.542916248 -0800
@@ -104,10 +104,10 @@ quiet_cmd_gen-coff = COFF    $@
 			$(HACKCOFF) $@ && \
 			ln -sf $(notdir $@) $(images)/zImage$(initrd).pmac
 
-$(images)/vmlinux.coff: $(obj)/coffboot
+$(images)/vmlinux.coff: $(obj)/coffboot $(boot)/ld.script
 	$(call cmd,gen-coff)
 
-$(images)/vmlinux.initrd.coff: $(obj)/coffboot.initrd
+$(images)/vmlinux.initrd.coff: $(obj)/coffboot.initrd $(boot)/ld.script
 	$(call cmd,gen-coff)
 
 quiet_cmd_gen-elf-pmac = ELF     $@
@@ -116,19 +116,19 @@ quiet_cmd_gen-elf-pmac = ELF     $@
 			$(OBJCOPY) $@ $@ --add-section=.note=$(obj)/note \
 					 -R .comment $(del-ramdisk-sec)
 
-$(images)/vmlinux.elf-pmac: $(obj)/image.o $(NEWWORLDOBJS) $(LIBS) $(obj)/note
+$(images)/vmlinux.elf-pmac: $(obj)/image.o $(NEWWORLDOBJS) $(LIBS) $(obj)/note $(boot)/ld.script
 	$(call cmd,gen-elf-pmac)
 $(images)/vmlinux.initrd.elf-pmac: $(obj)/image.initrd.o $(NEWWORLDOBJS) \
-				   $(LIBS) $(obj)/note
+				   $(LIBS) $(obj)/note $(boot)/ld.script
 	$(call cmd,gen-elf-pmac)
 
 quiet_cmd_gen-chrp = CHRP    $@
       cmd_gen-chrp = $(LD) $(CHRP_LD_ARGS) -o $@ $^ && \
 			$(OBJCOPY) $@ $@ -R .comment $(del-ramdisk-sec)
 
-$(images)/zImage.chrp: $(CHRPOBJS) $(obj)/image.o $(LIBS)
+$(images)/zImage.chrp: $(CHRPOBJS) $(obj)/image.o $(LIBS) $(boot)/ld.script
 	$(call cmd,gen-chrp)
-$(images)/zImage.initrd.chrp: $(CHRPOBJS) $(obj)/image.initrd.o $(LIBS)
+$(images)/zImage.initrd.chrp: $(CHRPOBJS) $(obj)/image.initrd.o $(LIBS) $(boot)/ld.script
 	$(call cmd,gen-chrp)
 
 quiet_cmd_addnote = ADDNOTE $@

_