aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2006-10-02 05:18:44 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2006-10-02 10:57:23 -0400
commit135ab6ec8fdad6f61aabe53f456821baf4a4aa0e (patch)
tree22a46321949e6621e95f6c21a3d34e3516d07cc8 /lib
parent821278a75d270048e291fcbec9304439a176ba88 (diff)
[PATCH] remove remaining errno and __KERNEL_SYSCALLS__ references
The last in-kernel user of errno is gone, so we should remove the definition and everything referring to it. This also removes the now-unused lib/execve.c file that was introduced earlier. Also remove every trace of __KERNEL_SYSCALLS__ that still remained in the kernel. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Cc: Andi Kleen <ak@muc.de> Cc: Paul Mackerras <paulus@samba.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Richard Henderson <rth@twiddle.net> Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Cc: Russell King <rmk@arm.linux.org.uk> Cc: Ian Molton <spyro@f2s.com> Cc: Mikael Starvik <starvik@axis.com> Cc: David Howells <dhowells@redhat.com> Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Cc: Hirokazu Takata <takata.hirokazu@renesas.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Kyle McMartin <kyle@mcmartin.ca> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Paul Mundt <lethal@linux-sh.org> Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp> Cc: Richard Curnow <rc@rc0.org.uk> Cc: William Lee Irwin III <wli@holomorphy.com> Cc: "David S. Miller" <davem@davemloft.net> Cc: Jeff Dike <jdike@addtoit.com> Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp> Cc: Chris Zankel <chris@zankel.net> Cc: "Luck, Tony" <tony.luck@intel.com> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Roman Zippel <zippel@linux-m68k.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'lib')
-rw-r--r--lib/Makefile4
-rw-r--r--lib/errno.c7
-rw-r--r--lib/execve.c23
3 files changed, 1 insertions, 33 deletions
diff --git a/lib/Makefile b/lib/Makefile
index 4d752be0edc0..b0361756e22e 100644
--- a/lib/Makefile
+++ b/lib/Makefile
@@ -2,7 +2,7 @@
2# Makefile for some libs needed in the kernel. 2# Makefile for some libs needed in the kernel.
3# 3#
4 4
5lib-y := errno.o ctype.o string.o vsprintf.o cmdline.o \ 5lib-y := ctype.o string.o vsprintf.o cmdline.o \
6 bust_spinlocks.o rbtree.o radix-tree.o dump_stack.o \ 6 bust_spinlocks.o rbtree.o radix-tree.o dump_stack.o \
7 idr.o div64.o int_sqrt.o bitmap.o extable.o prio_tree.o \ 7 idr.o div64.o int_sqrt.o bitmap.o extable.o prio_tree.o \
8 sha1.o 8 sha1.o
@@ -35,8 +35,6 @@ ifneq ($(CONFIG_HAVE_DEC_LOCK),y)
35 lib-y += dec_and_lock.o 35 lib-y += dec_and_lock.o
36endif 36endif
37 37
38lib-y += execve.o
39
40obj-$(CONFIG_CRC_CCITT) += crc-ccitt.o 38obj-$(CONFIG_CRC_CCITT) += crc-ccitt.o
41obj-$(CONFIG_CRC16) += crc16.o 39obj-$(CONFIG_CRC16) += crc16.o
42obj-$(CONFIG_CRC32) += crc32.o 40obj-$(CONFIG_CRC32) += crc32.o
diff --git a/lib/errno.c b/lib/errno.c
deleted file mode 100644
index 41cb9d76c052..000000000000
--- a/lib/errno.c
+++ /dev/null
@@ -1,7 +0,0 @@
1/*
2 * linux/lib/errno.c
3 *
4 * Copyright (C) 1991, 1992 Linus Torvalds
5 */
6
7int errno;
diff --git a/lib/execve.c b/lib/execve.c
deleted file mode 100644
index 2667ebc15045..000000000000
--- a/lib/execve.c
+++ /dev/null
@@ -1,23 +0,0 @@
1#include <asm/bug.h>
2#include <asm/uaccess.h>
3
4#define __KERNEL_SYSCALLS__
5static int errno __attribute__((unused));
6#include <asm/unistd.h>
7
8#ifdef _syscall3
9int kernel_execve (const char *filename, char *const argv[], char *const envp[])
10 __attribute__((__weak__));
11int kernel_execve (const char *filename, char *const argv[], char *const envp[])
12{
13 mm_segment_t fs = get_fs();
14 int ret;
15
16 WARN_ON(segment_eq(fs, USER_DS));
17 ret = execve(filename, (char **)argv, (char **)envp);
18 if (ret)
19 ret = -errno;
20
21 return ret;
22}
23#endif