lkml.org 
[lkml]   [2002]   [Apr]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
SubjectRe: [Patch] Compilation error on 2.5.8
From
Date
On Mon, 2002-04-15 at 18:53, Bongani wrote:
> I get the following error when I try to compile 2.5.8
> init/main.o: In function `start_kernel':
> init/main.o(.text.init+0x5e2): undefined reference to
> `setup_per_cpu_areas'
>
> Looking at the code it looks like someone got confused ;)
> around the ifdefs.I'm under the assumption that setup_per_cpu_areas()
> does nothing on a uniprocessor. The patch compile fine on
> my PC.

A better approach would probably be to define setup_per_cpu_areas to
nothing when CONFIG_SMP is not set so as not to have #ifdefs in the code
itself ... for example,

diff -urN linux-2.5.8/init/main.c linux/init/main.c
--- linux-2.5.8/init/main.c Sun Apr 14 15:18:46 2002
+++ linux/init/main.c Mon Apr 15 18:41:54 2002
@@ -272,6 +272,8 @@
#define smp_init() do { } while (0)
#endif

+#define setup_per_cpu_areas() do { } while(0)
+
#else

#ifdef __GENERIC_PER_CPU
Robert Love


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:25    [W:0.207 / U:0.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site