Patch "locking/atomic/x86: Use ALT_OUTPUT_SP() for __alternative_atomic64()" has been added to the 6.11-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    locking/atomic/x86: Use ALT_OUTPUT_SP() for __alternative_atomic64()

to the 6.11-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     locking-atomic-x86-use-alt_output_sp-for-__alternati.patch
and it can be found in the queue-6.11 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit bb181c5cc557e9007a7b41d113c3e2e10d1e1ac3
Author: Uros Bizjak <ubizjak@xxxxxxxxx>
Date:   Sun Nov 3 17:09:31 2024 +0100

    locking/atomic/x86: Use ALT_OUTPUT_SP() for __alternative_atomic64()
    
    [ Upstream commit 8b64db9733c2e4d30fd068d0b9dcef7b4424b035 ]
    
    CONFIG_X86_CMPXCHG64 variant of x86_32 __alternative_atomic64()
    macro uses CALL instruction inside asm statement. Use
    ALT_OUTPUT_SP() macro to add required dependence on %esp register.
    
    Fixes: 819165fb34b9 ("x86: Adjust asm constraints in atomic64 wrappers")
    Signed-off-by: Uros Bizjak <ubizjak@xxxxxxxxx>
    Signed-off-by: Peter Zijlstra (Intel) <peterz@xxxxxxxxxxxxx>
    Link: https://lkml.kernel.org/r/20241103160954.3329-1-ubizjak@xxxxxxxxx
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/arch/x86/include/asm/atomic64_32.h b/arch/x86/include/asm/atomic64_32.h
index 8db2ec4d6cdac..18818f6859f05 100644
--- a/arch/x86/include/asm/atomic64_32.h
+++ b/arch/x86/include/asm/atomic64_32.h
@@ -51,7 +51,8 @@ static __always_inline s64 arch_atomic64_read_nonatomic(const atomic64_t *v)
 #ifdef CONFIG_X86_CMPXCHG64
 #define __alternative_atomic64(f, g, out, in...) \
 	asm volatile("call %c[func]" \
-		     : out : [func] "i" (atomic64_##g##_cx8), ## in)
+		     : ALT_OUTPUT_SP(out) \
+		     : [func] "i" (atomic64_##g##_cx8), ## in)
 
 #define ATOMIC64_DECL(sym) ATOMIC64_DECL_ONE(sym##_cx8)
 #else




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux