From: Segher Boessenkool <segher@kernel.crashing.org>
To: Jesse Barnes <jbarnes@virtuousgeek.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>,
Alan Cox <alan@lxorguk.ukuu.org.uk>,
David Miller <davem@davemloft.net>,
jeff@garzik.org, paulus@samba.org, torvalds@osdl.org,
linux-kernel@vger.kernel.org, akpm@osdl.org
Subject: Re: Opinion on ordering of writel vs. stores to RAM
Date: Mon, 11 Sep 2006 03:13:20 +0200 [thread overview]
Message-ID: <2486D031-097B-45C6-AC47-D8745844C5A3@kernel.crashing.org> (raw)
In-Reply-To: <200609101734.06839.jbarnes@virtuousgeek.org>
> Yeah, write combining is a good point. After all these years we
> *still*
> don't have a good in-kernel interface for changing memory mapped
> attributes, so adding a 'flags' argument to ioremap might be a good
> idea (cached, uncached, write combine are the three variants I can
> think of off the top of my head).
But what does "write-combine" mean? There are many different
implementations of basically this same idea, and implementing
just the lowest common denominator of this will hardly get us
out of the mess we are in already.
> - existing readX/writeX routines are defined to be strongly ordered
> - new MMIO accessors are added with weak semantics (not sure I like
> the __ naming though, driver authors will have to continually
> refer
> to documentation to figure out what they mean) along with new
> barrier macros to synchronize things appropriately
What exactly will "weak" mean? If it's weak enough to please all
architectures and busses, it'll be so weak that you'll need 2**N
(with a big N) different barriers.
> - flags argument to ioremap
ioremap is a bad name anyway, if we'll change the API, change the
name as well (and it's a bad idea to keep the same name but make it
mean something different, anyway).
> Oh, and all MMIO accessors are *documented* with strongly defined
> semantics. :)
Not sure what this means? Document them in all-caps? :-)
> If we go this route though, can I request that we don't introduce any
> performance regressions in drivers currently using mmiowb()? I.e.
> they'll be converted over to the new accessor routines when they
> become
> available along with the new barrier macros?
In my proposal at least, those drivers won't lose any performance
(except for a conditional on their I/O cookie, which is a trivial
performance loss compared to the cost of the I/O /an sich/); they
won't need any changes either, except for some renaming. Drivers
_not_ using it might get a performance loss though, because they
will be forced to run with every-I/O-ordered semantics; they will
suddenly start to work *correctly* though.
Segher
next prev parent reply other threads:[~2006-09-11 1:14 UTC|newest]
Thread overview: 59+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-09-09 2:03 Paul Mackerras
2006-09-09 2:42 ` Linus Torvalds
2006-09-09 3:02 ` Paul Mackerras
2006-09-09 3:54 ` Linus Torvalds
2006-09-09 7:24 ` Benjamin Herrenschmidt
2006-09-09 9:34 ` David Miller
2006-09-09 9:55 ` Jeff Garzik
2006-09-09 10:08 ` David Miller
2006-09-10 17:18 ` Jesse Barnes
2006-09-10 19:35 ` Alan Cox
2006-09-10 21:25 ` Benjamin Herrenschmidt
2006-09-10 22:23 ` Alan Cox
2006-09-10 22:18 ` Benjamin Herrenschmidt
2006-09-11 13:19 ` Jes Sorensen
2006-09-10 23:35 ` Segher Boessenkool
2006-09-11 0:12 ` Benjamin Herrenschmidt
2006-09-11 0:34 ` Jesse Barnes
2006-09-11 1:04 ` Benjamin Herrenschmidt
2006-09-11 1:13 ` Segher Boessenkool [this message]
2006-09-11 1:35 ` Benjamin Herrenschmidt
2006-09-11 9:02 ` Alan Cox
2006-09-11 9:23 ` Benjamin Herrenschmidt
2006-09-11 0:25 ` Jesse Barnes
2006-09-11 0:54 ` Segher Boessenkool
2006-09-11 1:10 ` Benjamin Herrenschmidt
2006-09-11 1:48 ` Segher Boessenkool
2006-09-11 3:53 ` Benjamin Herrenschmidt
2006-09-11 18:12 ` Jesse Barnes
2006-09-11 1:00 ` Benjamin Herrenschmidt
2006-09-11 18:08 ` Jesse Barnes
2006-09-11 21:32 ` Benjamin Herrenschmidt
2006-09-10 20:01 ` Segher Boessenkool
2006-09-11 13:21 ` David Miller
2006-09-11 14:17 ` Segher Boessenkool
2006-09-12 0:32 ` David Miller
2006-09-12 0:49 ` Benjamin Herrenschmidt
2006-09-12 16:47 ` Segher Boessenkool
2006-09-12 0:54 ` Roland Dreier
2006-09-09 11:16 ` Paul Mackerras
2006-09-09 7:23 ` Benjamin Herrenschmidt
2006-09-09 9:38 ` David Miller
2006-09-09 15:09 ` Alan Cox
2006-09-10 17:19 ` Jesse Barnes
2006-09-10 17:35 ` Michael Buesch
2006-09-10 17:49 ` Linus Torvalds
2006-09-10 18:02 ` Michael Buesch
2006-09-09 15:08 ` Alan Cox
2006-09-09 18:34 ` Auke Kok
2006-09-09 19:10 ` Patrick McFarland
2006-09-09 15:06 ` Alan Cox
2006-09-11 5:03 Michael Chan
2006-09-11 5:21 ` Benjamin Herrenschmidt
2006-09-12 4:30 Albert Cahalan
2006-09-12 5:30 ` Benjamin Herrenschmidt
2006-09-12 6:04 ` Albert Cahalan
2006-09-12 6:12 ` Benjamin Herrenschmidt
2006-09-12 7:09 ` Albert Cahalan
2006-09-12 7:17 ` Benjamin Herrenschmidt
2006-09-12 7:21 ` Albert Cahalan
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=2486D031-097B-45C6-AC47-D8745844C5A3@kernel.crashing.org \
--to=segher@kernel.crashing.org \
--cc=akpm@osdl.org \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=benh@kernel.crashing.org \
--cc=davem@davemloft.net \
--cc=jbarnes@virtuousgeek.org \
--cc=jeff@garzik.org \
--cc=linux-kernel@vger.kernel.org \
--cc=paulus@samba.org \
--cc=torvalds@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®