diff -Naur -X exclude-files ac_cur/arch/asm-um/page_offset.h ac/arch/asm-um/page_offset.h --- ac_cur/arch/asm-um/page_offset.h Wed Dec 31 19:00:00 1969 +++ ac/arch/asm-um/page_offset.h Fri Oct 5 14:16:42 2001 @@ -0,0 +1 @@ +#define PAGE_OFFSET_RAW (physmem) diff -Naur -X exclude-files ac_cur/arch/um/Makefile ac/arch/um/Makefile --- ac_cur/arch/um/Makefile Fri Oct 5 14:15:35 2001 +++ ac/arch/um/Makefile Fri Oct 5 14:16:42 2001 @@ -69,7 +69,7 @@ archmrproper: $(MAKE) -C $(ARCH_DIR)/sys-$(SUBARCH) archmrproper - rm -f $(ARCH_SYMLINKS) include/asm \ + rm -f $(SYMLINK_HEADERS) $(ARCH_SYMLINKS) include/asm \ $(addprefix $(ARCH_DIR)/kernel/,$(KERN_SYMLINKS)) archclean: diff -Naur -X exclude-files ac_cur/arch/um/config.in ac/arch/um/config.in --- ac_cur/arch/um/config.in Fri Oct 5 14:15:35 2001 +++ ac/arch/um/config.in Fri Oct 5 14:16:42 2001 @@ -80,19 +80,13 @@ mainmenu_option next_comment comment 'Network device support' - bool 'Network device support' CONFIG_NETDEVICES - if [ "$CONFIG_NETDEVICES" = "y" ]; then - bool ' Virtual network device' CONFIG_UML_NET - if [ "$CONFIG_UML_NET" != "n" ]; then - bool ' Ethertap transport' CONFIG_UML_NET_ETHERTAP - bool ' TUN/TAP transport' CONFIG_UML_NET_TUNTAP - bool ' SLIP transport' CONFIG_UML_NET_SLIP - bool ' Daemon transport' CONFIG_UML_NET_DAEMON - bool ' Multicast transport' CONFIG_UML_NET_MCAST - fi - - dep_tristate ' Ethertap network tap (EXPERIMENTAL)' CONFIG_ETHERTAP $CONFIG_NETLINK - tristate ' Universal TUN/TAP device driver support' CONFIG_TUN + bool ' Virtual network device support' CONFIG_UML_NET + if [ "$CONFIG_UML_NET" != "n" ]; then + bool ' Ethertap transport' CONFIG_UML_NET_ETHERTAP + bool ' TUN/TAP transport' CONFIG_UML_NET_TUNTAP + bool ' SLIP transport' CONFIG_UML_NET_SLIP + bool ' Daemon transport' CONFIG_UML_NET_DAEMON + bool ' Multicast transport' CONFIG_UML_NET_MCAST fi endmenu fi diff -Naur -X exclude-files ac_cur/arch/um/include/kern_util.h ac/arch/um/include/kern_util.h --- ac_cur/arch/um/include/kern_util.h Fri Oct 5 14:15:35 2001 +++ ac/arch/um/include/kern_util.h Fri Oct 5 14:16:42 2001 @@ -8,9 +8,6 @@ #include "sysdep/ptrace.h" -#define x(s) #s -#define xx(s) x(s) - #ifndef _UNISTD_H extern int write(int, const char *, int); #endif @@ -29,7 +26,6 @@ extern long execute_syscall(struct sys_pt_regs regs); extern void syscall_segv(int sig); extern int current_pid(void); -extern void do_bh(void); extern void set_init_pid(int pid); extern unsigned long alloc_stack(void); extern int do_signal(unsigned long *error, int *again_out); diff -Naur -X exclude-files ac_cur/arch/um/include/user_util.h ac/arch/um/include/user_util.h --- ac_cur/arch/um/include/user_util.h Fri Oct 5 14:15:35 2001 +++ ac/arch/um/include/user_util.h Fri Oct 5 14:16:42 2001 @@ -17,9 +17,6 @@ extern int write(int, const char *, int); #endif -#define y(s) #s -#define yy(s) y(s) - enum { OP_NONE, OP_EXEC, OP_SWITCH, OP_THREAD, OP_FORK, OP_FORK_FINISH, OP_TRACE_ON, OP_TRACE_OFF, OP_REBOOT, OP_HALT, OP_CB }; diff -Naur -X exclude-files ac_cur/arch/um/kernel/exec_kern.c ac/arch/um/kernel/exec_kern.c --- ac_cur/arch/um/kernel/exec_kern.c Fri Oct 5 14:15:35 2001 +++ ac/arch/um/kernel/exec_kern.c Fri Oct 5 14:16:42 2001 @@ -69,7 +69,12 @@ stack = alloc_stack(); new_pid = start_fork_tramp(current->thread.kernel_stack, stack, 0, exec_tramp); - if(new_pid < 0) do_exit(SIGKILL); + if(new_pid < 0){ + printk(KERN_ERR + "flush_thread : new thread failed, errno = %d\n", + errno); + do_exit(SIGKILL); + } forward_interrupts(new_pid); current->thread.request.op = OP_EXEC; current->thread.request.u.exec.pid = new_pid; diff -Naur -X exclude-files ac_cur/arch/um/kernel/process_kern.c ac/arch/um/kernel/process_kern.c --- ac_cur/arch/um/kernel/process_kern.c Fri Oct 5 14:15:35 2001 +++ ac/arch/um/kernel/process_kern.c Fri Oct 5 14:16:42 2001 @@ -216,25 +216,12 @@ return(current->thread.request.u.cswitch.from); } -void do_bh(void) -{ -#ifndef CONFIG_SMP - if (softirq_pending(0)){ - do_softirq(); - unblock_signals(); - } -#else -#error Need to update do_bh -#endif -} - void ret_from_sys_call(void *t) { struct task_struct *task; task = t; if(task == NULL) task = current; - do_bh(); if(task->need_resched) schedule(); if(task->sigpending != 0) do_signal(NULL, NULL); } @@ -671,13 +658,6 @@ } EXPORT_SYMBOL(get_fault_addr); - -void set_fault_addr(void *addr) -{ - current->thread.fault_addr = addr; -} - -EXPORT_SYMBOL(set_fault_addr); int singlestepping(void *t) { diff -Naur -X exclude-files ac_cur/arch/um/kernel/ptrace.c ac/arch/um/kernel/ptrace.c --- ac_cur/arch/um/kernel/ptrace.c Fri Oct 5 14:40:17 2001 +++ ac/arch/um/kernel/ptrace.c Fri Oct 5 14:39:03 2001 @@ -156,21 +156,10 @@ break; } - case PTRACE_DETACH: { /* detach a process that was attached. */ - ret = -EIO; - if ((unsigned long) data > _NSIG) - break; - child->ptrace &= ~(PT_PTRACED|PT_TRACESYS); - child->exit_code = data; - write_lock_irq(&tasklist_lock); - REMOVE_LINKS(child); - child->p_pptr = child->p_opptr; - SET_LINKS(child); - write_unlock_irq(&tasklist_lock); - wake_up_process(child); - ret = 0; - break; - } + case PTRACE_DETACH: + /* detach a process that was attached. */ + ret = ptrace_detach(child, data); + break; #ifdef PTRACE_GETREGS case PTRACE_GETREGS: { /* Get all gp regs from the child. */ diff -Naur -X exclude-files ac_cur/arch/um/kernel/signal_kern.c ac/arch/um/kernel/signal_kern.c --- ac_cur/arch/um/kernel/signal_kern.c Fri Oct 5 14:15:35 2001 +++ ac/arch/um/kernel/signal_kern.c Fri Oct 5 14:16:42 2001 @@ -208,14 +208,16 @@ continue; /* FALLTHRU */ - case SIGSTOP: + case SIGSTOP: { + struct signal_struct *sig; current->state = TASK_STOPPED; current->exit_code = signr; - if (!(current->p_pptr->sig->action[SIGCHLD-1].sa.sa_flags & SA_NOCLDSTOP)) + sig = current->p_pptr->sig; + if (sig && !(sig->action[SIGCHLD-1].sa.sa_flags & SA_NOCLDSTOP)) notify_parent(current, SIGCHLD); schedule(); continue; - + } case SIGQUIT: case SIGILL: case SIGTRAP: case SIGABRT: case SIGFPE: case SIGSEGV: case SIGBUS: case SIGSYS: case SIGXCPU: case SIGXFSZ: diff -Naur -X exclude-files ac_cur/arch/um/kernel/user_util.c ac/arch/um/kernel/user_util.c --- ac_cur/arch/um/kernel/user_util.c Fri Oct 5 14:15:35 2001 +++ ac/arch/um/kernel/user_util.c Fri Oct 5 14:16:42 2001 @@ -223,6 +223,7 @@ else if((WSTOPSIG(status) == SIGVTALRM) || (WSTOPSIG(status) == SIGALRM) || (WSTOPSIG(status) == SIGIO) || + (WSTOPSIG(status) == SIGPROF) || (WSTOPSIG(status) == SIGCHLD)){ ptrace(cont_type, pid, 0, WSTOPSIG(status)); continue; @@ -295,12 +296,12 @@ info.fd = fd; tracing_cb(grantpt_cb, &info); if(info.res < 0){ - printk("get_ptr : Couldn't grant pty - errno = %d\n", + printk("get_pty : Couldn't grant pty - errno = %d\n", info.err); return(-1); } if(unlockpt(fd) < 0){ - printk("get_ptr : Couldn't unlock pty - errno = %d\n", errno); + printk("get_pty : Couldn't unlock pty - errno = %d\n", errno); return(-1); } return(fd); diff -Naur -X exclude-files ac_cur/include/asm-um/page.h ac/include/asm-um/page.h --- ac_cur/include/asm-um/page.h Fri Oct 5 14:15:51 2001 +++ ac/include/asm-um/page.h Fri Oct 5 14:16:42 2001 @@ -7,7 +7,6 @@ #undef BUG #undef PAGE_BUG -#undef PAGE_OFFSET #undef __pa #undef __va #undef virt_to_page @@ -29,8 +28,6 @@ #endif /* __ASSEMBLY__ */ extern unsigned long physmem; - -#define PAGE_OFFSET (physmem) #define __va_space (8*1024*1024) diff -Naur -X exclude-files ac_cur/include/asm-um/smp.h ac/include/asm-um/smp.h --- ac_cur/include/asm-um/smp.h Fri Oct 5 14:15:51 2001 +++ ac/include/asm-um/smp.h Fri Oct 5 14:16:42 2001 @@ -1,6 +1,8 @@ #ifndef __UM_SMP_H #define __UM_SMP_H +#ifdef __CONFIG_SMP + #include "linux/config.h" #include "asm/current.h" @@ -17,6 +19,8 @@ extern int hard_smp_processor_id(void); #define NO_PROC_ID -1 + +#endif #endif diff -Naur -X exclude-files ac_cur/include/asm-um/tlb.h ac/include/asm-um/tlb.h --- ac_cur/include/asm-um/tlb.h Fri Oct 5 14:15:51 2001 +++ ac/include/asm-um/tlb.h Fri Oct 5 14:16:42 2001 @@ -1,3 +1,4 @@ +#include #ifndef __UM_TLB_H #define __UM_TLB_H