]> err.no Git - linux-2.6/commit
[PATCH] dm: mirror sector offset fix
authorNeil Brown <neilb@suse.de>
Mon, 26 Jun 2006 07:27:26 +0000 (00:27 -0700)
committerLinus Torvalds <torvalds@g5.osdl.org>
Mon, 26 Jun 2006 16:58:35 +0000 (09:58 -0700)
commite4c8b3ba34cc1aeab451c7a5cc843c5fd62cbe3d
tree2b211393b1ffacd05a7fbae994012b7000e2c233
parentf0b04115368ff383654a3bd26baf8f4be5e81132
[PATCH] dm: mirror sector offset fix

The device-mapper core does not perform any remapping of bios before passing
them to the targets.  If a particular mapping begins part-way into a device,
targets obtain the sector relative to the start of the mapping by subtracting
ti->begin.

The dm-raid1 target didn't do this everywhere: this patch fixes it, taking
care to subtract ti->begin exactly once for each bio.

[akpm: too late for 2.6.17 - suitable for 2.6.17.x after it has settled]

Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
drivers/md/dm-raid1.c