linux-um archives
 help / color / mirror / Atom feed
* [uml-devel] [PATCH] UML - tty locking
@ 2006-09-11 18:43 Alan Cox
  0 siblings, 0 replies; only message in thread
From: Alan Cox @ 2006-09-11 18:43 UTC (permalink / raw)
  To: akpm, jdike

Jeff this is the tty locking diff I mentioned at Linux Kongress, it just
ensures current->signal->tty doesn't get freed during log_exec().

Signed-off-by: Alan Cox <alan@redhat.com>

diff -u --new-file --recursive --exclude-from /usr/src/exclude linux.vanilla-2.6.18-rc6-mm1/arch/um/kernel/exec.c linux-2.6.18-rc6-mm1/arch/um/kernel/exec.c
--- linux.vanilla-2.6.18-rc6-mm1/arch/um/kernel/exec.c	2006-09-11 11:02:11.000000000 +0100
+++ linux-2.6.18-rc6-mm1/arch/um/kernel/exec.c	2006-09-11 17:16:36.000000000 +0100
@@ -41,9 +41,11 @@
         long error;
 
 #ifdef CONFIG_TTY_LOG
-	task_lock(current);
+	mutex_lock(&tty_mutex);
+	task_lock(current);	/* FIXME:  is this needed ? */
 	log_exec(argv, current->signal->tty);
 	task_unlock(current);
+	mutex_unlock(&tty_mutex);
 #endif
         error = do_execve(file, argv, env, &current->thread.regs);
         if (error == 0){


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
User-mode-linux-devel mailing list
User-mode-linux-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-09-11 18:19 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-09-11 18:43 [uml-devel] [PATCH] UML - tty locking Alan Cox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox