This provides unified readq()/writeq() helper functions for 32-bit
drivers.
For some cases, readq/writeq without atomicity is harmful, and order of
io access has to be specified explicitly. So in this patch, new two
header files which contain non-atomic readq/writeq are added.
- provides non-atomic readq/
writeq with the order of lower address -> higher address
- provides non-atomic readq/
writeq with reversed order
This allows us to remove some readq()s that were added drivers when the
default non-atomic ones were removed in commit dbee8a0affd5 ("x86:
remove 32-bit versions of readq()/writeq()")
The drivers which need readq/writeq but can do with the non-atomic ones
must add the line:
#include /* or hi-lo.h */
But this will be nop in 64-bit environments, and no other #ifdefs are
required. So I believe that this patch can solve the problem of
1. driver-specific readq/writeq
2. atomicity and order of io access
This patch is tested with building allyesconfig and allmodconfig as
ARCH=x86 and ARCH=i386 on top of tip/master.
Cc: Kashyap Desai
Cc: Len Brown
Cc: Ravi Anand
Cc: Vikas Chaudhary
Cc: Matthew Garrett
Cc: Jason Uhlenkott
Cc: James Bottomley
Cc: Thomas Gleixner
Cc: "H. Peter Anvin"
Cc: Roland Dreier
Cc: James Bottomley
Cc: Alan Cox
Cc: Matthew Wilcox
Cc: Andrew Morton
Signed-off-by: Hitoshi Mitake
Signed-off-by: Linus Torvalds