]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
block: fix bio splitting on max sectors
authorMing Lei <tom.leiming@gmail.com>
Sat, 23 Jan 2016 00:05:33 +0000 (08:05 +0800)
committerJens Axboe <axboe@fb.com>
Sat, 23 Jan 2016 03:42:30 +0000 (20:42 -0700)
commitd0e5fbb01a67e400e82fefe4896ea40c6447ab98
tree3c8d2fd4fe59ab2c278d26a2bc37209ba4765195
parentb82dde0230439215b55e545880e90337ee16f51a
block: fix bio splitting on max sectors

After commit e36f62042880(block: split bios to maxpossible length),
bio can be splitted in the middle of a vector entry, then it
is easy to split out one bio which size isn't aligned with block
size, especially when the block size is bigger than 512.

This patch fixes the issue by making the max io size aligned
to logical block size.

Fixes: e36f62042880(block: split bios to maxpossible length)
Reported-by: Stefan Haberland <sth@linux.vnet.ibm.com>
Cc: Keith Busch <keith.busch@intel.com>
Suggested-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Ming Lei <tom.leiming@gmail.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
block/blk-merge.c