diff options
author | Jes Sorensen <jes@sgi.com> | 2007-10-21 21:03:31 -0400 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2007-10-23 01:49:52 -0400 |
commit | b410e7b1499c49513cab18275db8a8ab549d9e09 (patch) | |
tree | 8a71fa34660f5ccc9d71677137c5ae211a38bbf2 /drivers/lguest/lg.h | |
parent | cc6d4fbcef328acdc9fa7023e69f39f753f72fe1 (diff) |
Make hypercalls arch-independent.
Clean up the hypercall code to make the code in hypercalls.c
architecture independent. First process the common hypercalls and
then call lguest_arch_do_hcall() if the call hasn't been handled.
Rename struct hcall_ring to hcall_args.
This patch requires the previous patch which reorganize the layout of
struct lguest_regs on i386 so they match the layout of struct
hcall_args.
Signed-off-by: Jes Sorensen <jes@sgi.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'drivers/lguest/lg.h')
-rw-r--r-- | drivers/lguest/lg.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/lguest/lg.h b/drivers/lguest/lg.h index 662994b776cc..00c869bd9f79 100644 --- a/drivers/lguest/lg.h +++ b/drivers/lguest/lg.h | |||
@@ -107,7 +107,7 @@ struct lguest | |||
107 | u8 ss1; | 107 | u8 ss1; |
108 | 108 | ||
109 | /* If a hypercall was asked for, this points to the arguments. */ | 109 | /* If a hypercall was asked for, this points to the arguments. */ |
110 | struct lguest_regs *hcall; | 110 | struct hcall_args *hcall; |
111 | 111 | ||
112 | /* Do we need to stop what we're doing and return to userspace? */ | 112 | /* Do we need to stop what we're doing and return to userspace? */ |
113 | int break_out; | 113 | int break_out; |
@@ -197,6 +197,8 @@ void lguest_arch_host_init(void); | |||
197 | void lguest_arch_host_fini(void); | 197 | void lguest_arch_host_fini(void); |
198 | void lguest_arch_run_guest(struct lguest *lg); | 198 | void lguest_arch_run_guest(struct lguest *lg); |
199 | void lguest_arch_handle_trap(struct lguest *lg); | 199 | void lguest_arch_handle_trap(struct lguest *lg); |
200 | int lguest_arch_init_hypercalls(struct lguest *lg); | ||
201 | int lguest_arch_do_hcall(struct lguest *lg, struct hcall_args *args); | ||
200 | 202 | ||
201 | /* <arch>/switcher.S: */ | 203 | /* <arch>/switcher.S: */ |
202 | extern char start_switcher_text[], end_switcher_text[], switch_to_guest[]; | 204 | extern char start_switcher_text[], end_switcher_text[], switch_to_guest[]; |