30 #ifndef _LINUX_VIRGOCLOUDEXECMEMPOOLSVC_H
31 #define _LINUX_VIRGOCLOUDEXECMEMPOOLSVC_H
33 #include <linux/virgo_mempool.h>
34 #include <linux/socket.h>
37 int virgo_cloudexec_mempool_service(
void* args)
40 try_module_get(virgo_mempool_class.m_virgo_owner);
43 printk(KERN_INFO
"virgo_cloudexec_mempool_service(): virgo_mempool_ops.virgo_create() \n");
44 struct socket* clsock = virgo_mempool_ops.virgo_mempool_create();
52 struct task_struct *task;
55 printk(KERN_INFO
"virgo_cloudexec_mempool_service(): virgo mempool client thread per request \n");
56 task=kthread_create(virgo_mempool_client_thread, (
void*)args,
"virgo memorypool client thread per virgo_clone request");
57 woken_up=wake_up_process(task);
72 int virgo_mempool_client_thread(
void* args)
75 struct socket* clientsock=(
struct socket*)args;
76 printk(KERN_INFO
"virgo_mempool_client_thread(): virgo_mempool_ops.virgo_mempool_recvfrom()\n");
77 char *virgo_mempool_ret=(
char*)virgo_mempool_ops.virgo_mempool_recvfrom(clientsock);
78 printk(KERN_INFO
"virgo_mempool_client_thread(): virgo_mempool_ops.virgo_mempool_sendto()\n");
79 virgo_mempool_ops.virgo_mempool_sendto(clientsock, virgo_mempool_ret);