1 Nov 2008 17:54
Problems with the block-layer timeouts
Alan Stern <stern <at> rowland.harvard.edu>
2008-11-01 16:54:32 GMT
2008-11-01 16:54:32 GMT
James and Jens: I spent most of the day yesterday debugging some tricky problems in the new block-layer timeout scheme. Clearly it is in need of more work. A major reason for these problems was that there doesn't seem to be a clear a idea of when the timeout period should begin. In blk_add_timer() a comment says: * Each request has its own timer, and as it is added to the queue, we * set up the timer. On the other hand, elv_next_request() says: * We are now handing the request to the hardware, * add the timeout handler (Note that this comment is wrong for an additional reason. elv_next_request() doesn't hand the request to the hardware; it hands the request to a driver. What the driver chooses to do with the request is its own affair.) So when should the timeout begin? The most logical time is when the driver does send the request to the hardware. Of course, the block core has no way to know when that happens, so a suitable proxy might be when the request is removed from the block queue. (On the other hand, are there drivers which don't bother to dequeue a request until it has completed?) Either way, both the comments above and the actual code should be changed.(Continue reading)
RSS Feed