--- /dev/null
+Bottom: 3b5e1a76ae1d8ad2397f01e61749083ee7a6dfa0
+Top: 0c89e024c4bfe8ad32fa2a3126a05065e8804f95
+Author: U-AMR\MSHEFTY <MSHEFTY@mshefty-MOBL2.amr.corp.intel.com>
+Date: 2009-12-07 14:55:18 -0800
+
+Refresh of debug
+
+---
+
+diff --git a/trunk/core/al/kernel/al_cm.c b/trunk/core/al/kernel/al_cm.c
+index 673e9bd..a571624 100644
+--- a/trunk/core/al/kernel/al_cm.c
++++ b/trunk/core/al/kernel/al_cm.c
+@@ -37,7 +37,8 @@
+ typedef struct _iba_cm_id_priv\r
+ {\r
+ iba_cm_id id;\r
+- KEVENT destroy_event; \r
++ KEVENT destroy_event;\r
++int destroyed;\r
+ \r
+ } iba_cm_id_priv;\r
+ \r
+@@ -55,6 +56,7 @@ cm_alloc_id(NTSTATUS (*callback)(iba_cm_id *p_id, iba_cm_event *p_event),
+ KeInitializeEvent(&id->destroy_event, NotificationEvent, FALSE);\r
+ id->id.callback = callback;\r
+ id->id.context = context;\r
++id->destroyed = 0;\r
+ return &id->id;\r
+ }\r
+ \r
+@@ -68,6 +70,12 @@ static void
+ cm_destroy_handler(void *context)\r
+ {\r
+ iba_cm_id_priv *id = context;\r
++if (id->destroyed) {\r
++ DbgPrintEx(DPFLTR_IHVDRIVER_ID, 0, "cm_destroy_handler cid 0x%x already gave up\n",\r
++ id->id.cid);\r
++ cm_free_id(&id->id);\r
++}\r
++\r
+ KeSetEvent(&id->destroy_event, 0, FALSE);\r
+ }\r
+ \r
+@@ -142,13 +150,14 @@ NTSTATUS status;
+ \r
+ id = CONTAINING_RECORD(p_id, iba_cm_id_priv, id);\r
+ kal_cep_destroy(gh_al, p_id->cid, STATUS_SUCCESS);\r
+-timeout.QuadPart = -10 * 1000000 * 10;\r
++timeout.QuadPart = -20 * 1000000 * 10;\r
+ status =\r
+ KeWaitForSingleObject(&id->destroy_event, Executive, KernelMode, FALSE, &timeout);\r
++id->destroyed = 1;\r
+ if (status != STATUS_SUCCESS)\r
+- DbgPrintEx(DPFLTR_IHVDRIVER_ID, 0, "cm_destroy_id 0x%x cid 0x%x\n",\r
++ DbgPrintEx(DPFLTR_IHVDRIVER_ID, 0, "cm_destroy_id wait error 0x%x cid 0x%x\n",\r
+ status, p_id->cid);\r
+- \r
++else\r
+ cm_free_id(p_id);\r
+ }\r
+ \r
+diff --git a/trunk/core/al/kernel/al_cm_cep.c b/trunk/core/al/kernel/al_cm_cep.c
+index 755371e..c52cc71 100644
+--- a/trunk/core/al/kernel/al_cm_cep.c
++++ b/trunk/core/al/kernel/al_cm_cep.c
+@@ -4199,8 +4199,8 @@ signalled = p_cep->signalled;
+ KeReleaseInStackQueuedSpinLock( &hdl );\r
+ \r
+ if (pfn_destroy_cb && ref_cnt)\r
+- DbgPrintEx(DPFLTR_IHVDRIVER_ID, 0, "kal_cep_destroy %p 0x%x ref 0x%x signal %d\n",\r
+- p_cep, cid, ref_cnt, signalled);\r
++ DbgPrintEx(DPFLTR_IHVDRIVER_ID, 0, "kal_cep_destroy cid 0x%x retries %d timeout 0x%x ref 0x%x signal %d\n",\r
++ cid, p_cep->max_cm_retries, p_cep->retry_timeout, ref_cnt, signalled);\r
+ \r
+ if( !ref_cnt && pfn_destroy_cb )\r
+ pfn_destroy_cb( context );