Re: [PATCH 31/40] libata: take advantage of cmwq and remove concurrency limitations

Tejun Heo
2010-01-19T00:45:43Z

Hello,

On 01/19/2010 12:48 AM, Stefan Richter wrote:
>> b. ata_aux_wq which is used for SCSI probing has single thread. In
>> cases where SCSI probing is stalled for extended period of time
>> which is possible for ATAPI devices, this will stall all probing.
>
> Are things like INQUIRY and possibly motor spin-up performed there?
> If yes, ...

For disks, they are all done by EH. Responses to INQUIRYs are
constructed by libata from the data it has acquired during parallel
ATA probing, so there's nothing much going on there. For ATAPI
devices, it's a different story tho.

>> @@ -3408,8 +3408,7 @@ void ata_scsi_scan_host(struct ata_port *ap, int sync)
>> " switching to async\n");
>> }
>>
>> - queue_delayed_work(ata_aux_wq, &ap->hotplug_task,
>> - round_jiffies_relative(HZ));
>> + schedule_delayed_work(&ap->hotplug_task, round_jiffies_relative(HZ));
>> }
>>
>> /**
> [...]
>
> ... wouldn't queue_delayed_work(system_long_wq, &ap->hotplug_task, ...);
> be more appropriate then?

Hmmm... yeah, right, I'll update it. I'm thinking about adding a
debug option to trigger a warning if a work queued on the default
workqueue takes longer than, say, 30secs to finish.

Thanks.

--
tejun