summaryrefslogtreecommitdiffstats
path: root/kernel/exit.c
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>1997-09-12 01:29:55 +0000
committerRalf Baechle <ralf@linux-mips.org>1997-09-12 01:29:55 +0000
commit545f435ebcfd94a1e7c20b46efe81b4d6ac4e698 (patch)
treee9ce4bc598d06374bda906f18365984bf22a526a /kernel/exit.c
parent4291a610eef89d0d5c69d9a10ee6560e1aa36c74 (diff)
Merge with Linux 2.1.55. More bugfixes and goodies from my private
CVS archive.
Diffstat (limited to 'kernel/exit.c')
-rw-r--r--kernel/exit.c15
1 files changed, 4 insertions, 11 deletions
diff --git a/kernel/exit.c b/kernel/exit.c
index 23f0da655..922449fc6 100644
--- a/kernel/exit.c
+++ b/kernel/exit.c
@@ -446,13 +446,7 @@ static inline void __exit_mm(struct task_struct * tsk)
tsk->mm = &init_mm;
tsk->swappable = 0;
SET_PAGE_DIR(tsk, swapper_pg_dir);
-
- /* free the old state - not used any more */
- if (!--mm->count) {
- exit_mmap(mm);
- free_page_tables(mm);
- kmem_cache_free(mm_cachep, mm);
- }
+ mmput(mm);
}
}
@@ -504,7 +498,8 @@ static void exit_notify(void)
p->p_pptr = p->p_opptr;
p->p_osptr = p->p_pptr->p_cptr;
- p->p_osptr->p_ysptr = p;
+ if (p->p_osptr)
+ p->p_osptr->p_ysptr = p;
p->p_pptr->p_cptr = p;
if (p->state == TASK_ZOMBIE)
notify_parent(p, p->exit_signal);
@@ -528,10 +523,8 @@ static void exit_notify(void)
NORET_TYPE void do_exit(long code)
{
- if (in_interrupt()) {
- local_irq_count[smp_processor_id()] = 0; /* Not really correct */
+ if (in_interrupt())
printk("Aiee, killing interrupt handler\n");
- }
fake_volatile:
acct_process(code);
current->flags |= PF_EXITING;