From: Jeremy Fitzhardinge Subject: [PATCH 3/5] xen/blkfront: Make sure that the device is fully ready before allowing release. Date: Mon, 16 Jun 2008 14:45:01 -0700 Message-ID: <4856DEDD.50306@goop.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Jens Axboe Cc: Xen-devel , Wim Colgate , Linux Kernel Mailing List List-Id: xen-devel@lists.xenproject.org From: Wim Colgate [ linux-2.6.18-xen changeset c1c57fea77e9 ] Signed-off-by: Wim Colgate Signed-off-by: Jeremy Fitzhardinge --- drivers/block/xen-blkfront.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) =================================================================== --- a/drivers/block/xen-blkfront.c +++ b/drivers/block/xen-blkfront.c @@ -997,7 +997,7 @@ struct xenbus_device *dev = info->xbdev; enum xenbus_state state = xenbus_read_driver_state(dev->otherend); - if (state == XenbusStateClosing) + if (state == XenbusStateClosing && info->is_ready) blkfront_closing(dev); } return 0;