All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Beulich <jbeulich@suse.com>
To: Roger Pau Monne <roger.pau@citrix.com>
Cc: Tamas K Lengyel <tamas@tklengyel.com>,
	Andrew Cooper <andrew.cooper3@citrix.com>,
	George Dunlap <george.dunlap@citrix.com>, Wei Liu <wl@xen.org>,
	xen-devel@lists.xenproject.org
Subject: Re: [PATCH 1/2] x86/memsharing: use an atomic add instead of a cmpxchg loop
Date: Thu, 29 Feb 2024 08:37:53 +0100	[thread overview]
Message-ID: <19c837ce-534c-4b76-b8fd-f5baa9f328bd@suse.com> (raw)
In-Reply-To: <20240222090530.62530-2-roger.pau@citrix.com>

On 22.02.2024 10:05, Roger Pau Monne wrote:
> The usage of a cmpxchg loop in get_next_handle() is unnecessary, as the same
> can be achieved with an atomic increment, which is both simpler to read, and
> avoid any need for a loop.
> 
> The cmpxchg usage is likely a remnant of 32bit support, which didn't have an
> instruction to do an atomic 64bit add, and instead a cmpxchg had to be used.
> 
> Suggested-by: Andrew Cooper <andrew.cooper3@citrix.com>
> Signed-of-by: Roger Pau Monné <roger.pau@citrix.com>

Hmm, same typo again, so my commit script again got the author wrong.
I'm sorry again. I would consider adding an explicit confirmation step
when there's no (well-formed) S-o-b, but I use this script elsewhere
as well, and in e.g. binutils and gcc S-o-b are pretty uncommon. (And
to avoid the question: I'm specifically avoiding From: itself in the
common case, as for you and other people with non-ASCII characters in
their names those typically don't properly show up there.)

Jan


  parent reply	other threads:[~2024-02-29  7:38 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-22  9:05 [PATCH 0/2] xen/x86: cmpxchg cleanup Roger Pau Monne
2024-02-22  9:05 ` [PATCH 1/2] x86/memsharing: use an atomic add instead of a cmpxchg loop Roger Pau Monne
2024-02-22 10:06   ` Jan Beulich
2024-02-22 18:03     ` Tamas K Lengyel
2024-02-23  7:43       ` Jan Beulich
2024-02-28 10:53         ` Roger Pau Monné
2024-02-28 11:18           ` Jan Beulich
2024-02-28 13:28             ` Roger Pau Monné
2024-02-28 13:38               ` Tamas K Lengyel
2024-02-22 11:12   ` Julien Grall
2024-02-29  7:37   ` Jan Beulich [this message]
2024-02-22  9:05 ` [PATCH 2/2] x86/hpet: " Roger Pau Monne
2024-02-22 10:10   ` Jan Beulich
2024-02-22 10:58     ` Roger Pau Monné
2024-02-22 11:02       ` Jan Beulich
2024-02-22 11:16   ` Julien Grall
2024-02-26  9:29   ` Jan Beulich

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=19c837ce-534c-4b76-b8fd-f5baa9f328bd@suse.com \
    --to=jbeulich@suse.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=george.dunlap@citrix.com \
    --cc=roger.pau@citrix.com \
    --cc=tamas@tklengyel.com \
    --cc=wl@xen.org \
    --cc=xen-devel@lists.xenproject.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.