[PATCH 2/3] nvme: Sync queues on controller resets

Keith Busch keith.busch at intel.com
Mon Feb 12 13:46:02 PST 2018


On Sun, Feb 11, 2018 at 09:53:03AM +0800, jianchao.wang wrote:
> On 02/10/2018 09:55 AM, jianchao.wang wrote:
> > There could be a circular pattern here. Please consider the following scenario:
> > 
> > timeout_work context                    reset_work context
> > nvme_timeout                            nvme_reset_work
> >   -> nvme_dev_disable                     -> nvme_sync_queues // hold namespace_mutex
> >     -> nvme_stop_queues                     -> blk_sync_queue
> >       -> require namespaces_mutex               -> cancel_work_sync(&q->timeout_work)
> > 
> 
> Looks like we could use rwsem to replace namespaces_mutex.

Looks like rwsem is queued up for 4.17. I'll send an update based on
that. I guess this one and 3/3 can wait for 4.17, but 1/3 should still
go in 4.16.



More information about the Linux-nvme mailing list