summaryrefslogtreecommitdiffstats
path: root/arch/um/include/shared/kern.h
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2008-08-17 13:48:37 -0400
committerH. Peter Anvin <hpa@zytor.com>2008-10-22 22:55:19 -0700
commit8569c9140bd41089f9b6be8837ca421102714a90 (patch)
treecd289b322b215fe2ca2530aa320febfd99388d7f /arch/um/include/shared/kern.h
parent2515ddc6db8eb49a79f0fe5e67ff09ac7c81eab4 (diff)
x86, um: take arch/um/include/* out of the way
We can't just plop asm/* into it - userland helpers are built with it in search path and seeing asm/* show up there suddenly would be a bad idea. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'arch/um/include/shared/kern.h')
-rw-r--r--arch/um/include/shared/kern.h40
1 files changed, 40 insertions, 0 deletions
diff --git a/arch/um/include/shared/kern.h b/arch/um/include/shared/kern.h
new file mode 100644
index 00000000000..4ce3fc650e5
--- /dev/null
+++ b/arch/um/include/shared/kern.h
@@ -0,0 +1,40 @@
+/*
+ * Copyright (C) 2000 Jeff Dike (jdike@karaya.com)
+ * Licensed under the GPL
+ */
+
+#ifndef __KERN_H__
+#define __KERN_H__
+
+/* These are all user-mode things which are convenient to call directly
+ * from kernel code and for which writing a wrapper is too much of a pain.
+ * The regular include files can't be included because this file is included
+ * only into kernel code, and user-space includes conflict with kernel
+ * includes.
+ */
+
+extern int errno;
+
+extern int clone(int (*proc)(void *), void *sp, int flags, void *data);
+extern int sleep(int);
+extern int printf(const char *fmt, ...);
+extern char *strerror(int errnum);
+extern char *ptsname(int __fd);
+extern int munmap(void *, int);
+extern void *sbrk(int increment);
+extern void *malloc(int size);
+extern void perror(char *err);
+extern int kill(int pid, int sig);
+extern int getuid(void);
+extern int getgid(void);
+extern int pause(void);
+extern int write(int, const void *, int);
+extern void exit(int);
+extern int close(int);
+extern int read(unsigned int, char *, int);
+extern int pipe(int *);
+extern int sched_yield(void);
+extern int ptrace(int op, int pid, long addr, long data);
+
+#endif
+