Messages in this thread | | | Date | Mon, 23 Jan 2012 15:04:27 -0800 | From | "H. Peter Anvin" <> | Subject | Re: [PATCH] NVMe: Fix compilation on architecturs without readq/writeq |
| |
On 01/23/2012 08:57 AM, Linus Torvalds wrote: > On Mon, Jan 23, 2012 at 8:05 AM, Hitoshi Mitake<h.mitake@gmail.com> wrote: >> >> I wrote the patch which adds the new file include/asm-generic/io-nonatomic.h. >> io-nonatomic.h provides non-atomic version readq()/writeq(). > > I do wonder if we should do "little-endian" and "big-endian" variations? > > Quoting Willy: > > "For this particular hardware, it's defined to work if you read the > low order bits first" > > so I think we need make that explicit, and make two include files: > > include/asm-generic/io-64b-lo-hi.h > include/asm-generic/io-64b-hi-lo.h > > or something like that. And thus indirectly document these kinds of > requirements. >
I would concur with this (and I have suggested exactly this in the past.)
-hpa
| |