All of lore.kernel.org
 help / color / mirror / Atom feed
From: "tip-bot2 for Uros Bizjak" <tip-bot2@linutronix.de>
To: linux-tip-commits@vger.kernel.org
Cc: Uros Bizjak <ubizjak@gmail.com>,
	"Peter Zijlstra (Intel)" <peterz@infradead.org>,
	x86@kernel.org, linux-kernel@vger.kernel.org
Subject: [tip: locking/core] locking/x86: Define arch_try_cmpxchg_local
Date: Thu, 13 Apr 2023 11:38:29 -0000	[thread overview]
Message-ID: <168138590988.404.12145354091229728137.tip-bot2@tip-bot2> (raw)
In-Reply-To: <20230405141710.3551-5-ubizjak@gmail.com>

The following commit has been merged into the locking/core branch of tip:

Commit-ID:     561b081f19655a46a9690e868fa4aa516ff1b62c
Gitweb:        https://git.kernel.org/tip/561b081f19655a46a9690e868fa4aa516ff1b62c
Author:        Uros Bizjak <ubizjak@gmail.com>
AuthorDate:    Wed, 05 Apr 2023 16:17:09 +02:00
Committer:     Peter Zijlstra <peterz@infradead.org>
CommitterDate: Wed, 12 Apr 2023 16:46:35 +02:00

locking/x86: Define arch_try_cmpxchg_local

Define target specific arch_try_cmpxchg_local. This
definition overrides the generic arch_try_cmpxchg_local
fallback definition and enables target-specific
implementation of try_cmpxchg_local.

Signed-off-by: Uros Bizjak <ubizjak@gmail.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/r/20230405141710.3551-5-ubizjak@gmail.com
---
 arch/x86/include/asm/cmpxchg.h | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/arch/x86/include/asm/cmpxchg.h b/arch/x86/include/asm/cmpxchg.h
index 94fbe6a..540573f 100644
--- a/arch/x86/include/asm/cmpxchg.h
+++ b/arch/x86/include/asm/cmpxchg.h
@@ -221,9 +221,15 @@ extern void __add_wrong_size(void)
 #define __try_cmpxchg(ptr, pold, new, size)				\
 	__raw_try_cmpxchg((ptr), (pold), (new), (size), LOCK_PREFIX)
 
+#define __try_cmpxchg_local(ptr, pold, new, size)			\
+	__raw_try_cmpxchg((ptr), (pold), (new), (size), "")
+
 #define arch_try_cmpxchg(ptr, pold, new) 				\
 	__try_cmpxchg((ptr), (pold), (new), sizeof(*(ptr)))
 
+#define arch_try_cmpxchg_local(ptr, pold, new)				\
+	__try_cmpxchg_local((ptr), (pold), (new), sizeof(*(ptr)))
+
 /*
  * xadd() adds "inc" to "*ptr" and atomically returns the previous
  * value of "*ptr".

  reply	other threads:[~2023-04-13 11:38 UTC|newest]

Thread overview: 62+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-05 14:17 [PATCH v2 0/5] locking: Introduce local{,64}_try_cmpxchg Uros Bizjak
2023-04-05 14:17 ` Uros Bizjak
2023-04-05 14:17 ` Uros Bizjak
2023-04-05 14:17 ` [PATCH v2 1/5] locking/atomic: Add generic try_cmpxchg{,64}_local support Uros Bizjak
2023-04-05 14:17   ` Uros Bizjak
2023-04-11 11:10   ` Mark Rutland
2023-04-11 11:10     ` Mark Rutland
2023-04-13 11:38   ` [tip: locking/core] " tip-bot2 for Uros Bizjak
2023-04-29  7:03   ` [tip: locking/core] locking/atomic: Add generic try_cmpxchg{,64}_local() support tip-bot2 for Uros Bizjak
2023-04-29  7:18   ` tip-bot2 for Uros Bizjak
2023-04-05 14:17 ` [PATCH v2 2/5] locking/generic: Wire up local{,64}_try_cmpxchg Uros Bizjak
2023-04-11 11:13   ` Mark Rutland
2023-04-11 11:13     ` Mark Rutland
2023-04-13 11:38   ` [tip: locking/core] " tip-bot2 for Uros Bizjak
2023-04-29  7:03   ` [tip: locking/core] locking/generic: Wire up local{,64}_try_cmpxchg() tip-bot2 for Uros Bizjak
2023-04-29  7:18   ` tip-bot2 for Uros Bizjak
2023-04-05 14:17 ` [PATCH v2 3/5] locking/arch: Wire up local_try_cmpxchg Uros Bizjak
2023-04-05 14:17   ` Uros Bizjak
2023-04-12 11:32   ` Peter Zijlstra
2023-04-12 11:32     ` Peter Zijlstra
2023-04-12 13:37     ` Uros Bizjak
2023-04-12 13:37       ` Uros Bizjak
2023-04-12 13:37       ` Uros Bizjak
2023-04-12 13:40       ` Peter Zijlstra
2023-04-12 13:40         ` Peter Zijlstra
2023-04-12 13:40         ` Peter Zijlstra
2023-04-13 11:38   ` [tip: locking/core] " tip-bot2 for Uros Bizjak
2023-04-29  7:03   ` [tip: locking/core] locking/arch: Wire up local_try_cmpxchg() tip-bot2 for Uros Bizjak
2023-04-29  7:18   ` tip-bot2 for Uros Bizjak
2023-05-17  7:41   ` [PATCH v2 3/5] locking/arch: Wire up local_try_cmpxchg Charlemagne Lasse
2023-05-17  7:41     ` Charlemagne Lasse
2023-05-17  7:41     ` Charlemagne Lasse
2023-04-05 14:17 ` [PATCH v2 4/5] locking/x86: Define arch_try_cmpxchg_local Uros Bizjak
2023-04-05 14:17   ` Uros Bizjak
2023-04-13 11:38   ` tip-bot2 for Uros Bizjak [this message]
2023-04-29  7:03   ` [tip: locking/core] locking/x86: Define arch_try_cmpxchg_local() tip-bot2 for Uros Bizjak
2023-04-29  7:18   ` tip-bot2 for Uros Bizjak
2023-04-05 14:17 ` [PATCH v2 5/5] events: Illustrate the transition to local{,64}_try_cmpxchg Uros Bizjak
2023-04-05 16:37 ` [PATCH v2 0/5] locking: Introduce local{,64}_try_cmpxchg Dave Hansen
2023-04-05 16:37   ` Dave Hansen
2023-04-05 16:37   ` Dave Hansen
2023-04-05 18:53   ` Uros Bizjak
2023-04-05 18:53     ` Uros Bizjak
2023-04-05 18:53     ` Uros Bizjak
2023-04-06  8:25   ` David Laight
2023-04-06  8:25     ` David Laight
2023-04-06  8:25     ` David Laight
2023-04-06  8:38     ` Uros Bizjak
2023-04-06  8:38       ` Uros Bizjak
2023-04-06  8:38       ` Uros Bizjak
2023-04-06  9:01       ` David Laight
2023-04-06  9:01         ` David Laight
2023-04-06  9:01         ` David Laight
2023-04-11 11:35   ` Mark Rutland
2023-04-11 11:35     ` Mark Rutland
2023-04-11 11:35     ` Mark Rutland
2023-04-11 13:43     ` Dave Hansen
2023-04-11 13:43       ` Dave Hansen
2023-04-11 13:43       ` Dave Hansen
2023-04-11 21:34       ` David Laight
2023-04-11 21:34         ` David Laight
2023-04-11 21:34         ` David Laight

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=168138590988.404.12145354091229728137.tip-bot2@tip-bot2 \
    --to=tip-bot2@linutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=peterz@infradead.org \
    --cc=ubizjak@gmail.com \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.