diff options
Diffstat (limited to 'src/include/linux/kernel.h')
-rw-r--r-- | src/include/linux/kernel.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/include/linux/kernel.h b/src/include/linux/kernel.h new file mode 100644 index 0000000..2a0f916 --- /dev/null +++ b/src/include/linux/kernel.h | |||
@@ -0,0 +1,22 @@ | |||
1 | /* | ||
2 | * 'kernel.h' contains some often-used function prototypes etc | ||
3 | */ | ||
4 | void verify_area(void * addr,int count); | ||
5 | void panic(const char * str); | ||
6 | int printf(const char * fmt, ...); | ||
7 | int printk(const char * fmt, ...); | ||
8 | int tty_write(unsigned ch,char * buf,int count); | ||
9 | void * malloc(unsigned int size); | ||
10 | void free_s(void * obj, int size); | ||
11 | |||
12 | #define free(x) free_s((x), 0) | ||
13 | |||
14 | /* | ||
15 | * This is defined as a macro, but at some point this might become a | ||
16 | * real subroutine that sets a flag if it returns true (to do | ||
17 | * BSD-style accounting where the process is flagged if it uses root | ||
18 | * privs). The implication of this is that you should do normal | ||
19 | * permissions checks first, and check suser() last. | ||
20 | */ | ||
21 | #define suser() (current->euid == 0) | ||
22 | |||