linux/kernel/delayacct.c

// SPDX-License-Identifier: GPL-2.0-or-later
/* delayacct.c - per-task delay accounting
 *
 * Copyright (C) Shailabh Nagar, IBM Corp. 2006
 */

#include <linux/sched.h>
#include <linux/sched/task.h>
#include <linux/sched/cputime.h>
#include <linux/sched/clock.h>
#include <linux/slab.h>
#include <linux/taskstats.h>
#include <linux/sysctl.h>
#include <linux/delayacct.h>
#include <linux/module.h>

DEFINE_STATIC_KEY_FALSE(delayacct_key);
int delayacct_on __read_mostly;	/* Delay accounting turned on/off */
struct kmem_cache *delayacct_cache;

static void set_delayacct(bool enabled)
{}

static int __init delayacct_setup_enable(char *str)
{}
__setup();

void delayacct_init(void)
{}

#ifdef CONFIG_PROC_SYSCTL
static int sysctl_delayacct(const struct ctl_table *table, int write, void *buffer,
		     size_t *lenp, loff_t *ppos)
{}

static struct ctl_table kern_delayacct_table[] =;

static __init int kernel_delayacct_sysctls_init(void)
{}
late_initcall(kernel_delayacct_sysctls_init);
#endif

void __delayacct_tsk_init(struct task_struct *tsk)
{}

/*
 * Finish delay accounting for a statistic using its timestamps (@start),
 * accumalator (@total) and @count
 */
static void delayacct_end(raw_spinlock_t *lock, u64 *start, u64 *total, u32 *count)
{}

void __delayacct_blkio_start(void)
{}

/*
 * We cannot rely on the `current` macro, as we haven't yet switched back to
 * the process being woken.
 */
void __delayacct_blkio_end(struct task_struct *p)
{}

int delayacct_add_tsk(struct taskstats *d, struct task_struct *tsk)
{}

__u64 __delayacct_blkio_ticks(struct task_struct *tsk)
{}

void __delayacct_freepages_start(void)
{}

void __delayacct_freepages_end(void)
{}

void __delayacct_thrashing_start(bool *in_thrashing)
{}

void __delayacct_thrashing_end(bool *in_thrashing)
{}

void __delayacct_swapin_start(void)
{}

void __delayacct_swapin_end(void)
{}

void __delayacct_compact_start(void)
{}

void __delayacct_compact_end(void)
{}

void __delayacct_wpcopy_start(void)
{}

void __delayacct_wpcopy_end(void)
{}

void __delayacct_irq(struct task_struct *task, u32 delta)
{}