From 385d9bf1b81bc35f06cdf49f57bf65545339cbbb Mon Sep 17 00:00:00 2001 From: "Brent W. Baccala" Date: Mon, 14 Nov 2016 00:44:17 +0100 Subject: libpager: fix returning error on data_unlock MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The _pager_lock_object call needs to be asynchronous because libpager is single threaded, at least in the sense that individual memory objects only process one request at a time.  In this case, we're processing a data_unlock request, and would have to handle a lock_completed message before lock_object would return (synchronously). * libpager/data-unlock.c (_pager_S_memory_object_data_unlock): Pass 0 to sync parameter of _pager_lock_object() call. --- libpager/data-unlock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libpager/data-unlock.c b/libpager/data-unlock.c index 8c9680c4..077e673f 100644 --- a/libpager/data-unlock.c +++ b/libpager/data-unlock.c @@ -73,7 +73,7 @@ _pager_S_memory_object_data_unlock (struct pager *p, /* Flush the page, and set a bit so that m_o_data_request knows to issue an error. */ _pager_lock_object (p, offset, length, MEMORY_OBJECT_RETURN_NONE, 1, - VM_PROT_WRITE, 1); + VM_PROT_WRITE, 0); _pager_mark_next_request_error (p, offset, length, err); } out: -- cgit v1.2.3