MyOS Kernel
rpc.h
Go to the documentation of this file.
1 
5 #ifndef KERN_RPC_H
6 #define KERN_RPC_H
7 
8 #include <stddef.h>
9 
10 typedef void* (*rpc_func)(void*);
11 
15 typedef struct rpc_func_info {
16  char name[32];
19 
20 
29 void* kernel_rpc_call(pid_t pid,char* name,void* buf,size_t size);
35 void kernel_rpc_register_func(char* name,rpc_func code);
41 void kernel_rpc_deallocate_buf(void* buf,size_t size);
42 
49 void kernel_rpc_return(void* buf,size_t size);
50 
56 size_t kernel_get_num_rpc_funcs(pid_t pid);
57 
62 #endif
kernel_rpc_register_func
void kernel_rpc_register_func(char *name, rpc_func code)
Definition: rpc.c:109
kernel_rpc_mark_as_init
void kernel_rpc_mark_as_init()
Definition: rpc.c:151
kernel_rpc_call
void * kernel_rpc_call(pid_t pid, char *name, void *buf, size_t size)
Definition: rpc.c:64
kernel_rpc_return
void kernel_rpc_return(void *buf, size_t size)
Definition: rpc.c:129
kernel_rpc_deallocate_buf
void kernel_rpc_deallocate_buf(void *buf, size_t size)
Definition: rpc.c:124
kernel_get_num_rpc_funcs
size_t kernel_get_num_rpc_funcs(pid_t pid)
Definition: rpc.c:147
rpc_func_info::code
rpc_func code
A pointer to the code that implements the funtcion.
Definition: rpc.h:17
rpc_func
void *(* rpc_func)(void *)
Type of an RPC function.
Definition: rpc.h:10
rpc_func_info
Definition: rpc.h:15
rpc_func_info::name
char name[32]
THe name of the function.
Definition: rpc.h:16