On Tue, 2008-03-25 at 19:33 +0300, Oleg Nesterov wrote:Yes, you're right. My patch only works OK in the ptrace_notify() case, not when it is called from get_signal_to_deliver(). So, do you think it's a better idea to add a new flag to notify the tracee that its tracer disappeared? That way it can decide how to handle the situation in ptrace_stop(), something along these lines: --- a/kernel/signal.c +++ b/kernel/signal.c @@ -1628,6 +1628,8 @@ ptrace_stop(int exit_code, int c do_notify_parent_cldstop(current, CLD_TRAPPED); read_unlock(&tasklist_lock); schedule(); + if (current->flags & PF_PTRACEORPHAN & clear_code) + current->exit_code = 0; } else { /* * By the time we got the lock, our tracer went away. And then replace p->exit_code = 0 in my original patch with something like p->flags |= PF_PTRACEORPHAN. Better? Cheers, Petr Tesarik --
| Tomasz Kłoczko | Is it time for remove (crap) ALSA from kernel tree ? |
| Aubrey | O_DIRECT question |
| David Miller | Slow DOWN, please!!! |
| Linus Torvalds | Linux 2.6.27-rc8 |
git: | |
| Francis Moreau | emacs and git... |
| Linus Torvalds | I'm a total push-over.. |
| Keith Packard | Re: parsecvs tool now creates git repositories |
| Andreas Hildebrandt | CVS-$Id:$ replacement in git? |
| Jason Dixon | Wasting our Freedom |
| Richard Stallman | Real men don't attack straw men |
| Edwin Eyan Moragas | poll(2) vs kqueue(2) performance |
| James Hartley | scp batch mode? |
| Chris Peterson | [PATCH] drivers/net: remove network drivers' last few uses of IRQF_SAMPLE_RANDOM |
| Karen Xie | [RFC][PATCH 1/1] cxgb3i: cxgb3 iSCSI initiator |
| Lennert Buytenhek | [PATCH 14/39] mv643xx_eth: remove port serial status register bit defines |
| Andrew Morton | Re: [Bugme-new] [Bug 11036] New: atl1 tx busy and hw csum wrong |
| high memory | 2 hours ago | Linux kernel |
| semaphore access speed | 5 hours ago | Applications and Utilities |
| the kernel how to power off the machine | 6 hours ago | Linux kernel |
| Easter Eggs in windows XP | 9 hours ago | Windows |
| Shared swap partition | 10 hours ago | Linux general |
| Root password | 10 hours ago | Linux general |
| Where/when DNOTIFY is used? | 12 hours ago | Linux kernel |
| How to convert Linux Kernel built-in module into a loadable module | 14 hours ago | Linux kernel |
| Linux 2.6.24 and I/O schedulers | 15 hours ago | Linux kernel |
| USB Driver -- Interrupt Polling -- A Little Help Please | 20 hours ago | Linux general |
