2 * This file is part of the Palacios Virtual Machine Monitor developed
3 * by the V3VEE Project with funding from the United States National
4 * Science Foundation and the Department of Energy.
6 * The V3VEE Project is a joint project between Northwestern University
7 * and the University of New Mexico. You can find out more at
10 * Copyright (c) 2013, Oscar Mondragon <omondrag@cs.unm.edu>
11 * Copyright (c) 2013, Patrick G. Bridges <bridges@cs.unm.edu>
12 * Copyright (c) 2013, The V3VEE Project <http://www.v3vee.org>
13 * All rights reserved.
15 * Author: Oscar Mondragon <omondrag@cs.unm.edu>
16 * Patrick G. Bridges <bridges@cs.unm.edu>
18 * This is free software. You are permitted to use,
19 * redistribute, and modify it as specified in the file "V3VEE_LICENSE".
22 #ifndef __VMM_SCHEDULER_H__
23 #define __VMM_SCHEDULER_H__
25 struct vm_scheduler_impl {
29 int (*vm_init)(struct v3_vm_info *vm);
30 int (*vm_deinit)(struct v3_vm_info *vm);
31 int (*core_init)(struct guest_info *vm);
32 int (*core_deinit)(struct guest_info *vm);
33 void (*schedule)(struct guest_info *vm);
34 void (*yield)(struct guest_info *vm, int usec);
35 int (*admit)(struct v3_vm_info *vm);
36 int (*remap)(struct v3_vm_info *vm);
37 int (*dvfs)(struct v3_vm_info *vm);
40 void v3_schedule(struct guest_info *core);
41 void v3_yield(struct guest_info *core, int usec);
43 int v3_scheduler_register_vm(struct v3_vm_info *vm);
44 int v3_scheduler_register_core(struct guest_info *vm); /* ? */
45 int v3_scheduler_admit_vm(struct v3_vm_info *vm);
47 void v3_scheduler_remap_notify(struct v3_vm_info *vm);
48 void v3_scheduler_dvfs_notify(struct v3_vm_info *vm);
50 int V3_init_scheduling();
51 int v3_register_scheduler(struct vm_scheduler_impl *vm);
52 struct vm_scheduler_impl *v3_scheduler_lookup(char *name);
53 int V3_enable_scheduler();
55 #endif /* __VMM_SCHEDULER_H__ */