[ofw] [PATCH] winverbs: ensure that event and mutex memory are resident

Sean Hefty sean.hefty at intel.com
Tue Aug 25 13:59:44 PDT 2009


The winverbs PD structure contains both an event and a guarded mutex.  Both must
be allocated as part of resident memory, or vague system corruptions may occur
if their memory is paged out.

The fix is to allocate the PD structure from NonPagedPool.

Signed-off-by: Sean Hefty <sean.hefty at intel.com>
---
This fix needs to go into winof 2.1

Index: core/winverbs/kernel/wv_pd.c
===================================================================
--- core/winverbs/kernel/wv_pd.c	(revision 2342)
+++ core/winverbs/kernel/wv_pd.c	(working copy)
@@ -74,7 +74,7 @@
 	ib_api_status_t			ib_status;
 	WV_PROTECTION_DOMAIN	*pd;
 
-	pd = ExAllocatePoolWithTag(PagedPool, sizeof(WV_PROTECTION_DOMAIN),
'dpvw');
+	pd = ExAllocatePoolWithTag(NonPagedPool, sizeof(WV_PROTECTION_DOMAIN),
'dpvw');
 	if (pd == NULL) {
 		return STATUS_NO_MEMORY;
 	}

-------------- next part --------------
A non-text attachment was scrubbed...
Name: wv-pd.diff
Type: application/octet-stream
Size: 493 bytes
Desc: not available
URL: <http://lists.openfabrics.org/pipermail/ofw/attachments/20090825/fab93451/attachment.obj>


More information about the ofw mailing list