Re: [PATCH v2 4/5] scsi: Add scsi_restart_hctx()

Christoph Hellwig
2017-04-04T06:42:52Z

> +static void scsi_restart_hctx(struct request_queue *q,
> + struct blk_mq_hw_ctx *hctx)
> +{
> + struct blk_mq_tags *tags = hctx->tags;
> + struct blk_mq_tag_set *set = q->tag_set;
> + int i;
> +
> + rcu_read_lock();
> + list_for_each_entry_rcu(q, &set->tag_list, tag_set_list)
> + queue_for_each_hw_ctx(q, hctx, i)
> + if (hctx->tags == tags)
> + blk_mq_sched_restart_hctx(hctx);
> + rcu_read_unlock();
> +}

This looks like generic block layer code, why is it in SCSI?