lkml.org 
[lkml]   [2005]   [Jun]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] device-mapper: dm-raid1: Limit bios to size of mirror region
Set the target's split_io field when building a dm-mirror device so
incoming bios won't span the mirror's internal regions. Without
this, regions can be accessed while not holding correct locks and data
corruption is possible.

Reported-By: "Zhao Qian" <zhaoqian@aaastor.com>
From: Kevin Corry <kevcorry@us.ibm.com>
Signed-Off-By: Alasdair G Kergon <agk@redhat.com>

--- diff/drivers/md/dm-raid1.c 2005-06-17 20:48:29.000000000 +0100
+++ source/drivers/md/dm-raid1.c 2005-06-29 21:12:13.000000000 +0100
@@ -1060,6 +1060,7 @@
}

ti->private = ms;
+ ti->split_io = ms->rh->region_size;

r = kcopyd_client_create(DM_IO_PAGES, &ms->kcopyd_client);
if (r) {
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-06-30 20:24    [W:0.059 / U:0.120 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site