Re: [PATCH v3 04/15] scsi: replace blk_mq_pci_map_queues with blk_mq_dev_map_queues

From: Daniel Wagner
Date: Tue Aug 13 2024 - 05:39:43 EST


On Mon, Aug 12, 2024 at 04:31:32PM GMT, John Garry wrote:
> On 06/08/2024 13:06, Daniel Wagner wrote:
> > Replace all users of blk_mq_pci_map_queues with the more generic
> > blk_mq_dev_map_queues. This in preparation to retire
> > blk_mq_pci_map_queues.
>
> nit: About blk_mq_dev_map_queues(), from the name it gives the impression
> that we deal in struct device, which is not the case.

What about blk_mq_hctx_map_queues?

> > +static const struct cpumask *hisi_hba_get_queue_affinity(void *dev_data,
> > + int offset, int idx)
>
> personally I think that name "queue" would be better than "idx"

Yes, makes sense and would be more consistent with the rest of the code.

> > + return blk_mq_dev_map_queues(qmap, hisi_hba, 96,
>
> blk_mq_dev_map_queues() returns void, and so we should not return the value
> (which is void).
>
> And I know that the current code is like this, but using CQ0_IRQ_INDEX
> instead of 96 would be nicer.

Sure, will do.