linux/drivers/block
Hitoshi Mitake 797a796a13 asm-generic: architecture independent readq/writeq for 32bit environment
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.

 - <asm-generic/io-64-nonatomic-lo-hi.h> provides non-atomic readq/
   writeq with the order of lower address -> higher address

 - <asm-generic/io-64-nonatomic-hi-lo.h> 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 dbee8a0aff ("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 <asm-generic/io-64-nonatomic-lo-hi.h> /* 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 <Kashyap.Desai@lsi.com>
Cc: Len Brown <lenb@kernel.org>
Cc: Ravi Anand <ravi.anand@qlogic.com>
Cc: Vikas Chaudhary <vikas.chaudhary@qlogic.com>
Cc: Matthew Garrett <mjg@redhat.com>
Cc: Jason Uhlenkott <juhlenko@akamai.com>
Cc: James Bottomley <James.Bottomley@parallels.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Roland Dreier <roland@purestorage.com>
Cc: James Bottomley <jbottomley@parallels.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Matthew Wilcox <matthew.r.wilcox@intel.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Hitoshi Mitake <h.mitake@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-02-21 16:47:28 -08:00
..
aoe switch device_get_devnode() and ->devnode() to umode_t * 2012-01-03 22:54:55 -05:00
drbd module_param: make bool parameters really bool (drivers & misc) 2012-01-13 09:32:20 +10:30
mtip32xx mtip32xx: removed the irrelevant argument of mtip_hw_submit_io() and the unused member of struct driver_data 2012-02-07 07:54:31 +01:00
paride paride/pcd: fix bool verbose module parameter. 2012-01-13 09:32:26 +10:30
xen-blkback Merge branch 'for-3.3/drivers' of git://git.kernel.dk/linux-block 2012-01-15 12:48:41 -08:00
amiflop.c fs: move code out of buffer.c 2012-01-03 22:54:07 -05:00
ataflop.c block: unexport DISK_EVENT_MEDIA_CHANGE for legacy/fringe drivers 2011-04-21 21:33:05 +02:00
brd.c fs: move code out of buffer.c 2012-01-03 22:54:07 -05:00
cciss_cmd.h cciss: use new doorbell-bit-5 reset method 2011-05-06 08:23:55 -06:00
cciss_scsi.c cciss: auto engage SCSI mid layer at driver load time 2011-11-16 09:21:49 +01:00
cciss_scsi.h cciss: add cciss_tape_cmds module paramter 2011-05-06 08:23:59 -06:00
cciss.c block: add and use scsi_blk_cmd_ioctl 2012-01-14 15:07:24 -08:00
cciss.h cciss: Adds simple mode functionality 2011-08-08 11:40:15 +02:00
cpqarray.c drivers/block/cpqarray.c: use pci_dev->revision 2011-09-21 10:02:13 +02:00
cpqarray.h
cryptoloop.c
DAC960.c block: unexport DISK_EVENT_MEDIA_CHANGE for legacy/fringe drivers 2011-04-21 21:33:05 +02:00
DAC960.h
floppy.c floppy: Fix a crash during rmmod 2012-02-08 20:03:39 +01:00
hd.c i8253: Create linux/i8253.h and use it in all 8253 related files 2011-06-09 15:01:37 +02:00
ida_cmd.h
ida_ioctl.h
Kconfig Merge git://git.infradead.org/users/willy/linux-nvme 2012-01-18 12:34:09 -08:00
loop.c loop: zero fill bio instead of return -EIO for partial read 2012-02-08 22:07:19 +01:00
Makefile Merge git://git.infradead.org/users/willy/linux-nvme 2012-01-18 12:34:09 -08:00
mg_disk.c block: switch s390 tape_block and mg_disk to elevator_change() 2010-08-23 14:02:44 +02:00
nbd.c nbd-replace-some-printk-with-dev_warn-and-dev_info-checkpatch-fixes 2011-08-19 14:48:28 +02:00
nvme.c asm-generic: architecture independent readq/writeq for 32bit environment 2012-02-21 16:47:28 -08:00
osdblk.c block: remove spurious uses of REQ_HARDBARRIER 2010-09-10 12:35:36 +02:00
pktcdvd.c switch device_get_devnode() and ->devnode() to umode_t * 2012-01-03 22:54:55 -05:00
ps3disk.c block: Fix files that are modules and hence need module.h 2011-10-31 19:31:13 -04:00
ps3vram.c Merge branch 'modsplit-Oct31_2011' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux 2011-11-06 19:44:47 -08:00
rbd_types.h rbd: introduce rados block device (rbd), based on libceph 2010-10-20 15:38:13 -07:00
rbd.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client 2012-02-02 15:47:33 -08:00
smart1,2.h fix typos 'comamnd' -> 'command' in comments 2011-02-02 11:31:21 +01:00
sunvdc.c block: Consolidate phys_segment and hw_segment limits 2010-02-26 13:58:08 +01:00
swim3.c block/swim3: Locking fixes 2011-12-12 12:42:12 +01:00
swim_asm.S
swim.c m68k/mac: cleanup forward declarations 2011-12-10 19:52:46 +01:00
sx8.c block, sx8: kill blk_insert_request() 2011-12-14 00:33:37 +01:00
ub.c block: add and use scsi_blk_cmd_ioctl 2012-01-14 15:07:24 -08:00
umem.c block: remove support for bio remapping from ->make_request 2011-09-12 12:12:01 +02:00
umem.h
viodasd.c Fix common misspellings 2011-03-31 11:26:23 -03:00
virtio_blk.c block: add and use scsi_blk_cmd_ioctl 2012-01-14 15:07:24 -08:00
xd.c module_param: make bool parameters really bool (drivers & misc) 2012-01-13 09:32:20 +10:30
xd.h
xen-blkfront.c Merge branch 'for-3.3/drivers' of git://git.kernel.dk/linux-block 2012-01-15 12:48:41 -08:00
xsysace.c block: xsysace: Don't use NO_IRQ 2012-01-05 08:34:29 +01:00
z2ram.c drivers/block/z2ram.c: correct printing of sector_t 2010-10-28 06:15:26 -06:00