kbuild: cris use generic asm-offsets.h support
authorSam Ravnborg <sam@mars.(none)>
Fri, 9 Sep 2005 20:44:31 +0000 (22:44 +0200)
committerSam Ravnborg <sam@mars.(none)>
Fri, 9 Sep 2005 20:44:31 +0000 (22:44 +0200)
Cris has a dedicated asm-offsets.c file per subarchitecture.
So a symlink is created to put the desired asm-offsets.c file
in $(ARCH)/kernel
This is absolutely not good practice, but it was the trick
used in the rest of the cris code.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
arch/cris/Makefile
arch/cris/arch-v10/kernel/entry.S
arch/cris/arch-v32/kernel/entry.S

index 90ca8730b1203a1c33859d36cbf9dd48ad80e72e..a00043a91f16ca3b3ce12112cb1fddb2ed0a2dd6 100644 (file)
@@ -107,8 +107,7 @@ archclean:
        rm -f timage vmlinux.bin decompress.bin rescue.bin cramfs.img
        rm -rf $(LD_SCRIPT).tmp
 
-prepare: $(SRC_ARCH)/.links $(srctree)/include/asm-$(ARCH)/.arch \
-        include/asm-$(ARCH)/$(SARCH)/offset.h
+prepare: $(SRC_ARCH)/.links $(srctree)/include/asm-$(ARCH)/.arch
 
 # Create some links to make all tools happy
 $(SRC_ARCH)/.links:
@@ -120,6 +119,7 @@ $(SRC_ARCH)/.links:
        @ln -sfn $(SRC_ARCH)/$(SARCH)/lib $(SRC_ARCH)/lib
        @ln -sfn $(SRC_ARCH)/$(SARCH) $(SRC_ARCH)/arch
        @ln -sfn $(SRC_ARCH)/$(SARCH)/vmlinux.lds.S $(SRC_ARCH)/kernel/vmlinux.lds.S
+       @ln -sfn $(SRC_ARCH)/$(SARCH)/asm-offsets.c $(SRC_ARCH)/kernel/asm-offsets.c
        @touch $@
 
 # Create link to sub arch includes
@@ -128,9 +128,3 @@ $(srctree)/include/asm-$(ARCH)/.arch: $(wildcard include/config/arch/*.h)
        @rm -f include/asm-$(ARCH)/arch
        @ln -sf $(srctree)/include/asm-$(ARCH)/$(SARCH) $(srctree)/include/asm-$(ARCH)/arch
        @touch $@
-
-arch/$(ARCH)/$(SARCH)/kernel/asm-offsets.s: include/asm include/linux/version.h \
-                                       include/config/MARKER
-
-include/asm-$(ARCH)/$(SARCH)/offset.h: arch/$(ARCH)/$(SARCH)/kernel/asm-offsets.s
-       $(call filechk,gen-asm-offsets)
index c0163bf94a5001a3fe123d315e87ab83bc629a3d..c808005e8457862e144a2e34b8be90d25c5a5410 100644 (file)
 #include <asm/arch/sv_addr_ag.h>
 #include <asm/errno.h>
 #include <asm/thread_info.h>
-#include <asm/arch/offset.h>
+#include <asm/asm-offsets.h>
 #include <asm/page.h>
 #include <asm/pgtable.h>
 
index a8ed55e5b4031c09b93601db60c323ccfe1c9a24..3bd8503fec6842420ed7cf01d105fcd7b9f87e97 100644 (file)
@@ -23,7 +23,7 @@
 #include <asm/unistd.h>
 #include <asm/errno.h>
 #include <asm/thread_info.h>
-#include <asm/arch/offset.h>
+#include <asm/asm-offsets.h>
 
 #include <asm/arch/hwregs/asm/reg_map_asm.h>
 #include <asm/arch/hwregs/asm/intr_vect_defs_asm.h>