From: "Rafael J. Wysocki" This patch from Pavel moves userland freeze signals handling into more logical place. It now hits even with mysqld running. Signed-off-by: Rafael J. Wysocki Signed-off-by: Pavel Machek Signed-off-by: Andrew Morton --- arch/i386/kernel/signal.c | 4 ---- arch/x86_64/kernel/signal.c | 4 ---- kernel/signal.c | 3 ++- 3 files changed, 2 insertions(+), 9 deletions(-) diff -puN arch/i386/kernel/signal.c~swsusp-finally-solve-mysqld-problem arch/i386/kernel/signal.c --- devel/arch/i386/kernel/signal.c~swsusp-finally-solve-mysqld-problem 2006-02-23 19:41:06.000000000 -0800 +++ devel-akpm/arch/i386/kernel/signal.c 2006-02-23 19:41:06.000000000 -0800 @@ -583,9 +583,6 @@ static void fastcall do_signal(struct pt if (!user_mode(regs)) return; - if (try_to_freeze()) - goto no_signal; - if (test_thread_flag(TIF_RESTORE_SIGMASK)) oldset = ¤t->saved_sigmask; else @@ -614,7 +611,6 @@ static void fastcall do_signal(struct pt return; } -no_signal: /* Did we come from a system call? */ if (regs->orig_eax >= 0) { /* Restart the system call - no handlers present */ diff -puN arch/x86_64/kernel/signal.c~swsusp-finally-solve-mysqld-problem arch/x86_64/kernel/signal.c --- devel/arch/x86_64/kernel/signal.c~swsusp-finally-solve-mysqld-problem 2006-02-23 19:41:06.000000000 -0800 +++ devel-akpm/arch/x86_64/kernel/signal.c 2006-02-23 19:41:06.000000000 -0800 @@ -443,9 +443,6 @@ int do_signal(struct pt_regs *regs, sigs if (!user_mode(regs)) return 1; - if (try_to_freeze()) - goto no_signal; - if (!oldset) oldset = ¤t->blocked; @@ -463,7 +460,6 @@ int do_signal(struct pt_regs *regs, sigs return handle_signal(signr, &info, &ka, oldset, regs); } - no_signal: /* Did we come from a system call? */ if ((long)regs->orig_rax >= 0) { /* Restart the system call - no handlers present */ diff -puN kernel/signal.c~swsusp-finally-solve-mysqld-problem kernel/signal.c --- devel/kernel/signal.c~swsusp-finally-solve-mysqld-problem 2006-02-23 19:41:06.000000000 -0800 +++ devel-akpm/kernel/signal.c 2006-02-23 19:41:06.000000000 -0800 @@ -1922,6 +1922,8 @@ int get_signal_to_deliver(siginfo_t *inf sigset_t *mask = ¤t->blocked; int signr = 0; + try_to_freeze(); + relock: spin_lock_irq(¤t->sighand->siglock); for (;;) { @@ -2307,7 +2309,6 @@ sys_rt_sigtimedwait(const sigset_t __use timeout = schedule_timeout_interruptible(timeout); - try_to_freeze(); spin_lock_irq(¤t->sighand->siglock); sig = dequeue_signal(current, &these, &info); current->blocked = current->real_blocked; _