]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
vfs: guard end of device for mpage interface
authorAkinobu Mita <akinobu.mita@gmail.com>
Thu, 9 Oct 2014 22:26:55 +0000 (15:26 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 10 Oct 2014 02:25:53 +0000 (22:25 -0400)
commit4db96b71e3caea5bb39053d57683129e0682c66f
treeed8deca97f1b2beb3f73a79a8112d8819fd2df2c
parent59d43914ed7b96255271ad6b7b735344beffa3c0
vfs: guard end of device for mpage interface

Add guard_bio_eod() check for mpage code in order to allow us to do IO
even on the odd last sectors of a device, even if the block size is some
multiple of the physical sector size.

Using mpage_readpages() for block device requires this guard check.

Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: Alexander Viro <viro@zeniv.linux.org.uk>
Cc: Jeff Moyer <jmoyer@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/buffer.c
fs/internal.h
fs/mpage.c