Properly change blkfront state to XenbusStateClosed
PATCH 1/1 Properly change blkfront state to XenbusStateClosed
I've just noticed it today.
Follows a fix.
Signature · 3 lines
Glauber de Oliveira Costa Red Hat Inc. "Free as in Freedom"
# HG changeset patch
# User [email protected]
# Date 1164837286 18000
# Node ID 4ac5ffcde6875aa4c772941704fb75261c967462 # Parent ffd048080ce2e50b1e1247709918484d8de54af1 [LINUX] Properly trigger XenbusStateClosed in blkfront
In some situations, like when error happens in block attach for a guest in dom0, backend send us XenbusStateClosing notification. However, as frontend were never properly initialized, it fails to change its own state to XenbusStateClosed, leaving the system in a dead-end state.
Signed-off-by Glauber de Oliveira Costa <[email protected]>
linux-2.6-xen-sparse/drivers/xen/blkfront/blkfront.c +2 -1
@@ -359,7 +359,7 @@ static void blkfront_closing(struct xenbDPRINTK ("blkfront_closing: %s removed\n" , dev->nodename);if (info->rq ==NULL ) -return ; + goto out;spin_lock_irqsave (&blkif_io_lock, flags);/* No more blkif_request(). */
@@ -373,6 +373,7 @@ static void blkfront_closing(struct xenbxlvbd_del (info); +out:xenbus_frontend_closed (dev); }
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel