Andrew Morton wrote: >Nick Piggin wrote: > >>But I'm guessing that you have no requests in flight by the time >> blk_congestion_wait gets called, so nothing ever gets kicked. >> > >That's why blk_congestion_wait() in -mm propagates the schedule_timeout() >return value. You can do: > > if (blk_congestion_wait(...)) > printk("ouch\n"); > >If your kernel says ouch much, we have a problem. > > Martin, have you tried adding this printk? Andrew, could you take the following patch (even though it didn't fix the problem). I think the smp_mb isn't needed because the rl waitqueue stuff is serialised by the queue spinlocks. The addition of the smp_mb and the other change is to try to close the window for races a bit. Obviously they can still happen, it's a racy interface and it doesn't matter much.