summaryrefslogtreecommitdiffstats
path: root/arch/x86/include/asm/atomic.h
diff options
context:
space:
mode:
authorH. Peter Anvin2012-11-28 20:50:25 +0100
committerH. Peter Anvin2012-11-29 22:23:02 +0100
commit7ac468b1300f35143a9b5b100e3970ca7ae1d9b8 (patch)
tree1c928b80c897acc8bf7f47de8ef3793c5ba30c2c /arch/x86/include/asm/atomic.h
parentx86, 386 removal: Remove CONFIG_CMPXCHG (diff)
downloadkernel-qcow2-linux-7ac468b1300f35143a9b5b100e3970ca7ae1d9b8.tar.gz
kernel-qcow2-linux-7ac468b1300f35143a9b5b100e3970ca7ae1d9b8.tar.xz
kernel-qcow2-linux-7ac468b1300f35143a9b5b100e3970ca7ae1d9b8.zip
x86, 386 removal: Remove CONFIG_XADD
All 486+ CPUs support XADD, so remove the fallback 386 support code. Signed-off-by: H. Peter Anvin <hpa@linux.intel.com> Link: http://lkml.kernel.org/r/1354132230-21854-4-git-send-email-hpa@linux.intel.com
Diffstat (limited to 'arch/x86/include/asm/atomic.h')
-rw-r--r--arch/x86/include/asm/atomic.h16
1 files changed, 0 insertions, 16 deletions
diff --git a/arch/x86/include/asm/atomic.h b/arch/x86/include/asm/atomic.h
index b6c3b821acf6..722aa3b04624 100644
--- a/arch/x86/include/asm/atomic.h
+++ b/arch/x86/include/asm/atomic.h
@@ -172,23 +172,7 @@ static inline int atomic_add_negative(int i, atomic_t *v)
*/
static inline int atomic_add_return(int i, atomic_t *v)
{
-#ifdef CONFIG_M386
- int __i;
- unsigned long flags;
- if (unlikely(boot_cpu_data.x86 <= 3))
- goto no_xadd;
-#endif
- /* Modern 486+ processor */
return i + xadd(&v->counter, i);
-
-#ifdef CONFIG_M386
-no_xadd: /* Legacy 386 processor */
- raw_local_irq_save(flags);
- __i = atomic_read(v);
- atomic_set(v, i + __i);
- raw_local_irq_restore(flags);
- return i + __i;
-#endif
}
/**