diff options
| author | 2008-05-27 09:47:13 -0700 | |
|---|---|---|
| committer | 2008-06-02 12:29:31 +0200 | |
| commit | c1f64a58003fd2efaa725a857e269a15f765791a (patch) | |
| tree | 68a09bddb1c16fbcc748df41ddca4edb4442cb56 /arch/x86/mm/fault.c | |
| parent | Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6 (diff) | |
| download | linux-dev-c1f64a58003fd2efaa725a857e269a15f765791a.tar.xz linux-dev-c1f64a58003fd2efaa725a857e269a15f765791a.zip | |
x86: MMIO and gcc re-ordering issue
On Tue, 27 May 2008, Linus Torvalds wrote:
>
> Expecting people to fix up all drivers is simply not going to happen. And
> serializing things shouldn't be *that* expensive. People who cannot take
> the expense can continue to use the magic __raw_writel() etc stuff.
Of course, for non-x86, you kind of have to expect drivers to be
well-behaved, so non-x86 can probably avoid this simply because there are
less relevant drivers involved.
Here's a UNTESTED patch for x86 that may or may not compile and work, and
which serializes (on a compiler level) the IO accesses against regular
memory accesses.
__read[bwlq]()/__write[bwlq]() are not serialized with a :"memory"
barrier, although since they still use "asm volatile" I suspect that i
practice they are probably serial too. Did not look very closely at any
generated code (only did a trivial test to see that the code looks
*roughly* correct).
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/mm/fault.c')
0 files changed, 0 insertions, 0 deletions
