Re: [patch 01/28] Fall back on interrupt disable in cmpxchg8b on 80386 and 80486

2007-08-28 Thread Nick Piggin
Mathieu Desnoyers wrote: * Nick Piggin ([EMAIL PROTECTED]) wrote: Mathieu Desnoyers wrote: Q: What's the reason to have cmpxchg64_local on 32 bit architectures? Without that need all this would just be a few simple defines. A: cmpxchg64_local on 32 bits architectures takes unsigned long

Re: [patch 01/28] Fall back on interrupt disable in cmpxchg8b on 80386 and 80486

2007-08-28 Thread Mathieu Desnoyers
* Nick Piggin ([EMAIL PROTECTED]) wrote: > Mathieu Desnoyers wrote: > > >Q: > >What's the reason to have cmpxchg64_local on 32 bit architectures? > >Without that need all this would just be a few simple defines. > > > >A: > >cmpxchg64_local on 32 bits architectures takes unsigned long long >

Re: [patch 01/28] Fall back on interrupt disable in cmpxchg8b on 80386 and 80486

2007-08-28 Thread Mathieu Desnoyers
* Nick Piggin ([EMAIL PROTECTED]) wrote: Mathieu Desnoyers wrote: Q: What's the reason to have cmpxchg64_local on 32 bit architectures? Without that need all this would just be a few simple defines. A: cmpxchg64_local on 32 bits architectures takes unsigned long long parameters, but

Re: [patch 01/28] Fall back on interrupt disable in cmpxchg8b on 80386 and 80486

2007-08-28 Thread Nick Piggin
Mathieu Desnoyers wrote: * Nick Piggin ([EMAIL PROTECTED]) wrote: Mathieu Desnoyers wrote: Q: What's the reason to have cmpxchg64_local on 32 bit architectures? Without that need all this would just be a few simple defines. A: cmpxchg64_local on 32 bits architectures takes unsigned long

Re: [patch 01/28] Fall back on interrupt disable in cmpxchg8b on 80386 and 80486

2007-08-27 Thread Nick Piggin
Mathieu Desnoyers wrote: Q: What's the reason to have cmpxchg64_local on 32 bit architectures? Without that need all this would just be a few simple defines. A: cmpxchg64_local on 32 bits architectures takes unsigned long long parameters, but cmpxchg_local only takes longs. Since we have

[patch 01/28] Fall back on interrupt disable in cmpxchg8b on 80386 and 80486

2007-08-27 Thread Mathieu Desnoyers
Actually, on 386, cmpxchg and cmpxchg_local fall back on cmpxchg_386_u8/16/32: it disables interruptions around non atomic updates to mimic the cmpxchg behavior. The comment: /* Poor man's cmpxchg for 386. Unsuitable for SMP */ already present in cmpxchg_386_u32 tells much about how this cmpxchg

[patch 01/28] Fall back on interrupt disable in cmpxchg8b on 80386 and 80486

2007-08-27 Thread Mathieu Desnoyers
Actually, on 386, cmpxchg and cmpxchg_local fall back on cmpxchg_386_u8/16/32: it disables interruptions around non atomic updates to mimic the cmpxchg behavior. The comment: /* Poor man's cmpxchg for 386. Unsuitable for SMP */ already present in cmpxchg_386_u32 tells much about how this cmpxchg

Re: [patch 01/28] Fall back on interrupt disable in cmpxchg8b on 80386 and 80486

2007-08-27 Thread Nick Piggin
Mathieu Desnoyers wrote: Q: What's the reason to have cmpxchg64_local on 32 bit architectures? Without that need all this would just be a few simple defines. A: cmpxchg64_local on 32 bits architectures takes unsigned long long parameters, but cmpxchg_local only takes longs. Since we have