aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
Diffstat (limited to 'arch')
-rw-r--r--arch/sparc64/solaris/misc.c4
-rw-r--r--arch/um/kernel/exec.c7
2 files changed, 5 insertions, 6 deletions
diff --git a/arch/sparc64/solaris/misc.c b/arch/sparc64/solaris/misc.c
index 9ed997982f8d..e84241d5f7f4 100644
--- a/arch/sparc64/solaris/misc.c
+++ b/arch/sparc64/solaris/misc.c
@@ -423,9 +423,7 @@ asmlinkage int solaris_procids(int cmd, s32 pid, s32 pgid)
423 Solaris setpgrp and setsid? */ 423 Solaris setpgrp and setsid? */
424 ret = sys_setpgid(0, 0); 424 ret = sys_setpgid(0, 0);
425 if (ret) return ret; 425 if (ret) return ret;
426 mutex_lock(&tty_mutex); 426 proc_clear_tty(current);
427 current->signal->tty = NULL;
428 mutex_unlock(&tty_mutex);
429 return process_group(current); 427 return process_group(current);
430 } 428 }
431 case 2: /* getsid */ 429 case 2: /* getsid */
diff --git a/arch/um/kernel/exec.c b/arch/um/kernel/exec.c
index 0561c43b4685..8d56ec6cca79 100644
--- a/arch/um/kernel/exec.c
+++ b/arch/um/kernel/exec.c
@@ -39,12 +39,13 @@ static long execve1(char *file, char __user * __user *argv,
39 char __user *__user *env) 39 char __user *__user *env)
40{ 40{
41 long error; 41 long error;
42 struct tty_struct *tty;
42 43
43#ifdef CONFIG_TTY_LOG 44#ifdef CONFIG_TTY_LOG
44 mutex_lock(&tty_mutex); 45 mutex_lock(&tty_mutex);
45 task_lock(current); /* FIXME: is this needed ? */ 46 tty = get_current_tty();
46 log_exec(argv, current->signal->tty); 47 if (tty)
47 task_unlock(current); 48 log_exec(argv, tty);
48 mutex_unlock(&tty_mutex); 49 mutex_unlock(&tty_mutex);
49#endif 50#endif
50 error = do_execve(file, argv, env, &current->thread.regs); 51 error = do_execve(file, argv, env, &current->thread.regs);