UML - Throw out CONFIG_MODE_TT
Subsystems (2)
PATCH 1/14 UML - Throw out CONFIG_MODE_TT
Start getting rid of tt mode support.
This patch throws out CONFIG_MODE_TT and all config options, code, and files which depend on it.
CONFIG_MODE_SKAS is gone and everything that depends on it is included unconditionally.
The few changed lines are in re-written Kconfig help, lines which needed something skas-related removed from them, and a few more which weren't strictly deletions.
--
arch/um/Kconfig | 64 ---- arch/um/Kconfig.char | 2 arch/um/Kconfig.debug | 23 - arch/um/Makefile | 26 - arch/um/Makefile-i386 | 6 arch/um/defconfig | 2 arch/um/drivers/mconsole_kern.c | 15 - arch/um/include/as-layout.h | 1 arch/um/include/choose-mode.h | 18 - arch/um/include/common-offsets.h | 3 arch/um/include/irq_user.h | 4 arch/um/include/kern_util.h | 6 arch/um/include/mode.h | 19 - arch/um/include/mode_kern.h | 6 arch/um/include/os.h | 26 - arch/um/include/sysdep-i386/ptrace.h | 23 - arch/um/include/sysdep-i386/sigcontext.h | 4 arch/um/include/sysdep-i386/thread.h | 3 arch/um/include/sysdep-x86_64/ptrace.h | 21 - arch/um/include/sysdep-x86_64/thread.h | 4 arch/um/include/tt/debug.h | 18 - arch/um/include/tt/mmu-tt.h | 12 arch/um/include/tt/mode-tt.h | 23 - arch/um/include/tt/mode_kern_tt.h | 40 -- arch/um/include/tt/tt.h | 37 -- arch/um/include/tt/uaccess-tt.h | 46 --- arch/um/include/um_mmu.h | 23 - arch/um/include/um_uaccess.h | 8 arch/um/kernel/Makefile | 5 arch/um/kernel/dyn.lds.S | 2 arch/um/kernel/exec.c | 1 arch/um/kernel/init_task.c | 7 arch/um/kernel/irq.c | 24 - arch/um/kernel/ksyms.c | 10 arch/um/kernel/process.c | 7 arch/um/kernel/reboot.c | 19 - arch/um/kernel/smp.c | 5 arch/um/kernel/trap.c | 2 arch/um/kernel/tt/Makefile | 14 arch/um/kernel/tt/exec_kern.c | 84 ----- arch/um/kernel/tt/exec_user.c | 56 --- arch/um/kernel/tt/gdb.c | 280 ------------------ arch/um/kernel/tt/gdb_kern.c | 40 -- arch/um/kernel/tt/include/mode-tt.h | 34 -- arch/um/kernel/tt/ksyms.c | 29 - arch/um/kernel/tt/mem.c | 34 -- arch/um/kernel/tt/mem_user.c | 49 --- arch/um/kernel/tt/process_kern.c | 461 ------------------------------- arch/um/kernel/tt/ptproxy/Makefile | 10 arch/um/kernel/tt/ptproxy/proxy.c | 377 ------------------------- arch/um/kernel/tt/ptproxy/ptproxy.h | 61 ---- arch/um/kernel/tt/ptproxy/ptrace.c | 237 --------------- arch/um/kernel/tt/ptproxy/sysdep.c | 70 ---- arch/um/kernel/tt/ptproxy/sysdep.h | 25 - arch/um/kernel/tt/ptproxy/wait.c | 85 ----- arch/um/kernel/tt/ptproxy/wait.h | 15 - arch/um/kernel/tt/syscall_kern.c | 46 --- arch/um/kernel/tt/syscall_user.c | 60 ---- arch/um/kernel/tt/tlb.c | 120 -------- arch/um/kernel/tt/tracer.c | 461 ------------------------------- arch/um/kernel/tt/trap_user.c | 70 ---- arch/um/kernel/tt/uaccess.c | 73 ---- arch/um/kernel/tt/uaccess_user.c | 105 ------- arch/um/kernel/um_arch.c | 113 ------- arch/um/kernel/uml.lds.S | 7 arch/um/os-Linux/Makefile | 7 arch/um/os-Linux/main.c | 32 -- arch/um/os-Linux/process.c | 31 -- arch/um/os-Linux/start_up.c | 10 arch/um/os-Linux/sys-i386/Makefile | 2 arch/um/os-Linux/sys-x86_64/Makefile | 2 arch/um/os-Linux/time.c | 19 - arch/um/os-Linux/tls.c | 36 -- arch/um/scripts/Makefile.rules | 2 arch/um/sys-i386/Makefile | 10 arch/um/sys-i386/ldt.c | 67 ---- arch/um/sys-i386/ptrace.c | 120 -------- arch/um/sys-i386/ptrace_user.c | 86 ----- arch/um/sys-i386/signal.c | 58 --- arch/um/sys-i386/tls.c | 16 - arch/um/sys-i386/unmap.c | 25 - arch/um/sys-x86_64/Makefile | 9 arch/um/sys-x86_64/signal.c | 50 --- arch/um/sys-x86_64/syscalls.c | 31 -- arch/um/sys-x86_64/unmap.c | 25 - include/asm-um/mmu_context.h | 6 include/asm-um/processor-generic.h | 14 87 files changed, 35 insertions(+), 4204 deletions(-)
arch/um/Kconfig +10 -54
@@ -62,55 +62,16 @@ config IRQ_RELEASE_METHOD menu "UML-specific options" -config MODE_TT - bool "Tracing thread support (DEPRECATED)" - default n - depends on BROKEN - help - This option controls whether tracing thread support is compiled - into UML. This option is largely obsolete, given that skas0 provides - skas security and performance without needing to patch the host. - It is safe to say 'N' here; saying 'Y' may cause additional problems - with the resulting binary even if you run UML in SKAS mode, and running - in TT mode is strongly *NOT RECOMMENDED*. - config STATIC_LINK bool "Force a static link" default n - depends on !MODE_TT help - If CONFIG_MODE_TT is disabled, then this option gives you the ability - to force a static link of UML. Normally, if only skas mode is built - in to UML, it will be linked as a shared binary. This is inconvenient - for use in a chroot jail. So, if you intend to run UML inside a - chroot, and you disable CONFIG_MODE_TT, you probably want to say Y - here. + This option gives you the ability to force a static link of UML. + Normally, UML is linked as a shared binary. This is inconvenient for + use in a chroot jail. So, if you intend to run UML inside a chroot, + you probably want to say Y here. Additionally, this option enables using higher memory spaces (up to - 2.75G) for UML - disabling CONFIG_MODE_TT and enabling this option leads - to best results for this. - -config KERNEL_HALF_GIGS - int "Kernel address space size (in .5G units)" - default "1" - depends on MODE_TT - help - This determines the amount of address space that UML will allocate for - its own, measured in half Gigabyte units. The default is 1. - Change this only if you need to boot UML with an unusually large amount - of physical memory. - -config MODE_SKAS - bool "Separate Kernel Address Space support" if MODE_TT - default y - help - This option controls whether skas (separate kernel address space) - support is compiled in. - Unless you have specific needs to use TT mode (which applies almost only - to developers), you should say Y here. - SKAS mode will make use of the SKAS3 patch if it is applied on the host - (and your UML will run in SKAS3 mode), but if no SKAS patch is applied - on the host it will run in SKAS0 mode, which is anyway faster than TT - mode. + 2.75G) for UML. source "arch/um/Kconfig.arch" source "mm/Kconfig"
@@ -118,7 +79,7 @@ source "mm/Kconfig" config LD_SCRIPT_STATIC bool default y - depends on MODE_TT || STATIC_LINK + depends on STATIC_LINK config LD_SCRIPT_DYN bool
@@ -220,7 +181,7 @@ config SMP bool "Symmetric multi-processing support (EXPERIMENTAL)" default n #SMP_BROKEN is for x86_64. - depends on MODE_TT && EXPERIMENTAL && (!SMP_BROKEN || (BROKEN && SMP_BROKEN)) + depends on EXPERIMENTAL && (!SMP_BROKEN || (BROKEN && SMP_BROKEN)) help This option enables UML SMP support. It is NOT related to having a real SMP box. Not directly, at least.
@@ -258,11 +219,6 @@ config NEST_LEVEL inside another UML, set CONFIG_NEST_LEVEL to one more than the host UML. - Note that if the hosting UML has its CONFIG_KERNEL_HALF_GIGS set to - greater than one, then the guest UML should have its CONFIG_NEST_LEVEL - set to the host's CONFIG_NEST_LEVEL + CONFIG_KERNEL_HALF_GIGS. - Only change this if you are running nested UMLs. - config HIGHMEM bool "Highmem support (EXPERIMENTAL)" depends on !64BIT && EXPERIMENTAL
@@ -271,9 +227,9 @@ config HIGHMEM This was used to allow UML to run with big amounts of memory. Currently it is unstable, so if unsure say N. - To use big amounts of memory, it is recommended to disable TT mode (i.e. - CONFIG_MODE_TT) and enable static linking (i.e. CONFIG_STATIC_LINK) - - this should allow the guest to use up to 2.75G of memory. + To use big amounts of memory, it is recommended enable static + linking (i.e. CONFIG_STATIC_LINK) - this should allow the + guest to use up to 2.75G of memory. config KERNEL_STACK_ORDER int "Kernel stack size order"
arch/um/Makefile +6 -20
@@ -31,18 +31,9 @@ SYMLINK_HEADERS := $(foreach header,$(SY ARCH_SYMLINKS = include/asm-um/arch $(ARCH_DIR)/include/sysdep $(ARCH_DIR)/os \ $(SYMLINK_HEADERS) $(ARCH_DIR)/include/uml-config.h -um-modes-$(CONFIG_MODE_TT) += tt -um-modes-$(CONFIG_MODE_SKAS) += skas +MODE_INCLUDE += -I$(srctree)/$(ARCH_DIR)/include/skas -MODE_INCLUDE += $(foreach mode,$(um-modes-y),\ - -I$(srctree)/$(ARCH_DIR)/include/$(mode)) - -MAKEFILES-INCL += $(foreach mode,$(um-modes-y),\ - $(srctree)/$(ARCH_DIR)/Makefile-$(mode)) - -ifneq ($(MAKEFILES-INCL),) - include $(MAKEFILES-INCL) -endif +include $(srctree)/$(ARCH_DIR)/Makefile-skas ARCH_INCLUDE := -I$(ARCH_DIR)/include ifneq ($(KBUILD_SRC),)
@@ -59,7 +50,7 @@ SYS_DIR := $(ARCH_DIR)/include/sysdep-$ # These apply to USER_CFLAGS to. CFLAGS += $(CFLAGS-y) -D__arch_um__ -DSUBARCH=\"$(SUBARCH)\" \ - $(ARCH_INCLUDE) $(MODE_INCLUDE) -Dvmap=kernel_vmap \ + $(ARCH_INCLUDE) $(MODE_INCLUDE) -Dvmap=kernel_vmap \ -Din6addr_loopback=kernel_in6addr_loopback \ -Din6addr_any=kernel_in6addr_any
@@ -89,9 +80,8 @@ CFLAGS += $(call cc-option,-fno-unit-at- # included; the values here are meaningless CONFIG_NEST_LEVEL ?= 0 -CONFIG_KERNEL_HALF_GIGS ?= 0 -SIZE = (($(CONFIG_NEST_LEVEL) + $(CONFIG_KERNEL_HALF_GIGS)) * 0x20000000) +SIZE = ($(CONFIG_NEST_LEVEL) * 0x20000000) PHONY += linux
@@ -124,7 +114,6 @@ CFLAGS_NO_HARDENING := $(call cc-option, $(call cc-option, -fno-stack-protector,) \ $(call cc-option, -fno-stack-protector-all,) -CPP_MODE-$(CONFIG_MODE_TT) := -DMODE_TT CONFIG_KERNEL_STACK_ORDER ?= 2 STACK_SIZE := $(shell echo $$[ 4096 * (1 << $(CONFIG_KERNEL_STACK_ORDER)) ] )
@@ -132,11 +121,8 @@ ifndef START START = $(shell echo $$[ $(TOP_ADDR) - $(SIZE) ] ) endif -CPPFLAGS_vmlinux.lds = -U$(SUBARCH) \ - -DSTART=$(START) -DELF_ARCH=$(ELF_ARCH) \ - -DELF_FORMAT="$(ELF_FORMAT)" $(CPP_MODE-y) \ - -DKERNEL_STACK_SIZE=$(STACK_SIZE) \ - -DUNMAP_PATH=arch/um/sys-$(SUBARCH)/unmap.o +CPPFLAGS_vmlinux.lds = -U$(SUBARCH) -DSTART=$(START) -DELF_ARCH=$(ELF_ARCH) \ + -DELF_FORMAT="$(ELF_FORMAT)" -DKERNEL_STACK_SIZE=$(STACK_SIZE) #The wrappers will select whether using "malloc" or the kernel allocator. LINK_WRAPS = -Wl,--wrap,malloc -Wl,--wrap,free -Wl,--wrap,calloc
arch/um/kernel/Makefile +1 -4
@@ -9,15 +9,12 @@ clean-files := obj-y = config.o exec.o exitcode.o init_task.o irq.o ksyms.o mem.o \ physmem.o process.o ptrace.o reboot.o sigio.o \ signal.o smp.o syscall.o sysrq.o time.o tlb.o trap.o uaccess.o \ - um_arch.o umid.o + um_arch.o umid.o skas/ obj-$(CONFIG_BLK_DEV_INITRD) += initrd.o obj-$(CONFIG_GPROF) += gprof_syms.o obj-$(CONFIG_GCOV) += gmon_syms.o -obj-$(CONFIG_MODE_TT) += tt/ -obj-$(CONFIG_MODE_SKAS) += skas/ - USER_OBJS := config.o include arch/um/scripts/Makefile.rules
arch/um/os-Linux/Makefile +1 -6
@@ -5,12 +5,7 @@ obj-y = aio.o elf_aux.o execvp.o file.o helper.o irq.o main.o mem.o process.o \ registers.o sigio.o signal.o start_up.o time.o trap.o tty.o uaccess.o \ - umid.o tls.o user_syms.o util.o drivers/ sys-$(SUBARCH)/ - -obj-$(CONFIG_MODE_SKAS) += skas/ - -obj-$(CONFIG_MODE_TT) += tt.o -user-objs-$(CONFIG_MODE_TT) += tt.o + umid.o tls.o user_syms.o util.o drivers/ sys-$(SUBARCH)/ skas/ obj-$(CONFIG_TTY_LOG) += tty_log.o user-objs-$(CONFIG_TTY_LOG) += tty_log.o
arch/um/sys-i386/Makefile +2 -8
@@ -1,8 +1,6 @@ obj-y = bug.o bugs.o checksum.o delay.o fault.o ksyms.o ldt.o ptrace.o \ - ptrace_user.o setjmp.o signal.o sigcontext.o syscalls.o sysrq.o \ - sys_call_table.o tls.o - -obj-$(CONFIG_MODE_SKAS) += stub.o stub_segv.o + ptrace_user.o setjmp.o signal.o sigcontext.o stub.o stub_segv.o \ + syscalls.o sysrq.o sys_call_table.o tls.o subarch-obj-y = lib/bitops.o lib/semaphore.o lib/string.o subarch-obj-$(CONFIG_HIGHMEM) += mm/highmem.o
@@ -13,11 +11,7 @@ USER_OBJS := bugs.o ptrace_user.o sigcon USER_OBJS += user-offsets.s extra-y += user-offsets.s -extra-$(CONFIG_MODE_TT) += unmap.o - UNPROFILE_OBJS := stub_segv.o CFLAGS_stub_segv.o := $(CFLAGS_NO_HARDENING) include arch/um/scripts/Makefile.rules - -$(obj)/unmap.%: _c_flags = $(call unprofile,$(CFLAGS))
arch/um/sys-x86_64/Makefile +2 -7
@@ -5,10 +5,9 @@ # obj-y = bug.o bugs.o delay.o fault.o ldt.o mem.o ptrace.o ptrace_user.o \ - setjmp.o sigcontext.o signal.o syscalls.o syscall_table.o sysrq.o \ - ksyms.o tls.o + setjmp.o sigcontext.o signal.o stub.o stub_segv.o syscalls.o \ + syscall_table.o sysrq.o ksyms.o tls.o -obj-$(CONFIG_MODE_SKAS) += stub.o stub_segv.o obj-$(CONFIG_MODULES) += um_module.o subarch-obj-y = lib/bitops.o lib/csum-partial.o lib/memcpy.o lib/thunk.o
@@ -21,11 +20,7 @@ USER_OBJS := ptrace_user.o sigcontext.o USER_OBJS += user-offsets.s extra-y += user-offsets.s -extra-$(CONFIG_MODE_TT) += unmap.o - UNPROFILE_OBJS := stub_segv.o CFLAGS_stub_segv.o := $(CFLAGS_NO_HARDENING) include arch/um/scripts/Makefile.rules - -$(obj)/unmap.%: _c_flags = $(call unprofile,$(CFLAGS))
arch/um/kernel/tt/Makefile deleted +0 -14
@@ -1,14 +0,0 @@ -# -# Copyright (C) 2002 - 2003 Jeff Dike ([email protected]) -# Licensed under the GPL -# - -obj-y = exec_kern.o exec_user.o gdb.o ksyms.o mem.o mem_user.o process_kern.o \ - syscall_kern.o syscall_user.o tlb.o tracer.o trap_user.o \ - uaccess.o uaccess_user.o - -obj-$(CONFIG_PT_PROXY) += gdb_kern.o ptproxy/ - -USER_OBJS := gdb.o tracer.o - -include arch/um/scripts/Makefile.rules
arch/um/kernel/tt/exec_user.c deleted +0 -56
56 lines not on this page · raw message
arch/um/kernel/tt/gdb.c deleted +0 -280
280 lines not on this page · raw message
arch/um/kernel/tt/gdb_kern.c deleted +0 -40
@@ -1,40 +0,0 @@ -/* -* Copyright (C) 2002 Jeff Dike ([email protected]) -* Licensed under the GPL -*/ - -#include "linux/init.h" -#include "mconsole_kern.h" - -#ifdef CONFIG_MCONSOLE - -extern int gdb_config (char *str,char **error_out); -extern int gdb_remove (int n,char **error_out); - -static struct mc_device gdb_mc = { - .list =INIT_LIST_HEAD (gdb_mc.list), - .name ="gdb" , - .config = gdb_config, - .remove = gdb_remove, -}; - -int gdb_mc_init (void ) -{ -mconsole_register_dev (&gdb_mc); -return (0 ); -} - -__initcall (gdb_mc_init); - -#endif - -/* -* Overrides for Emacs so that we follow Linus's tabbing style. -* Emacs will notice this stuff at the end of the file and automatically -* adjust the settings for this buffer only. This must remain at the end -* of the file. -* --------------------------------------------------------------------------- -* Local variables: -* c-file-style: "linux" -* End: -*/
arch/um/kernel/tt/include/mode-tt.h deleted +0 -34
@@ -1,34 +0,0 @@ -/* -* Copyright (C) 2002 Jeff Dike ([email protected]) -* Licensed under the GPL -*/ - -#ifndef __MODE_TT_H__ -#define __MODE_TT_H__ - -#include "sysdep/ptrace.h" - -enum {OP_NONE ,OP_EXEC ,OP_FORK ,OP_TRACE_ON ,OP_REBOOT ,OP_HALT ,OP_CB }; - -extern int tracing_pid; - -extern int tracer (int (*init_proc)(void *),void *sp); -extern void sig_handler_common_tt (int sig,void *sc); -extern void syscall_handler_tt (int sig,union uml_pt_regs *regs); -extern void reboot_tt (void ); -extern void halt_tt (void ); -extern int is_tracer_winch (int pid,int fd,void *data); -extern void kill_off_processes_tt (void ); - -#endif - -/* -* Overrides for Emacs so that we follow Linus's tabbing style. -* Emacs will notice this stuff at the end of the file and automatically -* adjust the settings for this buffer only. This must remain at the end -* of the file. -* --------------------------------------------------------------------------- -* Local variables: -* c-file-style: "linux" -* End: -*/
arch/um/kernel/tt/ksyms.c deleted +0 -29
@@ -1,29 +0,0 @@ -/* -* Copyright (C) 2001, 2002 Jeff Dike ([email protected]) -* Licensed under the GPL -*/ - -#include "linux/module.h" -#include "asm/uaccess.h" -#include "mode.h" - -EXPORT_SYMBOL (__do_copy_from_user); -EXPORT_SYMBOL (__do_copy_to_user); -EXPORT_SYMBOL (__do_strncpy_from_user); -EXPORT_SYMBOL (__do_strnlen_user); -EXPORT_SYMBOL (__do_clear_user); -EXPORT_SYMBOL (clear_user_tt); - -EXPORT_SYMBOL (tracing_pid); -EXPORT_SYMBOL (honeypot); - -/* -* Overrides for Emacs so that we follow Linus's tabbing style. -* Emacs will notice this stuff at the end of the file and automatically -* adjust the settings for this buffer only. This must remain at the end -* of the file. -* --------------------------------------------------------------------------- -* Local variables: -* c-file-style: "linux" -* End: -*/
arch/um/kernel/tt/mem.c deleted +0 -34
@@ -1,34 +0,0 @@ -/* -* Copyright (C) 2002 Jeff Dike ([email protected]) -* Licensed under the GPL -*/ - -#include "linux/stddef.h" -#include "linux/mm.h" -#include "asm/uaccess.h" -#include "mem_user.h" -#include "kern_util.h" -#include "kern.h" -#include "tt.h" - -void before_mem_tt (unsigned long brk_start) -{ -if (debug) -remap_data (UML_ROUND_DOWN (&_stext),UML_ROUND_UP (&_etext),1 ); -remap_data (UML_ROUND_DOWN (&_sdata),UML_ROUND_UP (&_edata),1 ); -remap_data (UML_ROUND_DOWN (&__bss_start),UML_ROUND_UP (&_end),1 ); -} - -#define SIZE ((CONFIG_NEST_LEVEL + CONFIG_KERNEL_HALF_GIGS) * 0x20000000) -#define START (CONFIG_TOP_ADDR - SIZE) - -unsigned long set_task_sizes_tt (unsigned long *task_size_out) -{ -unsigned long host_task_size; - -/* Round up to the nearest 4M */ - host_task_size =ROUND_4M ((unsigned long ) &host_task_size); - *task_size_out =START ; - -return host_task_size; -}
arch/um/kernel/tt/mem_user.c deleted +0 -49
49 lines not on this page · raw message
arch/um/kernel/tt/process_kern.c deleted +0 -461
461 lines not on this page · raw message
arch/um/kernel/tt/ptproxy/Makefile deleted +0 -10
@@ -1,10 +0,0 @@ -# -# Copyright (C) 2002 Jeff Dike ([email protected]) -# Licensed under the GPL -# - -obj-y = proxy.o ptrace.o sysdep.o wait.o - -USER_OBJS := $(obj-y) - -include arch/um/scripts/Makefile.rules
arch/um/kernel/tt/ptproxy/ptproxy.h deleted +0 -61
61 lines not on this page · raw message
arch/um/kernel/tt/ptproxy/ptrace.c deleted +0 -237
237 lines not on this page · raw message
arch/um/kernel/tt/ptproxy/sysdep.c deleted +0 -70
70 lines not on this page · raw message
arch/um/kernel/tt/ptproxy/sysdep.h deleted +0 -25
@@ -1,25 +0,0 @@ -/********************************************************************** -sysdep.h - -Copyright (C) 1999 Lars Brinkhoff. -Copyright (C) 2001 Jeff Dike ([email protected]) -See the file COPYING for licensing terms and conditions. -**********************************************************************/ - -extern int get_syscall (pid_t pid,long *arg1,long *arg2,long *arg3, -long *arg4,long *arg5); -extern void syscall_cancel (pid_t pid,long result); -extern void syscall_set_result (pid_t pid,long result); -extern void syscall_continue (pid_t pid); -extern int syscall_pause (pid_t pid); - -/* -* Overrides for Emacs so that we follow Linus's tabbing style. -* Emacs will notice this stuff at the end of the file and automatically -* adjust the settings for this buffer only. This must remain at the end -* of the file. -* --------------------------------------------------------------------------- -* Local variables: -* c-file-style: "linux" -* End: -*/
arch/um/kernel/tt/ptproxy/wait.c deleted +0 -85
85 lines not on this page · raw message
arch/um/kernel/tt/ptproxy/wait.h deleted +0 -15
@@ -1,15 +0,0 @@ -/********************************************************************** -wait.h - -Copyright (C) 1999 Lars Brinkhoff. See the file COPYING for licensing -terms and conditions. -**********************************************************************/ - -#ifndef __PTPROXY_WAIT_H -#define __PTPROXY_WAIT_H - -extern int proxy_wait_return (struct debugger *debugger,pid_t unused); -extern int real_wait_return (struct debugger *debugger); -extern int parent_wait_return (struct debugger *debugger,pid_t unused); - -#endif
arch/um/kernel/tt/syscall_kern.c deleted +0 -46
46 lines not on this page · raw message
arch/um/kernel/tt/syscall_user.c deleted +0 -60
60 lines not on this page · raw message
arch/um/kernel/tt/tlb.c deleted +0 -120
120 lines not on this page · raw message
arch/um/kernel/tt/tracer.c deleted +0 -461
461 lines not on this page · raw message
arch/um/kernel/tt/trap_user.c deleted +0 -70
70 lines not on this page · raw message
arch/um/kernel/tt/uaccess.c deleted +0 -73
73 lines not on this page · raw message
arch/um/scripts/Makefile.rules +1 -1
@@ -21,7 +21,7 @@ $(UNPROFILE_OBJS:.o=.%): \ $(UNPROFILE_OBJS) : CHECKFLAGS := -D__linux__ -Dlinux -D__STDC__ \ -Dunix -D__unix__ -D__$(SUBARCH)__ $(CF) -# The stubs and unmap.o can't try to call mcount or update basic block data +# The stubs can't try to call mcount or update basic block data define unprofile $(patsubst -pg,,$(patsubst -fprofile-arcs -ftest-coverage,,$(1))) endef
arch/um/sys-i386/unmap.c deleted +0 -25
@@ -1,25 +0,0 @@ -/* -* Copyright (C) 2000 Jeff Dike ([email protected]) -* Licensed under the GPL -*/ - -#include <linux/mman.h> -#include <asm/unistd.h> - -static int errno; - -static inline _syscall2(int,munmap,void *,start,size_t,len) -static inline _syscall6 (void *,mmap2 ,void *,addr ,size_t ,len ,int ,prot ,int ,flags ,int ,fd ,off_t ,offset ) -int switcheroo(int fd, int prot, void *from, void *to, int size) -{ -if (munmap (to, size) <0 ){ -return (-1 ); - } -if (mmap2 (to, size, prot,MAP_SHARED |MAP_FIXED , fd,0 ) == (void *)-1 ){ -return (-1 ); - } -if (munmap (from, size) <0 ){ -return (-1 ); - } -return (0 ); -}
arch/um/sys-x86_64/unmap.c deleted +0 -25
@@ -1,25 +0,0 @@ -/* -* Copyright (C) 2000 Jeff Dike ([email protected]) -* Licensed under the GPL -*/ - -#include <linux/mman.h> -#include <asm/unistd.h> - -static int errno; - -static inline _syscall2(int,munmap,void *,start,size_t,len) -static inline _syscall6 (void *,mmap ,void *,addr ,size_t ,len ,int ,prot ,int ,flags ,int ,fd ,off_t ,offset ) -int switcheroo(int fd, int prot, void *from, void *to, int size) -{ -if (munmap (to, size) <0 ){ -return (-1 ); - } -if (mmap (to, size, prot,MAP_SHARED |MAP_FIXED , fd,0 ) == (void *)-1 ){ -return (-1 ); - } -if (munmap (from, size) <0 ){ -return (-1 ); - } -return (0 ); -}
arch/um/Kconfig.debug +2 -21
@@ -2,28 +2,9 @@ menu "Kernel hacking" source "lib/Kconfig.debug" -config CMDLINE_ON_HOST - bool "Show command line arguments on the host in TT mode" - depends on MODE_TT - default !DEBUG_INFO - help - This controls whether arguments in guest processes should be shown on - the host's ps output. - Enabling this option hinders debugging on some recent GDB versions - (because GDB gets "confused" when we do an execvp()). So probably you - should disable it. - -config PT_PROXY - bool "Enable ptrace proxy" - depends on XTERM_CHAN && DEBUG_INFO && MODE_TT - help - This option enables a debugging interface which allows gdb to debug - the kernel without needing to actually attach to kernel threads. - If you want to do kernel debugging, say Y here; otherwise say N. - config GPROF bool "Enable gprof support" - depends on DEBUG_INFO && MODE_SKAS && !MODE_TT + depends on DEBUG_INFO help This allows profiling of a User-Mode Linux kernel with the gprof utility.
@@ -36,7 +17,7 @@ config GPROF config GCOV bool "Enable gcov support" - depends on DEBUG_INFO && MODE_SKAS + depends on DEBUG_INFO help This option allows developers to retrieve coverage data from a UML session.
arch/um/Makefile-i386 +1 -5
@@ -2,11 +2,7 @@ core-y += arch/um/sys-i386/ arch/i386/cr TOP_ADDR := $(CONFIG_TOP_ADDR) -ifeq ($(CONFIG_MODE_SKAS),y) - ifneq ($(CONFIG_MODE_TT),y) - START := 0x8048000 - endif -endif +START := 0x8048000 LDFLAGS += -m elf_i386 ELF_ARCH := $(SUBARCH)
arch/um/defconfig +0 -2
@@ -12,9 +12,7 @@ CONFIG_IRQ_RELEASE_METHOD=y # # UML-specific options # -# CONFIG_MODE_TT is not set # CONFIG_STATIC_LINK is not set -CONFIG_MODE_SKAS=y # # Host processor type and features
arch/um/include/choose-mode.h +0 -18
@@ -8,26 +8,8 @@#include "uml-config.h" -#if defined(UML_CONFIG_MODE_TT ) && defined(UML_CONFIG_MODE_SKAS ) -#define CHOOSE_MODE (tt, skas) (mode_tt ? (tt) : (skas)) - -extern int mode_tt; -static inline void *__choose_mode (void *tt,void *skas) { -return mode_tt ? tt : skas; -} - -#define __CHOOSE_MODE (tt, skas) (*( (typeof(tt) *) __choose_mode(&(tt), &(skas)))) - -#elif defined(UML_CONFIG_MODE_SKAS )#define CHOOSE_MODE (tt, skas) (skas) -#elif defined(UML_CONFIG_MODE_TT ) -#define CHOOSE_MODE (tt, skas) (tt) - -#else -#error CONFIG_MODE_SKAS and CONFIG_MODE_TT are both disabled -#endif - #define CHOOSE_MODE_PROC(tt, skas, args...) \ CHOOSE_MODE(tt(args), skas(args))
arch/um/include/irq_user.h +0 -4
@@ -30,8 +30,4 @@ extern void deactivate_fd(int fd, int irextern int deactivate_all_fds (void );extern int activate_ipi (int fd,int pid); -#ifdef CONFIG_MODE_TT -extern void forward_interrupts (int pid); -#endif -#endif
arch/um/include/mode.h +0 -19
@@ -6,25 +6,6 @@#ifndef __MODE_H__#define __MODE_H__ -#include "uml-config.h" - -#ifdef UML_CONFIG_MODE_TT -#include "mode-tt.h" -#endif - -#ifdef UML_CONFIG_MODE_SKAS #include "mode-skas.h" -#endif #endif - -/* -* Overrides for Emacs so that we follow Linus's tabbing style. -* Emacs will notice this stuff at the end of the file and automatically -* adjust the settings for this buffer only. This must remain at the end -* of the file. -* --------------------------------------------------------------------------- -* Local variables: -* c-file-style: "linux" -* End: -*/
arch/um/include/mode_kern.h +0 -6
@@ -6,12 +6,6 @@#ifndef __MODE_KERN_H__#define __MODE_KERN_H__ -#ifdef CONFIG_MODE_TT -#include "mode_kern_tt.h" -#endif - -#ifdef CONFIG_MODE_SKAS #include "mode_kern_skas.h" -#endif #endif
arch/um/include/sysdep-i386/ptrace.h +0 -23
@@ -14,12 +14,7 @@#define MAX_REG_NR (UM_FRAME_SIZE / sizeof(unsigned long))#define MAX_REG_OFFSET (UM_FRAME_SIZE) -#ifdef UML_CONFIG_PT_PROXY -extern void update_debugregs (int seq); -#else static inline void update_debugregs (int seq) {} -#endif -/* syscall emulation path in ptrace */
@@ -31,12 +26,6 @@ void set_using_sysemu(int value);int get_using_sysemu (void );extern int sysemu_supported; -#ifdef UML_CONFIG_MODE_TT -#include "sysdep/sc.h" -#endif - -#ifdef UML_CONFIG_MODE_SKAS -#include "skas_ptregs.h" #define REGS_IP (r) ((r)[HOST_IP])
@@ -60,20 +49,11 @@ extern int sysemu_supported;#define REGS_RESTART_SYSCALL (r) IP_RESTART_SYSCALL(REGS_IP(r)) -#endif #ifndef PTRACE_SYSEMU_SINGLESTEP #define PTRACE_SYSEMU_SINGLESTEP 32#endif union uml_pt_regs { -#ifdef UML_CONFIG_MODE_TT -struct tt_regs { -long syscall; -void *sc; -struct faultinfo faultinfo; - } tt; -#endif -#ifdef UML_CONFIG_MODE_SKASstruct skas_regs {unsigned long regs[MAX_REG_NR ];unsigned long fp[HOST_FP_SIZE ];
@@ -82,13 +62,10 @@ union uml_pt_regs {long syscall;int is_user; } skas; -#endif };#define EMPTY_UML_PT_REGS { } -extern int mode_tt; -#define UPT_SC (r) ((r)->tt.sc)#define UPT_IP (r) \ __CHOOSE_MODE(SC_IP(UPT_SC(r)), REGS_IP((r)->skas.regs))
arch/um/include/sysdep-i386/thread.h +0 -3
@@ -4,8 +4,5 @@#include <kern_constants.h> #define TASK_DEBUGREGS (task) ((unsigned long *) &(((char *) (task))[HOST_TASK_DEBUGREGS])) -#ifdef UML_CONFIG_MODE_TT -#define TASK_EXTERN_PID (task) *((int *) &(((char *) (task))[HOST_TASK_EXTERN_PID])) -#endif #endif
arch/um/include/sysdep-x86_64/ptrace.h +1 -20
@@ -1,5 +1,6 @@/* * Copyright 2003 PathScale, Inc. +* Copyright (C) 2003 - 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com) * * Licensed under the GPL */
@@ -14,11 +15,6 @@#define MAX_REG_OFFSET (UM_FRAME_SIZE)#define MAX_REG_NR ((MAX_REG_OFFSET) / sizeof(unsigned long)) -#ifdef UML_CONFIG_MODE_TT -#include "sysdep/sc.h" -#endif - -#ifdef UML_CONFIG_MODE_SKAS #include "skas_ptregs.h" #define REGS_IP (r) ((r)[HOST_IP])
@@ -88,21 +84,10 @@#define REGS_ERR (r) ((r)->fault_type) -#endif -#include "choose-mode.h" /* XXX */ union uml_pt_regs { -#ifdef UML_CONFIG_MODE_TT -struct tt_regs { -long syscall; -unsigned long orig_rax; -void *sc; -struct faultinfo faultinfo; - } tt; -#endif -#ifdef UML_CONFIG_MODE_SKASstruct skas_regs {unsigned long regs[MAX_REG_NR ];unsigned long fp[HOST_FP_SIZE ];
@@ -110,14 +95,10 @@ union uml_pt_regs {long syscall;int is_user; } skas; -#endif };#define EMPTY_UML_PT_REGS { } -/* XXX */ -extern int mode_tt; -#define UPT_RBX (r) __CHOOSE_MODE(SC_RBX(UPT_SC(r)), REGS_RBX((r)->skas.regs))#define UPT_RCX (r) __CHOOSE_MODE(SC_RCX(UPT_SC(r)), REGS_RCX((r)->skas.regs))#define UPT_RDX (r) __CHOOSE_MODE(SC_RDX(UPT_SC(r)), REGS_RDX((r)->skas.regs))
arch/um/include/sysdep-x86_64/thread.h +0 -4
@@ -3,8 +3,4 @@#include <kern_constants.h> -#ifdef UML_CONFIG_MODE_TT -#define TASK_EXTERN_PID (task) *((int *) &(((char *) (task))[HOST_TASK_EXTERN_PID])) -#endif -#endif
arch/um/include/tt/debug.h deleted +0 -18
@@ -1,18 +0,0 @@ -/* -* Copyright (C) 2000, 2001, 2002 Jeff Dike ([email protected]) and -* Lars Brinkhoff. -* Licensed under the GPL -*/ - -#ifndef __UML_TT_DEBUG_H -#define __UML_TT_DEBUG_H - -extern int debugger_proxy (int status,pid_t pid); -extern void child_proxy (pid_t pid,int status); -extern void init_proxy (pid_t pid,int waiting,int status); -extern int start_debugger (char *prog,int startup,int stop,int *debugger_fd); -extern void fake_child_exit (void ); -extern int gdb_config (char *str); -extern int gdb_remove (int unused); - -#endif
arch/um/include/tt/mmu-tt.h deleted +0 -12
@@ -1,12 +0,0 @@ -/* -* Copyright (C) 2002 Jeff Dike ([email protected]) -* Licensed under the GPL -*/ - -#ifndef __TT_MMU_H -#define __TT_MMU_H - -struct mmu_context_tt { -}; - -#endif
arch/um/include/tt/mode-tt.h deleted +0 -23
@@ -1,23 +0,0 @@ -/* -* Copyright (C) 2002 Jeff Dike ([email protected]) -* Licensed under the GPL -*/ - -#ifndef __MODE_TT_H__ -#define __MODE_TT_H__ - -#include "sysdep/ptrace.h" - -enum {OP_NONE ,OP_EXEC ,OP_FORK ,OP_TRACE_ON ,OP_REBOOT ,OP_HALT ,OP_CB }; - -extern int tracing_pid; - -extern int tracer (int (*init_proc)(void *),void *sp); -extern void sig_handler_common_tt (int sig,void *sc); -extern void syscall_handler_tt (int sig,union uml_pt_regs *regs); -extern void reboot_tt (void ); -extern void halt_tt (void ); -extern int is_tracer_winch (int pid,int fd,void *data); -extern void kill_off_processes_tt (void ); - -#endif
arch/um/include/tt/mode_kern_tt.h deleted +0 -40
@@ -1,40 +0,0 @@ -/* -* Copyright (C) 2002 Jeff Dike ([email protected]) -* Licensed under the GPL -*/ - -#ifndef __TT_MODE_KERN_H__ -#define __TT_MODE_KERN_H__ - -#include "linux/sched.h" -#include "asm/page.h" -#include "asm/ptrace.h" -#include "asm/uaccess.h" - -extern void switch_to_tt (void *prev,void *next); -extern void flush_thread_tt (void ); -extern void start_thread_tt (struct pt_regs *regs,unsigned long eip, -unsigned long esp); -extern int copy_thread_tt (int nr,unsigned long clone_flags,unsigned long sp, -unsigned long stack_top,struct task_struct *p, -struct pt_regs *regs); -extern void release_thread_tt (struct task_struct *task); -extern void initial_thread_cb_tt (void (*proc)(void *),void *arg); -extern void init_idle_tt (void ); -extern void flush_tlb_kernel_range_tt (unsigned long start,unsigned long end); -extern void flush_tlb_kernel_vm_tt (void ); -extern void __flush_tlb_one_tt (unsigned long addr); -extern void flush_tlb_range_tt (struct vm_area_struct *vma, -unsigned long start,unsigned long end); -extern void flush_tlb_mm_tt (struct mm_struct *mm); -extern void force_flush_all_tt (void ); -extern long execute_syscall_tt (void *r); -extern void before_mem_tt (unsigned long brk_start); -extern unsigned long set_task_sizes_tt (unsigned long *task_size_out); -extern int start_uml_tt (void ); -extern int external_pid_tt (struct task_struct *task); -extern int thread_pid_tt (struct task_struct *task); - -#define kmem_end_tt (host_task_size - ABOVE_KMEM) - -#endif
arch/um/include/tt/tt.h deleted +0 -37
@@ -1,37 +0,0 @@ -/* -* Copyright (C) 2002 Jeff Dike ([email protected]) -* Licensed under the GPL -*/ - -#ifndef __TT_H__ -#define __TT_H__ - -#include "sysdep/ptrace.h" - -extern int gdb_pid; -extern int debug; -extern int debug_stop; -extern int debug_trace; - -extern int honeypot; - -extern int fork_tramp (void *sig_stack); -extern int do_proc_op (void *t,int proc_id); -extern int tracer (int (*init_proc)(void *),void *sp); -extern void attach_process (int pid); -extern void tracer_panic (char *format, ...) - __attribute__ ((format (printf,1 ,2 ))); -extern void set_init_pid (int pid); -extern int set_user_mode (void *task); -extern void set_tracing (void *t,int tracing); -extern int is_tracing (void *task); -extern void syscall_handler (int sig,union uml_pt_regs *regs); -extern void exit_kernel (int pid,void *task); -extern void do_syscall (void *task,int pid,int local_using_sysemu); -extern void do_sigtrap (void *task); -extern int is_valid_pid (int pid); -extern void remap_data (void *segment_start,void *segment_end,int w); -extern long execute_syscall_tt (void *r); -
Lines of this file are not shown. View the raw message.
arch/um/include/tt/uaccess-tt.h deleted +0 -46
46 lines not on this page · raw message
arch/um/kernel/um_arch.c +4 -109
113 lines not on this page · raw message
arch/um/sys-i386/ldt.c +0 -67
67 lines not on this page · raw message
arch/um/sys-i386/ptrace.c +0 -120
120 lines not on this page · raw message
arch/um/sys-i386/signal.c +0 -58
58 lines not on this page · raw message
arch/um/sys-x86_64/signal.c +0 -50
50 lines not on this page · raw message
arch/um/sys-i386/ptrace_user.c +0 -86
86 lines not on this page · raw message
arch/um/kernel/tt/exec_kern.c deleted +0 -84
84 lines not on this page · raw message
arch/um/kernel/tt/ptproxy/proxy.c deleted +0 -377
377 lines not on this page · raw message
arch/um/kernel/tt/uaccess_user.c deleted +0 -105
105 lines not on this page · raw message
arch/um/include/sysdep-i386/sigcontext.h +0 -4
Lines of this file are not shown. View the raw message.
The rest of this diff is not shown. View the raw message.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
User-mode-linux-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel
Part of the diff is not shown here. View the raw message.