[PATCH 5/5] nvme/pci: Complete all stuck requests

Christoph Hellwig hch at lst.de
Mon Feb 20 02:05:15 PST 2017


> > > +		 * If we are resuming from suspend, the queue was set to freeze
> > > +		 * to prevent blk-mq's hot CPU notifier from getting stuck on
> > > +		 * requests that entered the queue that NVMe had quiesced. Now
> > > +		 * that we are resuming and have notified blk-mq of the new h/w
> > > +		 * context queue count, it is safe to unfreeze the queues.
> > > +		 */
> > > +		if (was_suspend)
> > > +			nvme_unfreeze(&dev->ctrl);
> > 
> > And this change I don't understand at all.  It doesn't seem to pair
> > up with anything else in the patch.
> 
> If we had done a controller shutdown, as would happen on a system suspend,
> the resume needs to restore the queue freeze depth. That's all this
> is doing.

I've spent tons of times trying to understand this, but still fail
to.  Where is the nvme_start_freeze / nvme_wait_freeze that this
pairs with?



More information about the Linux-nvme mailing list