1
2
3
4
5
6#ifndef __USER_H__
7#define __USER_H__
8
9#include "kern_constants.h"
10
11
12
13
14
15
16
17#define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0]))
18
19
20#ifdef __KERNEL__
21#include <linux/types.h>
22#else
23#include <stddef.h>
24#endif
25
26extern void panic(const char *fmt, ...)
27 __attribute__ ((format (printf, 1, 2)));
28
29#ifdef UML_CONFIG_PRINTK
30extern int printk(const char *fmt, ...)
31 __attribute__ ((format (printf, 1, 2)));
32#else
33static inline int printk(const char *fmt, ...)
34{
35 return 0;
36}
37#endif
38
39extern void schedule(void);
40extern int in_aton(char *str);
41extern int open_gdb_chan(void);
42extern size_t strlcpy(char *, const char *, size_t);
43extern size_t strlcat(char *, const char *, size_t);
44
45#endif
46