All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@digeo.com>
To: Andrea Arcangeli <andrea@suse.de>
Cc: davem@redhat.com, shemminger@osdl.org, rmk@arm.linux.org.uk,
	ak@muc.de, davidm@napali.hpl.hp.com, anton@samba.org,
	linux-mm@kvack.org, rth@twiddle.net
Subject: Re: Linus rollup
Date: Wed, 29 Jan 2003 18:19:59 -0800	[thread overview]
Message-ID: <20030129181959.66111da0.akpm@digeo.com> (raw)
In-Reply-To: <20030130015427.GU1237@dualathlon.random>

Andrea Arcangeli <andrea@suse.de> wrote:
>
> On Wed, Jan 29, 2003 at 06:00:54PM -0800, Andrew Morton wrote:
> > Andrea Arcangeli <andrea@suse.de> wrote:
> > >
> > > On Wed, Jan 29, 2003 at 05:27:43PM -0800, Andrew Morton wrote:
> > > > @@ -82,11 +85,12 @@ static inline int fr_write_trylock(frloc
> > > >  
> > > >  	if (ret) {
> > > >  		++rw->pre_sequence;
> > > > -		wmb();
> > > > +		mb();
> > > >  	}
> > > 
> > > this isn't needed
> > > 
> > > 
> > > if we hold the spinlock, the serialized memory can't be change under us,
> > > so there's no need to put a read barrier, we only care that pre_sequence
> > > is visible before the chagnes are visible and before post_sequence is
> > > visible, hence only wmb() (after spin_lock and pre_sequence++) is
> > > needed there and only rmb() is needed in the read-side.
> > > 
> > 
> > OK, thanks muchly.
> > 
> > Lots more updates.  Here's the version which I currently have.  Looks like
> > fr_write_lock() and fr_write_unlock() need to be switched back to rmb()?
> 
> you certainly mean wmb() not rmb(), right? If yes, then yes.

Yup.


> I actually didn't notice the write_begin/end, not sure who could need
> them, I would suggest removing them, rather than to revert the mb()
> there too.

The intent here was to use them for i_size updates.  In situations where
writer serialisation was provided by external means (i_sem), and the spinlock
is not needed.

It's causing confusion so yeah, I'll probably pull them out.


--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/

  reply	other threads:[~2003-01-30  2:03 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-01-29  6:07 Linus rollup Andrew Morton
2003-01-29  6:53 ` David Mosberger
2003-01-29  7:25 ` David S. Miller
2003-01-29  9:33 ` Andrew Morton
2003-01-29  9:35   ` David S. Miller
2003-01-29  9:54 ` Anton Blanchard
2003-01-29  9:59 ` Russell King
2003-01-29  9:51   ` David S. Miller
2003-01-29 10:26     ` Andrew Morton
2003-01-29 22:35       ` Stephen Hemminger
2003-01-29 23:12         ` Andrew Morton
2003-01-30  0:30           ` David S. Miller
2003-01-30  1:27             ` Andrew Morton
2003-01-30  1:24               ` Andi Kleen
2003-01-30  2:01                 ` Andrew Morton
2003-01-30  1:35               ` Andrea Arcangeli
2003-01-30  2:00                 ` Andrew Morton
2003-01-30  1:50                   ` Jeff Garzik
2003-01-30  2:03                     ` Andrea Arcangeli
2003-01-30 17:09                       ` Stephen Hemminger
2003-01-30 17:15                         ` Randy.Dunlap
2003-01-30 17:25                           ` Andi Kleen
2003-01-30 17:23                             ` Randy.Dunlap
2003-01-30  1:52                   ` Richard Henderson
2003-01-30  2:06                     ` Andrea Arcangeli
2003-01-30  1:54                   ` Andrea Arcangeli
2003-01-30  2:19                     ` Andrew Morton [this message]
2003-01-30 17:37                     ` Stephen Hemminger
2003-01-30 17:50                       ` Andrea Arcangeli
2003-01-30  2:00                   ` Richard Henderson
2003-01-30  0:46         ` Andrea Arcangeli
2003-01-30  0:43       ` Andrea Arcangeli
2003-01-29 10:16   ` Andrew Morton
2003-01-29 17:04   ` David Mosberger
2003-01-29 17:25     ` Russell King
2003-01-29 19:05       ` David Mosberger

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=20030129181959.66111da0.akpm@digeo.com \
    --to=akpm@digeo.com \
    --cc=ak@muc.de \
    --cc=andrea@suse.de \
    --cc=anton@samba.org \
    --cc=davem@redhat.com \
    --cc=davidm@napali.hpl.hp.com \
    --cc=linux-mm@kvack.org \
    --cc=rmk@arm.linux.org.uk \
    --cc=rth@twiddle.net \
    --cc=shemminger@osdl.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.