From fb41147b9b46147f0e34d7ca91775604b8f10426 Mon Sep 17 00:00:00 2001 From: lepton Date: Tue, 18 Apr 2006 22:21:10 -0700 Subject: [PATCH] --- yaml --- r: 25983 b: refs/heads/master c: 1bb858f27eadc54e24dfa351fcae724cff426de2 h: refs/heads/master i: 25981: b45a2f0645f4026b698a9e186845d641ddc400eb 25979: 1ba13d17a79c71b78e4057d3539cdf0974016ac5 25975: dd4b558c4dc42159e8ab8dc80508a915753a43ba 25967: f747a31c78c4f6aaf0409d320c276b79e382b918 25951: fc327b425da38e20afcf2827127dcf1c0384906f 25919: 317d4aaaf0ee8bd5f3cc28d9dae42161ed3e812a 25855: f6e42e6cb6a70d0d49e44260ece8e05b58e19a8b v: v3 --- [refs] | 2 +- trunk/include/asm-i386/atomic.h | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index 137f071cb40d..4b1b286ae900 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: ab5703b34237da7034800ec2466ceebf88a7e685 +refs/heads/master: 1bb858f27eadc54e24dfa351fcae724cff426de2 diff --git a/trunk/include/asm-i386/atomic.h b/trunk/include/asm-i386/atomic.h index 22d80ece95cb..4ddce5296a78 100644 --- a/trunk/include/asm-i386/atomic.h +++ b/trunk/include/asm-i386/atomic.h @@ -183,6 +183,7 @@ static __inline__ int atomic_add_return(int i, atomic_t *v) { int __i; #ifdef CONFIG_M386 + unsigned long flags; if(unlikely(boot_cpu_data.x86==3)) goto no_xadd; #endif @@ -196,10 +197,10 @@ static __inline__ int atomic_add_return(int i, atomic_t *v) #ifdef CONFIG_M386 no_xadd: /* Legacy 386 processor */ - local_irq_disable(); + local_irq_save(flags); __i = atomic_read(v); atomic_set(v, i + __i); - local_irq_enable(); + local_irq_restore(flags); return i + __i; #endif }