public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@zip.com.au>
To: Anton Blanchard <anton@samba.org>
Cc: linux-kernel@vger.kernel.org, wli@holomorphy.com,
	torvalds@transmeta.com, jsantos@austin.ibm.com
Subject: Re: [PATCH] Missing memory barrier in pte_chain_unlock
Date: Thu, 25 Jul 2002 11:35:50 -0700	[thread overview]
Message-ID: <3D404506.45E6900@zip.com.au> (raw)
In-Reply-To: 20020725005932.GA18140@krispykreme

Anton Blanchard wrote:
> 
> ...
> +       smp_mb__before_clear_bit();
>         clear_bit(PG_chainlock, &page->flags);

Bah.   The problem with this smp_mb thing is that nobody knows
what it does, nobody remembers to do it and it's as ugly as sin.

I bet there are plenty of identical bugs around the place which
haven't been discovered yet.

Is there some clean, centralised way of fixing this problem
permanently?

Correctness comes first.  Why not move the barrier into
clear_bit() and then have a clear_bit_no_mb() operation for those
performance-sensitive places where the barrier is not needed?

 
-

      reply	other threads:[~2002-07-25 18:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-07-25  0:59 [PATCH] Missing memory barrier in pte_chain_unlock Anton Blanchard
2002-07-25 18:35 ` Andrew Morton [this message]

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=3D404506.45E6900@zip.com.au \
    --to=akpm@zip.com.au \
    --cc=anton@samba.org \
    --cc=jsantos@austin.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@transmeta.com \
    --cc=wli@holomorphy.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox