Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1674102
| From | Benjamin Herrenschmidt <benh@kernel.crashing.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 13/17] RISC-V: Add include subdirectory |
| Date | 2017-06-24 17:50 +0200 |
| Message-ID | <tVVtT-1ar-5@gated-at.bofh.it> (permalink) |
| References | <tVIGl-1JB-9@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Fri, 2017-06-23 at 19:01 -0700, Palmer Dabbelt wrote:
> > > +#define mmiowb() __asm__ __volatile__ ("fence io,io" : : : "memory");
I forgot if we already mentioned that but mmiowb is primarily intended
to order MMIO stores vs. a subsequent spin_unlock.
I'm not sure an IO only fence is sufficient here.
Note that I've never trusted drivers to get that right, it's a rather
bad abstraction to begin with, so on powerpc, instead, I just set a
per-cpu flag on every non-relaxed MMIO write and test it in spin_unlock
in order to "beef up" the barrier in there if necessary.
Cheers,
Ben.
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: [PATCH 13/17] RISC-V: Add include subdirectory Palmer Dabbelt <palmer@dabbelt.com> - 2017-06-24 04:10 +0200
Re: [PATCH 13/17] RISC-V: Add include subdirectory Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2017-06-24 17:50 +0200
Re: [patches] Re: [PATCH 13/17] RISC-V: Add include subdirectory Palmer Dabbelt <palmer@dabbelt.com> - 2017-06-24 23:40 +0200
Re: [patches] Re: [PATCH 13/17] RISC-V: Add include subdirectory Benjamin Herrenschmidt <benh@kernel.crashing.org> - 2017-06-25 05:10 +0200
csiph-web