From: Vincent Hanquez <vincent.hanquez@eu.citrix.com>
To: Xen Devel <xen-devel@lists.xensource.com>
Cc: Vincent Hanquez <vincent.hanquez@eu.citrix.com>
Subject: [PATCH 5/5] always drop the caml lock during any xl operations.
Date: Tue, 10 Aug 2010 16:12:44 +0100 [thread overview]
Message-ID: <1281453164-29013-6-git-send-email-vincent.hanquez@eu.citrix.com> (raw)
In-Reply-To: <1281453164-29013-1-git-send-email-vincent.hanquez@eu.citrix.com>
Signed-off-by: Vincent Hanquez <vincent.hanquez@eu.citrix.com>
---
tools/ocaml/libs/xl/xl_stubs.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/tools/ocaml/libs/xl/xl_stubs.c b/tools/ocaml/libs/xl/xl_stubs.c
index 8134e8e..2f8401d 100644
--- a/tools/ocaml/libs/xl/xl_stubs.c
+++ b/tools/ocaml/libs/xl/xl_stubs.c
@@ -58,12 +58,14 @@ void log_destroy(struct xentoollog_logger *logger)
lg.logger.vmessage = log_vmessage; \
lg.logger.destroy = log_destroy; \
lg.logger.progress = NULL; \
+ caml_enter_blocking_section(); \
ret = libxl_ctx_init(&ctx, LIBXL_VERSION, (struct xentoollog_logger *) &lg); \
if (ret != 0) \
failwith_xl("cannot init context", &lg);
#define FREE_CTX() \
gc_free(&gc); \
+ caml_leave_blocking_section(); \
libxl_ctx_free(&ctx)
static void * gc_calloc(caml_gc *gc, size_t nmemb, size_t size)
--
1.7.1
next prev parent reply other threads:[~2010-08-10 15:12 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-08-10 15:12 [PATCH 0/5] xl ocaml: drop lock in the bindings Vincent Hanquez
2010-08-10 15:12 ` [PATCH 1/5] Put a valid version number in the META files Vincent Hanquez
2010-08-10 15:12 ` [PATCH 2/5] Wrap init context procedure into a macro. Introduce a gc structure Vincent Hanquez
2010-08-10 15:12 ` [PATCH 3/5] use new functions to get elements out of ocaml values Vincent Hanquez
2010-08-10 15:12 ` [PATCH 4/5] use new gc functions to deep copy structure and only free once the gc Vincent Hanquez
2010-08-10 15:12 ` Vincent Hanquez [this message]
-- strict thread matches above, loose matches on Subject: below --
2010-08-10 11:46 [PATCH 0/5] xl ocaml: drop lock in the bindings Vincent Hanquez
2010-08-10 11:46 ` [PATCH 5/5] always drop the caml lock during any xl operations Vincent Hanquez
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1281453164-29013-6-git-send-email-vincent.hanquez@eu.citrix.com \
--to=vincent.hanquez@eu.citrix.com \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).