Messages in this thread |  | | | Date | Thu, 17 Jan 2008 15:59:24 +0900 | | From | KOSAKI Motohiro <> | | Subject | Re: Bitops source problem | |
Hi
> If that is indeed the source of your change_bit function then there is
> a problem. However in my kernel tree there is a LOCK_PREFIX in the
> definition of the atomic version. I don't have your exact source tree
> handy, but on a local RHEL4 system, the LOCK_PREFIX is still there:
>
> static inline void change_bit(int nr, volatile unsigned long * addr)
> {
> __asm__ __volatile__( LOCK_PREFIX
> "btcl %1,%0"
> :"=m" (ADDR)
> :"Ir" (nr));
> }
2.6.24-rc6-mm1 have LOCK_PREFIX too :)
static inline void change_bit(int nr, volatile void *addr)
{
asm volatile(LOCK_PREFIX "btc %1,%0"
: ADDR : "Ir" (nr));
}
|  |