From: Mikulas Patocka Date: Mon, 22 Jun 2009 09:12:26 +0000 (+0100) Subject: dm snapshot: use barrier when writing exception store X-Git-Tag: v2.6.31-rc1~8^2~19 X-Git-Url: http://pileus.org/git/?a=commitdiff_plain;h=2bd023452592e5f5cf90dd426cc39b7632b15b76;p=~andy%2Flinux dm snapshot: use barrier when writing exception store Send barrier requests when updating the exception area. Exception area updates need to be ordered w.r.t. data writes, so that the writes are not reordered in hardware disk cache. Signed-off-by: Mikulas Patocka Signed-off-by: Alasdair G Kergon --- diff --git a/drivers/md/dm-snap-persistent.c b/drivers/md/dm-snap-persistent.c index 2662a41337e..6e3fe4f1493 100644 --- a/drivers/md/dm-snap-persistent.c +++ b/drivers/md/dm-snap-persistent.c @@ -636,7 +636,7 @@ static void persistent_commit_exception(struct dm_exception_store *store, /* * Commit exceptions to disk. */ - if (ps->valid && area_io(ps, WRITE)) + if (ps->valid && area_io(ps, WRITE_BARRIER)) ps->valid = 0; /*