]> git.baikalelectronics.ru Git - kernel.git/commit
dm table: pass correct dev area size to device_area_is_valid
authorMike Snitzer <snitzer@redhat.com>
Thu, 23 Jul 2009 19:30:42 +0000 (20:30 +0100)
committerAlasdair G Kergon <agk@redhat.com>
Thu, 23 Jul 2009 19:30:42 +0000 (20:30 +0100)
commit9236fb1724320050f96a36a25fedefa7d35aa250
treec85bcee4f90729927285fc282c6df94bf18d023d
parent412d17fc6dae3d2dc638636b16a3cf2a742acfa1
dm table: pass correct dev area size to device_area_is_valid

Incorrect device area lengths are being passed to device_area_is_valid().

The regression appeared in 2.6.31-rc1 through commit
e965ab5a47d097b37fb4d7755d9b1c3869a36d1a.

With the dm-stripe target, the size of the target (ti->len) was used
instead of the stripe_width (ti->len/#stripes).  An example of a
consequent incorrect error message is:

  device-mapper: table: 254:0: sdb too small for target

Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
drivers/md/dm-crypt.c
drivers/md/dm-delay.c
drivers/md/dm-linear.c
drivers/md/dm-mpath.c
drivers/md/dm-raid1.c
drivers/md/dm-stripe.c
drivers/md/dm-table.c
include/linux/device-mapper.h