aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/linux/linux-turbostation/linux-2.6.16_arch_ppc_syslib_mpc10x_common.c
blob: 296395818eeaea51e3316fd831d5e70114ca70f1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Index: linux-2.6.20.1/arch/ppc/syslib/mpc10x_common.c
===================================================================
--- linux-2.6.20.1.orig/arch/ppc/syslib/mpc10x_common.c	2007-02-20 07:34:32.000000000 +0100
+++ linux-2.6.20.1/arch/ppc/syslib/mpc10x_common.c	2007-02-26 02:26:51.000000000 +0100
@@ -645,9 +645,11 @@
 	/* Skip reserved space and map i2c and DMA Ch[01] */
 	openpic_set_sources(EPIC_IRQ_BASE, 3, OpenPIC_Addr + 0x11020);
 	/* Skip reserved space and map Message Unit Interrupt (I2O) */
-	openpic_set_sources(EPIC_IRQ_BASE + 3, 1, OpenPIC_Addr + 0x110C0);
-	/* Skip reserved space and map Serial Interupts */
-	openpic_set_sources(EPIC_IRQ_BASE + 4, 2, OpenPIC_Addr + 0x11120);
+	//openpic_set_sources(EPIC_IRQ_BASE + 3, 1, OpenPIC_Addr + 0x110C0);
+#ifdef CONFIG_SANDPOINT
+	openpic_set_sources(EPIC_IRQ_BASE + 3, 1, OpenPIC_Addr + 0x11140);
+	openpic_set_sources(EPIC_IRQ_BASE + 4, 1, OpenPIC_Addr + 0x11120);
+#endif
 
 	openpic_init(NUM_8259_INTERRUPTS);
 }
n class="p">() try: # Fork a second child and exit immediately to prevent zombies. This # causes the second child process to be orphaned, making the init # process responsible for its cleanup. And, since the first child is # a session leader without a controlling terminal, it's possible for # it to acquire one by opening a terminal in the future (System V- # based systems). This second fork guarantees that the child is no # longer a session leader, preventing the daemon from ever acquiring # a controlling terminal. pid = os.fork() # Fork a second child. except OSError as e: raise Exception("%s [%d]" % (e.strerror, e.errno)) if (pid != 0): # Parent (the first child) of the second child. # exit() or _exit()? # _exit is like exit(), but it doesn't call any functions registered # with atexit (and on_exit) or any registered signal handlers. It also # closes any open file descriptors. Using exit() may cause all stdio # streams to be flushed twice and any temporary files may be unexpectedly # removed. It's therefore recommended that child branches of a fork() # and the parent branch(es) of a daemon use _exit(). os._exit(0) else: os.waitpid(pid, 0) return # The second child. # Replace standard fds with our own si = open('/dev/null', 'r') os.dup2(si.fileno(), sys.stdin.fileno()) try: so = open(logfile, 'a+') se = so os.dup2(so.fileno(), sys.stdout.fileno()) os.dup2(se.fileno(), sys.stderr.fileno()) except io.UnsupportedOperation: sys.stdout = open(logfile, 'a+') sys.stderr = sys.stdout try: function() except Exception as e: traceback.print_exc() finally: bb.event.print_ui_queue() os._exit(0)