]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
powerpc: Remove the empty giveup_fpu() function on 32bit kernel
authorKevin Hao <haokexin@gmail.com>
Sun, 14 Jul 2013 09:02:06 +0000 (17:02 +0800)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Wed, 14 Aug 2013 04:59:50 +0000 (14:59 +1000)
Instead of implementing an empty giveup_fpu() function for each
32bit processor type, replace them with an unique empty inline
function.

Signed-off-by: Kevin Hao <haokexin@gmail.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/include/asm/switch_to.h
arch/powerpc/kernel/head_40x.S
arch/powerpc/kernel/head_44x.S
arch/powerpc/kernel/head_8xx.S
arch/powerpc/kernel/head_fsl_booke.S
arch/powerpc/kernel/ppc_ksyms.c

index 39cf0f6cc37396e19741cd3bd8b700e0689bb2e2..2c7edde8f1bb214677801bf7eaebac566e4bae2e 100644 (file)
@@ -16,7 +16,6 @@ struct thread_struct;
 extern struct task_struct *_switch(struct thread_struct *prev,
                                   struct thread_struct *next);
 
-extern void giveup_fpu(struct task_struct *);
 extern void load_up_fpu(void);
 extern void enable_kernel_fp(void);
 extern void enable_kernel_altivec(void);
@@ -38,8 +37,10 @@ static inline void discard_lazy_cpu_state(void)
 
 #ifdef CONFIG_PPC_FPU
 extern void flush_fp_to_thread(struct task_struct *);
+extern void giveup_fpu(struct task_struct *);
 #else
 static inline void flush_fp_to_thread(struct task_struct *t) { }
+static inline void giveup_fpu(struct task_struct *t) { }
 #endif
 
 #ifdef CONFIG_ALTIVEC
index 8a9b6f59822d666edf25ebc77326f2a5acbc8482..67ee0d6c1070b3f02702dbc8442a905f3b39b8d6 100644 (file)
@@ -822,14 +822,6 @@ finish_tlb_load:
        rfi                     /* Should sync shadow TLBs */
        b       .               /* prevent prefetch past rfi */
 
-/* extern void giveup_fpu(struct task_struct *prev)
- *
- * The PowerPC 4xx family of processors do not have an FPU, so this just
- * returns.
- */
-_ENTRY(giveup_fpu)
-       blr
-
 /* This is where the main kernel code starts.
  */
 start_here:
index 97e2671cde7f4ae662264d0bbf377f95c0d6e58e..c334f53453f708ea64c7d9c1322cc92418a5b687 100644 (file)
@@ -784,16 +784,6 @@ _GLOBAL(__fixup_440A_mcheck)
        sync
        blr
 
-/*
- * extern void giveup_fpu(struct task_struct *prev)
- *
- * The 44x core does not have an FPU.
- */
-#ifndef CONFIG_PPC_FPU
-_GLOBAL(giveup_fpu)
-       blr
-#endif
-
 _GLOBAL(set_context)
 
 #ifdef CONFIG_BDI_SWITCH
index b2a5860accfb9c3fa607e2cf4210802e574d6fd2..1b92a97b1b046d3721c9aed9912775de27dccd6d 100644 (file)
@@ -691,10 +691,6 @@ modified_instr:
        b       151b
 #endif
 
-       .globl  giveup_fpu
-giveup_fpu:
-       blr
-
 /*
  * This is where the main kernel code starts.
  */
index d10a7cacccd203b7af0814a19f3ea9f6ed1f000a..289afaffbbb5df2ecba595e01646a5b5d4bfd964 100644 (file)
@@ -947,16 +947,6 @@ _GLOBAL(giveup_spe)
        blr
 #endif /* CONFIG_SPE */
 
-/*
- * extern void giveup_fpu(struct task_struct *prev)
- *
- * Not all FSL Book-E cores have an FPU
- */
-#ifndef CONFIG_PPC_FPU
-_GLOBAL(giveup_fpu)
-       blr
-#endif
-
 /*
  * extern void abort(void)
  *
index 380a6f9fa7f856255ccfbf17a50bd9b1f588e9c1..21646dbe1bb3c7a48df59ba14dea18431abe12be 100644 (file)
@@ -96,7 +96,9 @@ EXPORT_SYMBOL(pci_dram_offset);
 
 EXPORT_SYMBOL(start_thread);
 
+#ifdef CONFIG_PPC_FPU
 EXPORT_SYMBOL(giveup_fpu);
+#endif
 #ifdef CONFIG_ALTIVEC
 EXPORT_SYMBOL(giveup_altivec);
 #endif /* CONFIG_ALTIVEC */