aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVeaceslav Falico <vfalico@redhat.com>2010-03-10 18:23:02 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2010-03-12 18:52:39 -0500
commit4dd66e69d472f0ba5355a2529364d0db9a18a02b (patch)
treeb0ea53215bbe61d678090385018de64821eb6831
parenta56704ef6b0c5796c9ff38cc78aa232dfb9644d7 (diff)
copy_signal() cleanup: kill taskstats_tgid_init() and acct_init_pacct()
Kill unused functions taskstats_tgid_init() and acct_init_pacct() because we don't use them anywhere after using kmem_cache_zalloc() in copy_signal(). Signed-off-by: Veaceslav Falico <vfalico@redhat.com> Cc: Roland McGrath <roland@redhat.com> Cc: Oleg Nesterov <oleg@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--include/linux/acct.h2
-rw-r--r--include/linux/taskstats_kern.h7
-rw-r--r--kernel/acct.c10
3 files changed, 0 insertions, 19 deletions
diff --git a/include/linux/acct.h b/include/linux/acct.h
index 882dc7248766..93f46096ad4c 100644
--- a/include/linux/acct.h
+++ b/include/linux/acct.h
@@ -123,14 +123,12 @@ struct pacct_struct;
123struct pid_namespace; 123struct pid_namespace;
124extern void acct_auto_close_mnt(struct vfsmount *m); 124extern void acct_auto_close_mnt(struct vfsmount *m);
125extern void acct_auto_close(struct super_block *sb); 125extern void acct_auto_close(struct super_block *sb);
126extern void acct_init_pacct(struct pacct_struct *pacct);
127extern void acct_collect(long exitcode, int group_dead); 126extern void acct_collect(long exitcode, int group_dead);
128extern void acct_process(void); 127extern void acct_process(void);
129extern void acct_exit_ns(struct pid_namespace *); 128extern void acct_exit_ns(struct pid_namespace *);
130#else 129#else
131#define acct_auto_close_mnt(x) do { } while (0) 130#define acct_auto_close_mnt(x) do { } while (0)
132#define acct_auto_close(x) do { } while (0) 131#define acct_auto_close(x) do { } while (0)
133#define acct_init_pacct(x) do { } while (0)
134#define acct_collect(x,y) do { } while (0) 132#define acct_collect(x,y) do { } while (0)
135#define acct_process() do { } while (0) 133#define acct_process() do { } while (0)
136#define acct_exit_ns(ns) do { } while (0) 134#define acct_exit_ns(ns) do { } while (0)
diff --git a/include/linux/taskstats_kern.h b/include/linux/taskstats_kern.h
index 3398f4553269..b6523c1427ce 100644
--- a/include/linux/taskstats_kern.h
+++ b/include/linux/taskstats_kern.h
@@ -14,11 +14,6 @@
14extern struct kmem_cache *taskstats_cache; 14extern struct kmem_cache *taskstats_cache;
15extern struct mutex taskstats_exit_mutex; 15extern struct mutex taskstats_exit_mutex;
16 16
17static inline void taskstats_tgid_init(struct signal_struct *sig)
18{
19 sig->stats = NULL;
20}
21
22static inline void taskstats_tgid_free(struct signal_struct *sig) 17static inline void taskstats_tgid_free(struct signal_struct *sig)
23{ 18{
24 if (sig->stats) 19 if (sig->stats)
@@ -30,8 +25,6 @@ extern void taskstats_init_early(void);
30#else 25#else
31static inline void taskstats_exit(struct task_struct *tsk, int group_dead) 26static inline void taskstats_exit(struct task_struct *tsk, int group_dead)
32{} 27{}
33static inline void taskstats_tgid_init(struct signal_struct *sig)
34{}
35static inline void taskstats_tgid_free(struct signal_struct *sig) 28static inline void taskstats_tgid_free(struct signal_struct *sig)
36{} 29{}
37static inline void taskstats_init_early(void) 30static inline void taskstats_init_early(void)
diff --git a/kernel/acct.c b/kernel/acct.c
index a6605ca921b6..24f8c81fc48d 100644
--- a/kernel/acct.c
+++ b/kernel/acct.c
@@ -588,16 +588,6 @@ out:
588} 588}
589 589
590/** 590/**
591 * acct_init_pacct - initialize a new pacct_struct
592 * @pacct: per-process accounting info struct to initialize
593 */
594void acct_init_pacct(struct pacct_struct *pacct)
595{
596 memset(pacct, 0, sizeof(struct pacct_struct));
597 pacct->ac_utime = pacct->ac_stime = cputime_zero;
598}
599
600/**
601 * acct_collect - collect accounting information into pacct_struct 591 * acct_collect - collect accounting information into pacct_struct
602 * @exitcode: task exit code 592 * @exitcode: task exit code
603 * @group_dead: not 0, if this thread is the last one in the process. 593 * @group_dead: not 0, if this thread is the last one in the process.