X-Git-Url: http://v3vee.org/palacios/gitweb/gitweb.cgi?a=blobdiff_plain;f=palacios%2Finclude%2Fpalacios%2Fvmm.h;h=9071fb70413db727efa8d2c33c290c4337aa6a2e;hb=7a10bbf26095ed08095f38de6c1db4b3a131d6f0;hp=db94298c6f017e951ca49df48766f9bdd07e2004;hpb=ed88df2e8e304ac4b391521d47c192127ad9bc5a;p=palacios.git diff --git a/palacios/include/palacios/vmm.h b/palacios/include/palacios/vmm.h index db94298..9071fb7 100644 --- a/palacios/include/palacios/vmm.h +++ b/palacios/include/palacios/vmm.h @@ -192,7 +192,7 @@ int v3_get_vcore(struct guest_info *); -#define V3_CREATE_THREAD(fn, arg, name) ({ \ +#define V3_CREATE_AND_START_THREAD(fn, arg, name) ({ \ void * thread = NULL; \ extern struct v3_os_hooks * os_hooks; \ if ((os_hooks) && (os_hooks)->start_kernel_thread) { \ @@ -230,6 +230,14 @@ int v3_get_vcore(struct guest_info *); } \ }) +#define V3_CREATE_AND_START_THREAD_ON_CPU(cpu, fn, arg, name) ({ \ + void *thread = V3_CREATE_THREAD_ON_CPU(cpu,fn,arg,name); \ + if (thread) { \ + V3_START_THREAD(thread); \ + } \ + thread; \ + }) + #define V3_MOVE_THREAD_TO_CPU(pcpu, thread) ({ \ int ret = -1; \ extern struct v3_os_hooks * os_hooks; \