android_kernel_samsung_a7y1.../block
Ming Lei 15e2533507 block: don't use bio->bi_vcnt to figure out segment number
[ Upstream commit 1a67356e9a4829da2935dd338630a550c59c8489 ]

It is wrong to use bio->bi_vcnt to figure out how many segments
there are in the bio even though CLONED flag isn't set on this bio,
because this bio may be splitted or advanced.

So always use bio_segments() in blk_recount_segments(), and it shouldn't
cause any performance loss now because the physical segment number is figured
out in blk_queue_split() and BIO_SEG_VALID is set meantime since
bdced438acd83ad83a6c ("block: setup bi_phys_segments after splitting").

Reviewed-by: Omar Sandoval <osandov@fb.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Fixes: 76d8137a3113 ("blk-merge: recaculate segment if it isn't less than max segments")
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-04-07 13:40:31 +02:00
..
partitions A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
bio-integrity.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
bio.c block: do not leak memory in bio_copy_user_iov() 2020-04-06 15:08:22 +02:00
blk-cgroup.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-core.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-exec.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-flush.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-integrity.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-ioc.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-iopoll.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-lib.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-map.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-merge.c block: don't use bio->bi_vcnt to figure out segment number 2020-04-07 13:40:31 +02:00
blk-mq-cpu.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-mq-cpumap.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-mq-sysfs.c blk-mq: make sure that line break can be printed 2020-04-07 13:08:08 +02:00
blk-mq-tag.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-mq-tag.h A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-mq.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-mq.h A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-settings.c block: fix an integer overflow in logical block size 2020-04-07 13:37:29 +02:00
blk-softirq.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-sysfs.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-tag.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-throttle.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk-timeout.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
blk.h A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
bounce.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
bsg-lib.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
bsg.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
cfq-iosched.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
cmdline-parser.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
compat_ioctl.c compat_ioctl: block: handle Persistent Reservations 2020-04-07 13:24:43 +02:00
deadline-iosched.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
elevator.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
genhd.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
ioctl.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
ioprio.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
Kconfig A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
Kconfig.iosched A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
Makefile A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
noop-iosched.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
partition-generic.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
scsi_ioctl.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30
t10-pi.c A750FXXU4CTBC 2020-03-27 21:51:54 +05:30