lkml.org 
[lkml]   [2005]   [Oct]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: error: implicit declaration of function 'cpu_die'
Hi,

> arch/ppc/kernel/idle.c includes linux/smp.h, which includes asm-smp.h
> only if CONFIG_SMP is defined.
> As a result, cpu_die remains undefined for non-SMP builds.

I have used the attached patch for my tree[1], but this needs to be
cross-checked with the other architectures.

Simon

[1] where I merge the APUS stuff by Roman Zippel --
http://www.psi5.com/~geier/linux-2.6-apus.git
diff --git a/include/asm-ppc/smp.h b/include/asm-ppc/smp.h
--- a/include/asm-ppc/smp.h
+++ b/include/asm-ppc/smp.h
@@ -66,11 +66,7 @@ extern struct klock_info_struct klock_in

#endif /* __ASSEMBLY__ */

-#else /* !(CONFIG_SMP) */
-
-static inline void cpu_die(void) { }
-
-#endif /* !(CONFIG_SMP) */
+#endif /* CONFIG_SMP */

#endif /* !(_PPC_SMP_H) */
#endif /* __KERNEL__ */
diff --git a/include/linux/smp.h b/include/linux/smp.h
--- a/include/linux/smp.h
+++ b/include/linux/smp.h
@@ -99,6 +99,7 @@ void smp_prepare_boot_cpu(void);
static inline void smp_send_reschedule(int cpu) { }
#define num_booting_cpus() 1
#define smp_prepare_boot_cpu() do {} while (0)
+static inline void cpu_die(void) { }

#endif /* !SMP */
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2005-10-10 18:52    [from the cache]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and my Meterkast|Read the blog