On Tue, 2018-03-13 at 07:49 -0700, Jens Axboe wrote:
> On 3/13/18 2:18 AM, Christoph Hellwig wrote:
> > bio_check_eod() should check partiton size not the whole disk if
> > bio->bi_partno is non-zero.  Does this by taking the call to bio_check_eod
> > into blk_partition_remap.
> 
> Applied, thanks.

Hello Christoph and Jens,

I think that this patch introduces a severe regression: with this patch applied
a VM that I use for kernel testing doesn't boot anymore. If I revert this patch
that VM boots fine again. This is what I see on the serial console with this
patch applied:

virtio_blk virtio4: [vda] 41943040 512-byte logical blocks (21.5 GB/20.0 GiB)
 vda: vda1
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
scsi host2: Virtio SCSI HBA
scsi 2:0:0:0: Direct-Access     QEMU     QEMU HARDDISK    2.5+ PQ: 0 ANSI: 5
sr 0:0:1:0: [sr0] scsi3-mmc drive: 4x/4x cd/rw xa/form2 tray
cdrom: Uniform CD-ROM driver Revision: 3.20
sr 0:0:1:0: Attached scsi CD-ROM sr0
sg_inq (142) used greatest stack depth: 26912 bytes left
systemd-udevd[90]: could not create device: Invalid argument
systemd-udevd[110]: Inserted 'virtio_scsi'
systemd-udevd[90]: Validate module index
systemd-udevd[110]: passed device to netlink monitor 0x55642693eed0
systemd-udevd[90]: Check if link configuration needs reloading.
systemd-udevd[90]: passed 146 byte device to netlink monitor 0x55642692e7d0
systemd-udevd[123]: passed device to netlink monitor 0x556426980e80
systemd-udevd[90]: passed 176 byte device to netlink monitor 0x55642692e7d0
systemd-udevd[123]: passed device to netlink monitor 0x556426980e80
systemd-udevd[90]: passed 179 byte device to netlink monitor 0x55642692e7d0
sd 2:0:0:0: Power-on or device reset occurred
sd 2:0:0:0: [sda] 5242880 512-byte logical blocks: (2.68 GB/2.50 GiB)
sd 2:0:0:0: [sda] Write Protect is off
sd 2:0:0:0: [sda] Mode Sense: 63 00 00 08
sd 2:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support 
DPO or FUA
systemd-udevd (123) used greatest stack depth: 26576 bytes left
systemd-udevd (121) used greatest stack depth: 24928 bytes left
systemd-udevd (110) used greatest stack depth: 24848 bytes left
sd 2:0:0:0: [sda] Attached SCSI disk
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
systemd-udevd[90]: Validate module index
systemd-udevd[90]: Check if link configuration needs reloading.
systemd-udevd[209]: IMPORT '/usr/bin/sg_inq --export /dev/sda' 
/lib/udev/rules.d/55-scsi-sg3_id.rules:10
systemd-udevd[211]: starting '/usr/bin/sg_inq --export /dev/sda'
systemd-udevd[210]: IMPORT builtin 'path_id' 
/lib/udev/rules.d/60-persistent-storage.rules:66
systemd-udevd[210]: LINK 'disk/by-path/pci-0000:00:07.0' 
/lib/udev/rules.d/60-persistent-storage.rules:68
systemd-udevd[210]: LINK 'disk/by-path/virtio-pci-0000:00:07.0' 
/lib/udev/rules.d/60-persistent-storage.rules:72
systemd-udevd[209]: '/usr/bin/sg_inq --export /dev/sda'(out) 'SCSI_TPGS=0'
systemd-udevd[210]: IMPORT builtin 'blkid' 
/lib/udev/rules.d/60-persistent-storage.rules:83
systemd-udevd[209]: '/usr/bin/sg_inq --export /dev/sda'(out) 'SCSI_TYPE=disk'
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
buffer_io_error: 1 callbacks suppressed
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
buffer_io_error: 1 callbacks suppressed
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
buffer_io_error: 2 callbacks suppressed
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
buffer_io_error: 2 callbacks suppressed
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
attempt to access beyond end of device
vda: rw=0, want=41940872, limit=41938944
Buffer I/O error on dev vda1, logical block 5242352, async page read


Reply via email to