Re: [PATCH V2] scsi: storvsc: Allow only one remove lun work item to be issued per lun

2017-10-31 Thread Cathy Avery
On 10/31/2017 08:24 AM, Martin K. Petersen wrote: If you use alloc_ordered_workqueue directly instead of create_singlethread_workqueue you can pass a format string and don't need the separate allocation. But I'm not sure if Tejun is fine with using __WQ_LEGACY directly.. The only thing that fla

Re: [PATCH V2] scsi: storvsc: Allow only one remove lun work item to be issued per lun

2017-10-31 Thread Martin K. Petersen
>> If you use alloc_ordered_workqueue directly instead of >> create_singlethread_workqueue you can pass a format string and don't >> need the separate allocation. >> >> But I'm not sure if Tejun is fine with using __WQ_LEGACY directly.. > > The only thing that flag does is exempting the workqueue

Re: [PATCH V2] scsi: storvsc: Allow only one remove lun work item to be issued per lun

2017-10-21 Thread Tejun Heo
Hello, On Thu, Oct 19, 2017 at 08:35:10AM -0700, Christoph Hellwig wrote: > On Tue, Oct 17, 2017 at 01:35:21PM -0400, Cathy Avery wrote: > > + /* > > +* Set the error handler work queue. > > +*/ > > + snprintf(host_dev->work_q_name, sizeof(host_dev->work_q_name), > > +"stor

RE: [PATCH V2] scsi: storvsc: Allow only one remove lun work item to be issued per lun

2017-10-19 Thread Long Li
> On Tue, Oct 17, 2017 at 01:35:21PM -0400, Cathy Avery wrote: > > + /* > > +* Set the error handler work queue. > > +*/ > > + snprintf(host_dev->work_q_name, sizeof(host_dev- > >work_q_name), > > +"storvsc_error_wq_%d", host->host_no); > > + host_dev->handle_error_wq = >

Re: [PATCH V2] scsi: storvsc: Allow only one remove lun work item to be issued per lun

2017-10-19 Thread Christoph Hellwig
On Tue, Oct 17, 2017 at 01:35:21PM -0400, Cathy Avery wrote: > + /* > + * Set the error handler work queue. > + */ > + snprintf(host_dev->work_q_name, sizeof(host_dev->work_q_name), > + "storvsc_error_wq_%d", host->host_no); > + host_dev->handle_error_wq = > +

[PATCH V2] scsi: storvsc: Allow only one remove lun work item to be issued per lun

2017-10-17 Thread Cathy Avery
When running multipath on a VM if all available paths go down the driver can schedule large amounts of storvsc_remove_lun work items to the same lun. In response to the failing paths typically storvsc responds by taking host->scan_mutex and issuing a TUR per lun. If there has been heavy IO to the f