|
From: | Anthony Liguori |
Subject: | Re: [Qemu-devel] [PATCH] Flush pending AIO on reboot and shutdown. |
Date: | Wed, 13 Aug 2008 10:53:57 -0500 |
User-agent: | Thunderbird 2.0.0.16 (X11/20080723) |
Gleb Natapov wrote:
On Wed, Aug 13, 2008 at 10:07:06AM -0500, Anthony Liguori wrote:Yes, conceptually this is what should be done. But all outstanding block IOrequests are stored in one global list in block-raw.c and this file also provides a global facility to flush all request from this global queue that is why I used it. Otherwise each subsisted will have to be touched to have desired affect.
What happens on reset to outstanding disk requests is a semantic of the controller itself. Really, I think the right thing to do is cancel any request that can be cancelled. If a request cannot be cancelled then we should wait for it to complete.
Now that I think about it, I think your fixing the wrong problem. The issue isn't that the IO requests need to be completed, but that they *will* complete which means that the IDE driver will receive a callback for a request that it no longer knows about (because it was reset). So what we really need to do is modify the IDE device such that when it is reset, it cancels any pending requests.
The fact that this reset happens as a consequence of a system reset is really just a coincidence.
Regards, Anthony Lgiuori
-- Gleb.
[Prev in Thread] | Current Thread | [Next in Thread] |