public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: Jesse Barnes <jesse.barnes@intel.com>
To: Nick Piggin <npiggin@suse.de>
Cc: linux-ia64@vger.kernel.org,
	Linus Torvalds <torvalds@linux-foundation.org>,
	linuxppc-dev@ozlabs.org
Subject: Re: wmb vs mmiowb
Date: Thu, 23 Aug 2007 17:02:38 +0000	[thread overview]
Message-ID: <200708231002.39429.jesse.barnes@intel.com> (raw)
In-Reply-To: <20070823022043.GB18788@wotan.suse.de>

> > Yeah, they keep threatening to use this instead, but I'm not sure
> > how easy it would be.  Also they may have more devices/drivers to
> > worry about than sn2, so maybe changing over would mean too much
> > driver debugging (well auditing really since it's not that hard to
> > know where to put them).  Irix actually had an io_unlock() routine
> > that did this implicitly, but iirc that was shot down for Linux...
>
> Why was it shot down? Seems like a pretty good idea to me ;)

Well, like Linus said, it had some significant downsides (though I think 
Irix had fewer lock types, so the multiplicative effect wasn't so bad 
there).

> I'm clueless when it comes to drivers, but I see a lot of mmiowb()
> that are not paired with spin_unlock. How are these obvious? (ie.
> what is the pattern?) It looks like some might be lockless FIFOs (or
> maybe I'm just not aware of where the locks are). Can you just
> quickly illustrate the problem being solved?

Wow, it certainly has proliferated since it was added to the tree. :)

I didn't audit all the uses, but it seems like many of them get it 
right, i.e. mmiowb() before spin_unlock() where PIO has been done.  I'd 
have to look carefully to see whether lockless usages are correct, it's 
likely they're not.

Jesse

  parent reply	other threads:[~2007-08-23 17:02 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-22  4:57 wmb vs mmiowb Nick Piggin
2007-08-22 18:07 ` Linus Torvalds
2007-08-22 19:02   ` Jesse Barnes
2007-08-23  2:20     ` Nick Piggin
2007-08-23  2:57       ` Linus Torvalds
2007-08-23  3:54         ` Nick Piggin
2007-08-23 16:14           ` Linus Torvalds
2007-08-23  4:20         ` Nick Piggin
2007-08-23 16:16           ` Linus Torvalds
2007-08-23 16:27             ` Benjamin Herrenschmidt
2007-08-24  3:09               ` Nick Piggin
2007-08-28 20:56                 ` Brent Casavant
2007-08-29  0:59                   ` Nick Piggin
2007-08-29 18:53                     ` Brent Casavant
2007-08-30  3:36                       ` Nick Piggin
2007-08-30 19:42                         ` Brent Casavant
2007-09-03 20:48                           ` Nick Piggin
2007-08-24  2:59             ` Nick Piggin
2007-08-23 17:02       ` Jesse Barnes [this message]
2007-08-23  1:59   ` Nick Piggin
2007-08-23  7:27   ` Benjamin Herrenschmidt
2007-08-23 16:56     ` Jesse Barnes
2007-08-24  3:12       ` Nick Piggin
2007-08-28 21:21       ` Brent Casavant
2007-08-28 23:01         ` Peter Chubb
2007-08-23  7:25 ` Benjamin Herrenschmidt

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=200708231002.39429.jesse.barnes@intel.com \
    --to=jesse.barnes@intel.com \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=npiggin@suse.de \
    --cc=torvalds@linux-foundation.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox