6634671 domu panicked on mutex when being tested by xmstress and network load together
authormrj
Wed, 02 Jul 2008 20:01:51 -0700
changeset 7017 131719b72ca5
parent 7016 8b85f8b0129c
child 7018 3ef7992cecec
6634671 domu panicked on mutex when being tested by xmstress and network load together
usr/src/uts/common/xen/io/xdf.c
--- a/usr/src/uts/common/xen/io/xdf.c	Wed Jul 02 19:06:00 2008 -0700
+++ b/usr/src/uts/common/xen/io/xdf.c	Wed Jul 02 20:01:51 2008 -0700
@@ -488,6 +488,7 @@
 	if (vdp->xdf_vd_lbl != NULL) {
 		cmlb_detach(vdp->xdf_vd_lbl, NULL);
 		cmlb_free_handle(&vdp->xdf_vd_lbl);
+		vdp->xdf_vd_lbl = NULL;
 	}
 #if !defined(XPV_HVM_DRIVER)
 	xdf_kstat_delete(devi);
@@ -2126,8 +2127,11 @@
 		xdf_iostart(vdp);
 	} else if ((status == XD_CLOSED) && !unexpect_die) {
 		/* interface is closed successfully, remove all minor nodes */
-		cmlb_detach(vdp->xdf_vd_lbl, NULL);
-		cmlb_free_handle(&vdp->xdf_vd_lbl);
+		if (vdp->xdf_vd_lbl != NULL) {
+			cmlb_detach(vdp->xdf_vd_lbl, NULL);
+			cmlb_free_handle(&vdp->xdf_vd_lbl);
+			vdp->xdf_vd_lbl = NULL;
+		}
 	}
 }