aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/fork.c
diff options
context:
space:
mode:
authorAl Viro <viro@parcelfarce.linux.theplanet.co.uk>2005-11-13 19:06:55 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2005-11-13 21:14:13 -0500
commita1261f54611ec4ad6a7ab7080f86747e3ac3685b (patch)
tree8a65c419da590e3712543f69284fb5f8cd613a37 /kernel/fork.c
parent7feacd53347c04aee789ba5d632eda0c3fc421c4 (diff)
[PATCH] m68k: introduce task_thread_info
new helper - task_thread_info(task). On platforms that have thread_info allocated separately (i.e. in default case) it simply returns task->thread_info. m68k wants (and for good reasons) to embed its thread_info into task_struct. So it will (in later patch) have task_thread_info() of its own. For now we just add a macro for generic case and convert existing instances of its body in core kernel to uses of new macro. Obviously safe - all normal architectures get the same preprocessor output they used to get. Signed-off-by: Al Viro <viro@parcelfarce.linux.theplanet.co.uk> Signed-off-by: Roman Zippel <zippel@linux-m68k.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'kernel/fork.c')
-rw-r--r--kernel/fork.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/fork.c b/kernel/fork.c
index 158710d22566..7ef352ce347b 100644
--- a/kernel/fork.c
+++ b/kernel/fork.c
@@ -919,7 +919,7 @@ static task_t *copy_process(unsigned long clone_flags,
919 if (nr_threads >= max_threads) 919 if (nr_threads >= max_threads)
920 goto bad_fork_cleanup_count; 920 goto bad_fork_cleanup_count;
921 921
922 if (!try_module_get(p->thread_info->exec_domain->module)) 922 if (!try_module_get(task_thread_info(p)->exec_domain->module))
923 goto bad_fork_cleanup_count; 923 goto bad_fork_cleanup_count;
924 924
925 if (p->binfmt && !try_module_get(p->binfmt->module)) 925 if (p->binfmt && !try_module_get(p->binfmt->module))
@@ -1180,7 +1180,7 @@ bad_fork_cleanup:
1180 if (p->binfmt) 1180 if (p->binfmt)
1181 module_put(p->binfmt->module); 1181 module_put(p->binfmt->module);
1182bad_fork_cleanup_put_domain: 1182bad_fork_cleanup_put_domain:
1183 module_put(p->thread_info->exec_domain->module); 1183 module_put(task_thread_info(p)->exec_domain->module);
1184bad_fork_cleanup_count: 1184bad_fork_cleanup_count:
1185 put_group_info(p->group_info); 1185 put_group_info(p->group_info);
1186 atomic_dec(&p->user->processes); 1186 atomic_dec(&p->user->processes);