[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1211924335.3286.89.camel@pasglop>
Date: Wed, 28 May 2008 07:38:55 +1000
From: Benjamin Herrenschmidt <benh@...nel.crashing.org>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: David Miller <davem@...emloft.net>, linux-arch@...r.kernel.org,
scottwood@...escale.com, linuxppc-dev@...abs.org,
alan@...rguk.ukuu.org.uk, linux-kernel@...r.kernel.org,
tpiepho@...escale.com
Subject: Re: MMIO and gcc re-ordering issue
> So practically speaking, I suspect that the right approach is to just say
> "ok, x86 will continue to be pretty darn ordered, and the barriers won't
> really matter (*)" but at the same time also saying "we wish reality was
> different, and well-maintained drivers should probably try to work in the
> presense of re-ordering".
Ok, well, I'll slap "memory" clobbers onto powerpc accessors, we made
them fully ordered a while ago anyway. The extra barriers in drivers
like USB etc.. won't hurt us much, we can always fine tune drivers that
really want high performances.
A problem with __raw_ though is that they -also- don't do byteswap,
which is a pain in the neck as people use them for either one reason
(relaxed ordering) or the other (no byteswap) without always knowing the
consequences of doing so...
I'm happy to say that __raw is purely about ordering and make them
byteswap on powerpc tho (ie, make them little endian like the non-raw
counterpart).
Some archs started providing writel_be etc... I added those to powerpc a
little while ago, and I tend to prefer that approach for the byteswap
issue.
What do you think ?
Ben.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists