patch-2.1.37 linux/arch/m68k/kernel/process.c

Next file: linux/arch/m68k/kernel/ptrace.c
Previous file: linux/arch/m68k/kernel/m68k_ksyms.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.36/linux/arch/m68k/kernel/process.c linux/arch/m68k/kernel/process.c
@@ -10,6 +10,7 @@
  * This file handles the architecture-dependent parts of process handling..
  */
 
+#include <linux/config.h>
 #include <linux/errno.h>
 #include <linux/sched.h>
 #include <linux/kernel.h>
@@ -30,6 +31,22 @@
 #include <asm/machdep.h>
 #include <asm/setup.h>
 
+/*
+ * Initial task structure. Make this a per-architecture thing,
+ * because different architectures tend to have different
+ * alignment requirements and potentially different initial
+ * setup.
+ */
+static unsigned long init_kernel_stack[1024] = { STACK_MAGIC, };
+unsigned long init_user_stack[1024] = { STACK_MAGIC, };
+static struct vm_area_struct init_mmap = INIT_MMAP;
+static struct fs_struct init_fs = INIT_FS;
+static struct files_struct init_files = INIT_FILES;
+static struct signal_struct init_signals = INIT_SIGNALS;
+
+struct mm_struct init_mm = INIT_MM;
+struct task_struct init_task = INIT_TASK;
+
 asmlinkage void ret_from_exception(void);
 
 /*
@@ -46,8 +63,16 @@
 	/* endless idle loop with no priority at all */
 	current->priority = -100;
 	current->counter = -100;
-	for (;;)
+	for (;;){
+		if (!need_resched)
+#if defined(CONFIG_ATARI) && !defined(CONFIG_AMIGA) && !defined(CONFIG_MAC)
+			/* block out HSYNC on the atari (falcon) */
+			__asm__("stop #0x2200" : : : "cc");
+#else /* portable version */
+			__asm__("stop #0x2000" : : : "cc");
+#endif /* machine compilation types */ 
 		schedule();
+	}
 	ret = 0;
 out:
 	unlock_kernel();

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov