lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1281977523-19335-1-git-send-email-tj@kernel.org>
Date:	Mon, 16 Aug 2010 18:51:58 +0200
From:	Tejun Heo <tj@...nel.org>
To:	jaxboe@...ionio.com, linux-fsdevel@...r.kernel.org,
	linux-scsi@...r.kernel.org, linux-ide@...r.kernel.org,
	linux-kernel@...r.kernel.org, linux-raid@...r.kernel.org,
	hch@....de, James.Bottomley@...e.de, tytso@....edu,
	chris.mason@...cle.com, swhiteho@...hat.com,
	konishi.ryusuke@....ntt.co.jp, dm-devel@...hat.com, vst@...b.net,
	jack@...e.cz, rwheeler@...hat.com, hare@...e.de, neilb@...e.de,
	rusty@...tcorp.com.au, mst@...hat.com
Subject: [RFC PATCHSET block#for-2.6.36-post] block: convert to REQ_FLUSH/FUA

Hello,

This patchset contains five patches to convert block drivers
implementing REQ_HARDBARRIER to support REQ_FLUSH/FUA.

  0001-block-loop-implement-REQ_FLUSH-FUA-support.patch
  0002-virtio_blk-implement-REQ_FLUSH-FUA-support.patch
  0003-lguest-replace-VIRTIO_F_BARRIER-support-with-VIRTIO_.patch
  0004-md-implment-REQ_FLUSH-FUA-support.patch
  0005-dm-implement-REQ_FLUSH-FUA-support.patch

I'm fairly sure about conversions 0001-0003.  0004 should be okay
although multipath wasn't tested.  0005, I'm not quite sure about.  It
works fine for the tests I've done but there are many other targets
and code paths that I didn't test.  So, please be careful with the
last patch.  I think it would be best to route the last two through
the respective md/dm trees after the core part is merged and pulled
into those trees.

The nice thing about the conversion is that in many cases it replaces
postflush with FUA writes which can be handled by request queues lower
in the chain.  For md/dm, this replaces an array wide cacheflush with
FUA writes to only affected member devices.

After this patchset, the followings remain to be converted.

* blktrace

* scsi_error.c for some reason tests REQ_HARDBARRIER.  I think this
  part can be dropped altogether but am not sure.

* drbd and xen.  I have no idea.

These patches are on top of

  block#for-2.6.36-post (c047ab2dddeeafbd6f7c00e45a13a5c4da53ea0b)
+ block-replace-barrier-with-sequenced-flush patchset[1]
+ block-fix-incorrect-bio-request-flag-conversion-in-md patch[2]

and available in the following git tree.

  git://git.kernel.org/pub/scm/linux/kernel/git/tj/misc.git flush-fua

and contain the following changes.

 Documentation/lguest/lguest.c   |   36 +++-----
 drivers/block/loop.c            |   18 ++--
 drivers/block/virtio_blk.c      |   26 ++---
 drivers/md/dm-crypt.c           |    2 
 drivers/md/dm-io.c              |   20 ----
 drivers/md/dm-log.c             |    2 
 drivers/md/dm-raid1.c           |    8 -
 drivers/md/dm-region-hash.c     |   16 +--
 drivers/md/dm-snap-persistent.c |    2 
 drivers/md/dm-snap.c            |    6 -
 drivers/md/dm-stripe.c          |    2 
 drivers/md/dm.c                 |  180 ++++++++++++++++++++--------------------
 drivers/md/linear.c             |    4 
 drivers/md/md.c                 |  117 +++++---------------------
 drivers/md/md.h                 |   23 +----
 drivers/md/multipath.c          |    4 
 drivers/md/raid0.c              |    4 
 drivers/md/raid1.c              |  175 +++++++++++++-------------------------
 drivers/md/raid1.h              |    2 
 drivers/md/raid10.c             |    7 -
 drivers/md/raid5.c              |   38 ++++----
 drivers/md/raid5.h              |    1 
 include/linux/virtio_blk.h      |    6 +
 23 files changed, 278 insertions(+), 421 deletions(-)

--
tejun

[1] http://thread.gmane.org/gmane.linux.kernel/1022363
[2] http://thread.gmane.org/gmane.linux.kernel/1023435
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ