lkml.org 
[lkml]   [2010]   [Feb]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    Subject[tip:x86/atomic] x86-32: Allow UP/SMP lock replacement in cmpxchg64
    Commit-ID:  9c76b38476b18c45f97098a10b0176b321eba3ea
    Gitweb: http://git.kernel.org/tip/9c76b38476b18c45f97098a10b0176b321eba3ea
    Author: Luca Barbieri <luca@luca-barbieri.com>
    AuthorDate: Wed, 24 Feb 2010 10:54:23 +0100
    Committer: H. Peter Anvin <hpa@zytor.com>
    CommitDate: Thu, 25 Feb 2010 20:47:03 -0800

    x86-32: Allow UP/SMP lock replacement in cmpxchg64

    Use the functionality just introduced in the previous patch: mark the
    lock prefixes in cmpxchg64 alternatives for UP removal.

    Changes in v2:
    - Naming change

    Signed-off-by: Luca Barbieri <luca@luca-barbieri.com>
    LKML-Reference: <1267005265-27958-3-git-send-email-luca@luca-barbieri.com>
    Signed-off-by: H. Peter Anvin <hpa@zytor.com>
    ---
    arch/x86/include/asm/cmpxchg_32.h | 3 ++-
    1 files changed, 2 insertions(+), 1 deletions(-)

    diff --git a/arch/x86/include/asm/cmpxchg_32.h b/arch/x86/include/asm/cmpxchg_32.h
    index ffb9bb6..8859e12 100644
    --- a/arch/x86/include/asm/cmpxchg_32.h
    +++ b/arch/x86/include/asm/cmpxchg_32.h
    @@ -271,7 +271,8 @@ extern unsigned long long cmpxchg_486_u64(volatile void *, u64, u64);
    __typeof__(*(ptr)) __ret; \
    __typeof__(*(ptr)) __old = (o); \
    __typeof__(*(ptr)) __new = (n); \
    - alternative_io("call cmpxchg8b_emu", \
    + alternative_io(LOCK_PREFIX_HERE \
    + "call cmpxchg8b_emu", \
    "lock; cmpxchg8b (%%esi)" , \
    X86_FEATURE_CX8, \
    "=A" (__ret), \

    \
     
     \ /
      Last update: 2010-02-26 06:15    [W:0.025 / U:0.084 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site