aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/lguest/hypercalls.c
diff options
context:
space:
mode:
authorGlauber de Oliveira Costa <gcosta@redhat.com>2008-01-07 08:05:36 -0500
committerRusty Russell <rusty@rustcorp.com.au>2008-01-30 06:50:13 -0500
commit5e232f4f428c4266ba5cdae9f23ba19a0913dcf9 (patch)
tree591e21cb88959373e495eac7eb8ee2c2865771ae /drivers/lguest/hypercalls.c
parent4665ac8e28c30c2a015c617c55783c0bf3a49c05 (diff)
lguest: make pending notifications per-vcpu
this patch makes the pending_notify field, used to control pending notifications, per-vcpu, instead of per-guest Signed-off-by: Glauber de Oliveira Costa <gcosta@redhat.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'drivers/lguest/hypercalls.c')
-rw-r--r--drivers/lguest/hypercalls.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/lguest/hypercalls.c b/drivers/lguest/hypercalls.c
index ab70bbebdf25..be8f04685767 100644
--- a/drivers/lguest/hypercalls.c
+++ b/drivers/lguest/hypercalls.c
@@ -91,7 +91,7 @@ static void do_hcall(struct lg_cpu *cpu, struct hcall_args *args)
91 cpu->halted = 1; 91 cpu->halted = 1;
92 break; 92 break;
93 case LHCALL_NOTIFY: 93 case LHCALL_NOTIFY:
94 lg->pending_notify = args->arg1; 94 cpu->pending_notify = args->arg1;
95 break; 95 break;
96 default: 96 default:
97 /* It should be an architecture-specific hypercall. */ 97 /* It should be an architecture-specific hypercall. */
@@ -154,7 +154,7 @@ static void do_async_hcalls(struct lg_cpu *cpu)
154 154
155 /* Stop doing hypercalls if they want to notify the Launcher: 155 /* Stop doing hypercalls if they want to notify the Launcher:
156 * it needs to service this first. */ 156 * it needs to service this first. */
157 if (lg->pending_notify) 157 if (cpu->pending_notify)
158 break; 158 break;
159 } 159 }
160} 160}
@@ -219,7 +219,7 @@ void do_hypercalls(struct lg_cpu *cpu)
219 /* If we stopped reading the hypercall ring because the Guest did a 219 /* If we stopped reading the hypercall ring because the Guest did a
220 * NOTIFY to the Launcher, we want to return now. Otherwise we do 220 * NOTIFY to the Launcher, we want to return now. Otherwise we do
221 * the hypercall. */ 221 * the hypercall. */
222 if (!cpu->lg->pending_notify) { 222 if (!cpu->pending_notify) {
223 do_hcall(cpu, cpu->hcall); 223 do_hcall(cpu, cpu->hcall);
224 /* Tricky point: we reset the hcall pointer to mark the 224 /* Tricky point: we reset the hcall pointer to mark the
225 * hypercall as "done". We use the hcall pointer rather than 225 * hypercall as "done". We use the hcall pointer rather than