OpenAFS Master Repository branch, openafs-devel-1_7_x, updated. openafs-devel-1_7_7-12-g6bec896
Gerrit Code Review
gerrit@openafs.org
Tue, 13 Mar 2012 19:36:46 -0700 (PDT)
The following commit has been merged in the openafs-devel-1_7_x branch:
commit 6bec896cdd216eec47e73ff0598555adf37f17dc
Author: Jeffrey Altman <jaltman@your-file-system.com>
Date: Wed Mar 7 06:54:54 2012 -0800
Windows: Wait for memory allocation if necessary
The kernel has a limited pool of memory. If there is no memory
available to satisfy a request, that request will fail initially
with a STATUS_OUT_OF_RESOURCES error which in most cases is exposed
to the user-mode application as STATUS_ACCESS_DENIED. This can
produce inconsistent results.
This patchset introduces an Event object, MemoryAvailableEvent,
which is signalled when the redirector deallocates memory. This
should in many cases permit requests to succeed where they otherwise
would have failed immediately.
The WaitingForMemoryCount field tracks the number of threads that
are waiting for memory to become available. A subsequent patch
could use this value to accelerate the tear down of cached data.
To avoid deadlocks, blocking threads will only wait for a maximum
of 30 seconds at a time. As long as the redirector continues to
free memory, the thread can re-queue itself. However, if a timeout
occurs, the allocation request will fail.
Reviewed-on: http://gerrit.openafs.org/6886
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
(cherry picked from commit 6fb1078e08d4077fb0602f97b1a83bcd72f55db8)
Change-Id: I6d16591e597866d2e5b9592431bc3ba0d7c8de44
Reviewed-on: http://gerrit.openafs.org/6900
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
src/WINNT/afsrdr/common/AFSRedirCommonStructs.h | 8 ++
src/WINNT/afsrdr/kernel/fs/AFSGeneric.cpp | 111 +++++++++++++++++++----
2 files changed, 101 insertions(+), 18 deletions(-)
--
OpenAFS Master Repository