2006-10-01 14:28:55 +08:00
|
|
|
/*
|
|
|
|
* tsacct_kern.h - kernel header for system accounting over taskstats interface
|
|
|
|
*
|
|
|
|
* Copyright (C) Jay Lan SGI
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef _LINUX_TSACCT_KERN_H
|
|
|
|
#define _LINUX_TSACCT_KERN_H
|
|
|
|
|
|
|
|
#include <linux/taskstats.h>
|
|
|
|
|
|
|
|
#ifdef CONFIG_TASKSTATS
|
2012-02-08 09:56:49 +08:00
|
|
|
extern void bacct_add_tsk(struct user_namespace *user_ns,
|
|
|
|
struct pid_namespace *pid_ns,
|
|
|
|
struct taskstats *stats, struct task_struct *tsk);
|
2006-10-01 14:28:55 +08:00
|
|
|
#else
|
2012-02-08 09:56:49 +08:00
|
|
|
static inline void bacct_add_tsk(struct user_namespace *user_ns,
|
|
|
|
struct pid_namespace *pid_ns,
|
|
|
|
struct taskstats *stats, struct task_struct *tsk)
|
2006-10-01 14:28:55 +08:00
|
|
|
{}
|
|
|
|
#endif /* CONFIG_TASKSTATS */
|
|
|
|
|
2006-10-01 14:28:58 +08:00
|
|
|
#ifdef CONFIG_TASK_XACCT
|
|
|
|
extern void xacct_add_tsk(struct taskstats *stats, struct task_struct *p);
|
2006-10-01 14:28:59 +08:00
|
|
|
extern void acct_update_integrals(struct task_struct *tsk);
|
2012-11-13 21:20:55 +08:00
|
|
|
extern void acct_account_cputime(struct task_struct *tsk);
|
2006-10-01 14:28:59 +08:00
|
|
|
extern void acct_clear_integrals(struct task_struct *tsk);
|
2006-10-01 14:28:58 +08:00
|
|
|
#else
|
|
|
|
static inline void xacct_add_tsk(struct taskstats *stats, struct task_struct *p)
|
|
|
|
{}
|
2006-10-01 14:28:59 +08:00
|
|
|
static inline void acct_update_integrals(struct task_struct *tsk)
|
|
|
|
{}
|
2012-11-13 21:20:55 +08:00
|
|
|
static inline void acct_account_cputime(struct task_struct *tsk)
|
|
|
|
{}
|
2006-10-01 14:28:59 +08:00
|
|
|
static inline void acct_clear_integrals(struct task_struct *tsk)
|
|
|
|
{}
|
2006-10-01 14:28:58 +08:00
|
|
|
#endif /* CONFIG_TASK_XACCT */
|
|
|
|
|
2006-10-01 14:28:55 +08:00
|
|
|
#endif
|
2006-10-01 14:28:58 +08:00
|
|
|
|
|
|
|
|