[PATCH for-4.4] NVMe: IO ending fixes on surprise removal

Sagi Grimberg sagig at dev.mellanox.co.il
Sun Dec 13 06:59:52 PST 2015


> -	if (kill)
> +	if (kill) {
>   		blk_set_queue_dying(ns->queue);
> +
> +		/*
> +		 * The controller was shutdown first if we got here through
> +		 * device removal. The shutdown may requeue outstanding
> +		 * requests. These need to be aborted immediately so
> +		 * del_gendisk doesn't block indefinitely for their completion.
> +		 */
> +		blk_mq_abort_requeue_list(ns->queue);

Something looks convoluted a bit here.
We abort_requeue_list here and...

> +	}
>   	if (ns->disk->flags & GENHD_FL_UP)
>   		del_gendisk(ns->disk);
>   	if (kill || !blk_queue_dying(ns->queue)) {

Here again?



More information about the Linux-nvme mailing list