From: Kenn H. <ke...@us...> - 2002-10-29 00:52:56
|
Update of /cvsroot/linux-vax/kernel-2.5/arch/vax/kernel In directory usw-pr-cvs1:/tmp/cvs-serv2713/arch/vax/kernel Modified Files: cpu_ka43.c entry.S init_task.c interrupt.c process.c ptrace.c Log Message: Merge Linus' 2.5.4 release. Major change is the splitting of task_struct into task_struct and struct thread_info. Index: cpu_ka43.c =================================================================== RCS file: /cvsroot/linux-vax/kernel-2.5/arch/vax/kernel/cpu_ka43.c,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- cpu_ka43.c 5 Jun 2002 21:55:03 -0000 1.7 +++ cpu_ka43.c 29 Oct 2002 00:52:50 -0000 1.8 @@ -167,8 +167,10 @@ * Resetting the cache involves disabling it, then clear it and enable again. */ ka43_cache_disable(ka43_creg_addr); +#if 0 ka43_cache_clear(ka43_ctag_addr); ka43_cache_enable(ka43_creg_addr); +#endif } void ka43_init_devices(void) @@ -207,8 +209,13 @@ /* Unknown error state, panic/halt the machine */ printk("KA43: Machine Check - unknown error state - halting\n"); - machine_halt(); + printk("\nStack dump\n"); + hex_dump((void *)(&stkframe), 256); + dump_cur_regs(1); + show_cpu_regs(); + + machine_halt(); } /* slap the KA43_DIAGMEM bit on an area of S0 memory - used by drivers */ Index: entry.S =================================================================== RCS file: /cvsroot/linux-vax/kernel-2.5/arch/vax/kernel/entry.S,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- entry.S 20 May 2002 00:33:33 -0000 1.4 +++ entry.S 29 Oct 2002 00:52:50 -0000 1.5 @@ -474,6 +474,7 @@ .long sys_madvise .long sys_getdents64 /* 220 */ .long sys_fcntl64 + .long sys_tkill /* * NOTE!! This doesn't have to be exact - we just have Index: init_task.c =================================================================== RCS file: /cvsroot/linux-vax/kernel-2.5/arch/vax/kernel/init_task.c,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- init_task.c 6 Jun 2002 00:12:24 -0000 1.5 +++ init_task.c 29 Oct 2002 00:52:50 -0000 1.6 @@ -17,7 +17,7 @@ struct mm_struct init_mm = INIT_MM(init_mm); /* - * Initial task structure. + * Initial thread structure. * * We need to make sure that this is 8192-byte aligned due to the * way process stacks are handled. This is done by having a special @@ -26,7 +26,14 @@ * Note that once we drop from IPL 31 to IPL 0 during init, we'll * be using the stack inside this union as the kernel stack. */ -union task_union init_task_union +union thread_union init_thread_union __attribute__((__section__(".data.init_task"))) = - { INIT_TASK(init_task_union.task) }; + { INIT_THREAD_INFO(init_task) }; +/* + * Initial task structure. + * + * All other task structs will be allocated on slabs in fork.c + */ +struct task_struct init_task = INIT_TASK(init_task); + Index: interrupt.c =================================================================== RCS file: /cvsroot/linux-vax/kernel-2.5/arch/vax/kernel/interrupt.c,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- interrupt.c 6 Jun 2002 00:12:24 -0000 1.6 +++ interrupt.c 29 Oct 2002 00:52:50 -0000 1.7 @@ -542,7 +542,7 @@ } /* check for pending signals */ - if (current->work.sigpending != 0) { + if (test_tsk_thread_flag(current, TIF_SIGPENDING)) { /* FIXME: do we need to check the IPL here (i386 does a sti here) */ /* FIXME: oldset? */ do_signal(0,regs); Index: process.c =================================================================== RCS file: /cvsroot/linux-vax/kernel-2.5/arch/vax/kernel/process.c,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- process.c 6 Jun 2002 00:12:24 -0000 1.6 +++ process.c 29 Oct 2002 00:52:50 -0000 1.7 @@ -111,12 +111,7 @@ struct pt_regs *child_regs; void *stack_top; - /* stack top is at the end of the task_union - - take the pointer, add in the size of task_union, - and then drop by a longword to keep it within the - current union - */ - stack_top = ((union task_union *)p)+1; + stack_top = (unsigned char *)(p->thread_info) + THREAD_SIZE; stack_top -= 4; child_stack = (struct new_thread_stack *)(stack_top) - 1; Index: ptrace.c =================================================================== RCS file: /cvsroot/linux-vax/kernel-2.5/arch/vax/kernel/ptrace.c,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- ptrace.c 6 Jun 2002 00:12:24 -0000 1.5 +++ ptrace.c 29 Oct 2002 00:52:50 -0000 1.6 @@ -39,7 +39,7 @@ unsigned long *pc1, *pc2; void *stack_top; - stack_top = ((union task_union *)child)+1; + stack_top = child->thread_info + THREAD_SIZE; stack_top -= 4; @@ -272,15 +272,9 @@ if ((unsigned long) data > _NSIG) break; if (request == PTRACE_SYSCALL) { - if (!(child->ptrace & PT_SYSCALLTRACE)) { - child->ptrace |= PT_SYSCALLTRACE; - child->work.syscall_trace++; - } + set_tsk_thread_flag(child, TIF_SYSCALL_TRACE); } else { - if (child->ptrace & PT_SYSCALLTRACE) { - child->ptrace &= ~PT_SYSCALLTRACE; - child->work.syscall_trace--; - } + clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE); } child->exit_code = data; wake_up_process(child); @@ -308,10 +302,7 @@ res = -EIO; if ((unsigned long) data > _NSIG) break; - if (child->ptrace & PT_SYSCALLTRACE) { - child->ptrace &= ~PT_SYSCALLTRACE; - child->work.syscall_trace--; - } + clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE); if ((child->ptrace & PT_DTRACE)==0) child->ptrace |= PT_DTRACE; @@ -336,7 +327,7 @@ goto out; } out_tsk: - free_task_struct(child); + put_task_struct(child); out: unlock_kernel(); return res; @@ -344,8 +335,9 @@ asmlinkage void syscall_trace(void) { - if ((current->ptrace & (PT_PTRACED|PT_SYSCALLTRACE)) - != (PT_PTRACED|PT_SYSCALLTRACE)) + if (!test_thread_flag(TIF_SYSCALL_TRACE)) + return; + if (!(current->ptrace & PT_PTRACED)) return; current->exit_code = SIGTRAP; current->state = TASK_STOPPED; |