public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Bongani <bonganilinux@mweb.co.za>
To: Robert Love <rml@tech9.net>
Cc: Linux Kernel <linux-kernel@vger.kernel.org>
Subject: Re: [Patch] Compilation error on 2.5.8
Date: 16 Apr 2002 06:57:15 +0200	[thread overview]
Message-ID: <1018933094.2688.443.camel@localhost.localdomain> (raw)
In-Reply-To: <1018913070.3399.37.camel@phantasy>

On Tue, 2002-04-16 at 01:24, Robert Love wrote:
> On Mon, 2002-04-15 at 19:34, Bongani wrote:
> 
> > Does this also look cleaner ?
> 
> > -static inline void setup_per_cpu_areas(void)
> > -{
> > -}
> > +
> > +#define setup_per_cpu_areas()  do { } while(0)
> > +
> 
> Personally yes, but others would disagree.
> 
> In fact, if we use a define setup_per_cpu_areas can not be used outside
> of this compilation unit.  Right now this looks to be the case, but if
> something other than init/main.c wanted to use setup_per_cpu_areas we
> would need to make the code an actual function or put the define in a
> header file.
> 
> Since either case should optimize away, maybe we should make it a static
> inline in both cases, since that is the authors original preference ...
> 
> 	Robert Love
> 

Ok, so this patch should be fine then

--- init/main.c Tue Apr 16 06:52:20 2002
+++ init/main.c_new     Tue Apr 16 06:55:17 2002
@@ -272,6 +272,10 @@
 #define smp_init()     do { } while (0)
 #endif

+static inline void setup_per_cpu_areas(void)
+{
+}
+
 #else

 #ifdef __GENERIC_PER_CPU
@@ -297,9 +301,11 @@
        }
 }
 #else
+
 static inline void setup_per_cpu_areas(void)
 {
 }
+
 #endif /* !__GENERIC_PER_CPU */

 /* Called by boot processor to activate the rest. */





  reply	other threads:[~2002-04-16  4:43 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-04-15 22:53 [Patch] Compilation error on 2.5.8 Bongani
2002-04-15 22:45 ` Robert Love
2002-04-15 23:34   ` Bongani
2002-04-15 23:24     ` Robert Love
2002-04-16  4:57       ` Bongani [this message]
2002-04-16  4:48         ` Robert Love

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1018933094.2688.443.camel@localhost.localdomain \
    --to=bonganilinux@mweb.co.za \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rml@tech9.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox