From c5d4bb171cab17576779a51d23d313abcb3db102 Mon Sep 17 00:00:00 2001 From: Jeff Dike Date: Mon, 4 Feb 2008 22:31:14 -0800 Subject: uml: style fixes in arch/um/kernel Joe Perches noticed some printks in smp.c that needed fixing. While I was in there, I did the usual tidying in arch/um/kernel, which should be fairly style-clean at this point: copyright updates emacs formatting comments removal include tidying style fixes Cc: Joe Perches Signed-off-by: Jeff Dike Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- arch/um/kernel/process.c | 41 ++++++++++++++++++++++------------------- 1 file changed, 22 insertions(+), 19 deletions(-) (limited to 'arch/um/kernel/process.c') diff --git a/arch/um/kernel/process.c b/arch/um/kernel/process.c index e6d89ad..c07961b 100644 --- a/arch/um/kernel/process.c +++ b/arch/um/kernel/process.c @@ -4,19 +4,21 @@ * Licensed under the GPL */ -#include "linux/stddef.h" -#include "linux/err.h" -#include "linux/hardirq.h" -#include "linux/mm.h" -#include "linux/personality.h" -#include "linux/proc_fs.h" -#include "linux/ptrace.h" -#include "linux/random.h" -#include "linux/sched.h" -#include "linux/tick.h" -#include "linux/threads.h" -#include "asm/pgtable.h" -#include "asm/uaccess.h" +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include #include "as-layout.h" #include "kern_util.h" #include "os.h" @@ -40,7 +42,7 @@ int pid_to_processor_id(int pid) { int i; - for(i = 0; i < ncpus; i++) { + for (i = 0; i < ncpus; i++) { if (cpu_tasks[i].pid == pid) return i; } @@ -94,14 +96,15 @@ void *_switch_to(void *prev, void *next, void *last) do { current->thread.saved_task = NULL; - switch_threads(&from->thread.switch_buf, &to->thread.switch_buf); + switch_threads(&from->thread.switch_buf, + &to->thread.switch_buf); arch_switch_to(current); if (current->thread.saved_task) show_regs(&(current->thread.regs)); - next = current->thread.saved_task; - prev = current; + to = current->thread.saved_task; + from = current; } while (current->thread.saved_task); return current->thread.prev_sched; @@ -232,7 +235,7 @@ void default_idle(void) { unsigned long long nsecs; - while(1) { + while (1) { /* endless idle loop with no priority at all */ /* @@ -387,7 +390,7 @@ int singlestepping(void * t) { struct task_struct *task = t ? t : current; - if ( ! (task->ptrace & PT_DTRACE) ) + if (!(task->ptrace & PT_DTRACE)) return 0; if (task->thread.singlestep_syscall) -- cgit v1.1