On Tue, Apr 20, 2021 at 12:06:24AM +0800, John Garry wrote:
Function sdev_store_queue_depth() enforces that the sdev queue depth cannot
However, the LLDD may still set cmd_per_lun > can_queue, which leads to an
initial sdev queue depth greater than can_queue.
Stop this happened by capping initial sdev queue depth at can_queue.
Signed-off-by: John Garry <john.garry@xxxxxxxxxx>
Topic originally discussed at:
Last idea there was to error/warn in scsi_add_host() for cmd_per_lun >
No, that isn't my suggestion.
can_queue. However, such a shost driver could still configure the sdev
queue depth to be sound value at .slave_configure callback, so now thinking
the orig patch better.
As I mentioned last time, why can't we fix ->cmd_per_lun in
scsi_add_host() using .can_queue?