Greg Edwards 67f2519fe2 fs: guard_bio_eod() needs to consider partitions
guard_bio_eod() needs to look at the partition capacity, not just the
capacity of the whole device, when determining if truncation is
necessary.

[   60.268688] attempt to access beyond end of device
[   60.268690] unknown-block(9,1): rw=0, want=67103509, limit=67103506
[   60.268693] buffer_io_error: 2 callbacks suppressed
[   60.268696] Buffer I/O error on dev md1p7, logical block 4524305, async page read

Fixes: 74d46992e0d9 ("block: replace bi_bdev with a gendisk pointer and partitions index")
Cc: stable@vger.kernel.org # v4.13
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Greg Edwards <gedwards@ddn.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2017-11-10 19:55:57 -07:00
..
2017-09-04 19:05:15 -04:00
2017-08-24 13:23:03 -07:00
2017-09-12 20:05:58 -07:00
2017-09-11 22:01:44 -07:00
2017-09-14 20:04:32 -07:00
2017-07-06 03:31:46 -04:00
2017-09-08 19:33:25 -07:00
2017-09-04 19:05:15 -04:00
2017-09-04 19:05:15 -04:00
2017-04-17 12:52:27 -04:00
2016-12-14 23:48:11 -05:00
2017-06-22 11:44:55 -04:00
2017-07-06 03:27:09 -04:00
2017-07-06 03:27:09 -04:00
2017-05-08 17:15:12 -07:00
2017-08-17 22:06:03 +02:00
2017-09-03 20:24:30 -04:00