On Thu, Mar 08, 2018 at 08:54:43AM +0100, Christoph Hellwig wrote:
> > + /* 256 tags should be high enough to saturate device */
> > + int max_queues = DIV_ROUND_UP(h->scsi_host->can_queue, 256);
> > +
> > + /* per NUMA node hw queue */
> > + h->scsi_host->nr_hw_queues = min_t(int,
> + /* 256 tags should be high enough to saturate device */
> + int max_queues = DIV_ROUND_UP(h->scsi_host->can_queue, 256);
> +
> + /* per NUMA node hw queue */
> + h->scsi_host->nr_hw_queues = min_t(int, nr_node_ids, max_queues);
I don't think this magic should be in a driver.
It is observed that IOPS can be improved much by simply making
hw queue per NUMA node on null_blk, so this patch applies the
introduced .host_tagset for improving performance.
In reality, .can_queue is quite big, and NUMA node number is
often small, so each hw queue's depth should be high enough