public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Jeremy Fitzhardinge <jeremy@goop.org>
To: Ingo Molnar <mingo@elte.hu>
Cc: Jan Beulich <jbeulich@novell.com>, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] x86: simplify sync_test_bit()
Date: Sat, 22 Mar 2008 13:27:38 -0700	[thread overview]
Message-ID: <47E56BBA.2000803@goop.org> (raw)
In-Reply-To: <20080321111826.GC20420@elte.hu>

Ingo Molnar wrote:
> * Jan Beulich <jbeulich@novell.com> wrote:
>
>   
>> There really is no need for a redundant implementation here, just keep 
>> the alternative name for allowing consumers to use consistent naming.
>>     
>
>   
>> -	__asm__ __volatile__("btl %2,%1\n\tsbbl %0,%0"
>> -			     :"=r" (oldbit)
>> -			     :"m" (ADDR),"Ir" (nr));
>>     
>
>   
>> +#define sync_test_bit test_bit
>>     
>
> thanks, applied.

Please use this instead.

    J

Subject: x86: use macro parameters on sync_test_bit

Using a naked parameterless macro could lead to other tokens being
unexpectedly replaced.

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
---
 include/asm-x86/sync_bitops.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

===================================================================
--- a/include/asm-x86/sync_bitops.h
+++ b/include/asm-x86/sync_bitops.h
@@ -123,7 +123,7 @@
 	return oldbit;
 }
 
-#define sync_test_bit test_bit
+#define sync_test_bit(nr, addr) test_bit(nr, addr)
 
 #undef ADDR
 



  reply	other threads:[~2008-03-22 20:31 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-14  7:56 [PATCH] x86: simplify sync_test_bit() Jan Beulich
2008-03-14 15:03 ` Jeremy Fitzhardinge
2008-03-14 15:20   ` Jan Beulich
2008-03-14 15:43     ` Jeremy Fitzhardinge
2008-03-21 11:18 ` Ingo Molnar
2008-03-22 20:27   ` Jeremy Fitzhardinge [this message]
2008-03-26  7:27     ` Ingo Molnar

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=47E56BBA.2000803@goop.org \
    --to=jeremy@goop.org \
    --cc=jbeulich@novell.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    /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