[CRIU] [PATCH 2/6] lock: Add completion helpers
Cyrill Gorcunov
gorcunov at openvz.org
Tue Sep 11 09:17:49 EDT 2012
For tty code we will need completions,
in other words -- waiters. I tried to
make them close to ones used in linux
kernel.
Typicall usage example
- init completion via init_completion()
- task 1 which waits for completion to proceed
wait_completion()
... some work here ...
complete()
- task 2 which inform task 1 that completion can be proceeded
wake_up_completion()
wait_for_completion()
Signed-off-by: Cyrill Gorcunov <gorcunov at openvz.org>
---
include/lock.h | 39 +++++++++++++++++++++++++++++++++++++++
1 files changed, 39 insertions(+), 0 deletions(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-lock-Add-completion-helpers.patch
Type: text/x-patch
Size: 1045 bytes
Desc: not available
Url : http://openvz.org/pipermail/criu/attachments/20120911/5c67c8fa/0002-lock-Add-completion-helpers.bin
More information about the CRIU
mailing list