That's not what I meant. Suppose the driver wants to carry out special
requests A and B before carrying out request R, which is initially at
the head of the queue. The driver inserts A at the front, calls
blk_start_queue(), and inserts B at the front when A completes.
What's to prevent the block layer from sending R to the driver while A
I see. You're suggesting we add a new "power_mode" or "queue_idle"
callback to the request_queue struct, and make the block layer invoke
this callback whenever a request completes and there are no other
requests pending or in flight. Right? And similarly, invoke the
callback (with a different argument) when the first request gets added
to an otherwise empty queue.
That would suit my needs.
Alan Stern
--