block: add code to track actual device queue depth
authorJens Axboe <axboe@fb.com>
Wed, 30 Mar 2016 16:21:08 +0000 (10:21 -0600)
committerJens Axboe <axboe@fb.com>
Tue, 25 Oct 2016 02:55:31 +0000 (20:55 -0600)
commit0d9f7fd7558fa87e0b4661865e730c3638a9bff7
treed7ae89f2d29be48c2c692f2ac51bbe2637241e2a
parent1a4ae841640c6f5457bf8dc4b4454a41b84a9928
block: add code to track actual device queue depth

For blk-mq, ->nr_requests does track queue depth, at least at init
time. But for the older queue paths, it's simply a soft setting.
On top of that, it's generally larger than the hardware setting
on purpose, to allow backup of requests for merging.

Fill a hole in struct request with a 'queue_depth' member, that
drivers can call to more closely inform the block layer of the
real queue depth.

Signed-off-by: Jens Axboe <axboe@fb.com>
block/blk-settings.c
drivers/scsi/scsi.c
include/linux/blkdev.h