|
|
|
|
|
|
|
|
|
|
xen-changelog
[Xen-changelog] [xen-unstable] continue_hypercall_on_cpu() always defers
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1271327518 -3600
# Node ID 6eda8033bb6dfdb72aa8041425b9b55daca69085
# Parent 93ac55cf3e40886c449008094f76dfaf906a505f
continue_hypercall_on_cpu() always defers execution of the continuation
...even when scheduled to run on the current physical cpu. This
ensures that locks get dropped correctly before executing the
continuation code, and also allows the original caller to determine
whether the continuation has/will execute based on c_h_o_c()'s
immediate return code.
Signed-off-by: Keir Fraser <keir.fraser@xxxxxxxxxx>
---
xen/common/domain.c | 3 ---
xen/include/xen/domain.h | 7 ++++++-
2 files changed, 6 insertions(+), 4 deletions(-)
diff -r 93ac55cf3e40 -r 6eda8033bb6d xen/common/domain.c
--- a/xen/common/domain.c Thu Apr 15 09:04:45 2010 +0100
+++ b/xen/common/domain.c Thu Apr 15 11:31:58 2010 +0100
@@ -951,9 +951,6 @@ int continue_hypercall_on_cpu(
if ( (cpu >= NR_CPUS) || !cpu_online(cpu) )
return -EINVAL;
- if ( cpu == smp_processor_id() )
- return func(data);
-
info = this_cpu(continue_info);
if ( info == NULL )
{
diff -r 93ac55cf3e40 -r 6eda8033bb6d xen/include/xen/domain.h
--- a/xen/include/xen/domain.h Thu Apr 15 09:04:45 2010 +0100
+++ b/xen/include/xen/domain.h Thu Apr 15 11:31:58 2010 +0100
@@ -63,7 +63,12 @@ bool_t domctl_lock_acquire(void);
bool_t domctl_lock_acquire(void);
void domctl_lock_release(void);
-/* Continue the current hypercall via func(data) on specified cpu. */
+/*
+ * Continue the current hypercall via func(data) on specified cpu.
+ * If this function returns 0 then the function is guaranteed to run at some
+ * point in the future. If this function returns an error code then the
+ * function has not been and will not be executed.
+ */
int continue_hypercall_on_cpu(
unsigned int cpu, long (*func)(void *data), void *data);
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-changelog] [xen-unstable] continue_hypercall_on_cpu() always defers execution of the continuation,
Xen patchbot-unstable <=
|
|
|
|
|