#include <linux/mm.h>
#include <linux/interrupt.h>
#include <linux/syscalls.h>
#include <linux/time.h>
#include <linux/sched/signal.h>
#include <linux/sched/cputime.h>
#include <linux/posix-timers.h>
#include <linux/hrtimer.h>
#include <trace/events/timer.h>
#include <linux/compat.h>
#include <linux/uaccess.h>
static struct timespec64 itimer_get_remtime(struct hrtimer *timer)
{ … }
static void get_cpu_itimer(struct task_struct *tsk, unsigned int clock_id,
struct itimerspec64 *const value)
{ … }
static int do_getitimer(int which, struct itimerspec64 *value)
{ … }
static int put_itimerval(struct __kernel_old_itimerval __user *o,
const struct itimerspec64 *i)
{ … }
SYSCALL_DEFINE2(getitimer, int, which, struct __kernel_old_itimerval __user *, value)
{ … }
#if defined(CONFIG_COMPAT) || defined(CONFIG_ALPHA)
struct old_itimerval32 { … };
static int put_old_itimerval32(struct old_itimerval32 __user *o,
const struct itimerspec64 *i)
{ … }
COMPAT_SYSCALL_DEFINE2(getitimer, int, which,
struct old_itimerval32 __user *, value)
{ … }
#endif
enum hrtimer_restart it_real_fn(struct hrtimer *timer)
{ … }
static void set_cpu_itimer(struct task_struct *tsk, unsigned int clock_id,
const struct itimerspec64 *const value,
struct itimerspec64 *const ovalue)
{ … }
#define timeval_valid(t) …
static int do_setitimer(int which, struct itimerspec64 *value,
struct itimerspec64 *ovalue)
{ … }
#ifdef CONFIG_SECURITY_SELINUX
void clear_itimer(void)
{ … }
#endif
#ifdef __ARCH_WANT_SYS_ALARM
static unsigned int alarm_setitimer(unsigned int seconds)
{ … }
SYSCALL_DEFINE1(alarm, unsigned int, seconds)
{ … }
#endif
static int get_itimerval(struct itimerspec64 *o, const struct __kernel_old_itimerval __user *i)
{ … }
SYSCALL_DEFINE3(setitimer, int, which, struct __kernel_old_itimerval __user *, value,
struct __kernel_old_itimerval __user *, ovalue)
{ … }
#if defined(CONFIG_COMPAT) || defined(CONFIG_ALPHA)
static int get_old_itimerval32(struct itimerspec64 *o, const struct old_itimerval32 __user *i)
{ … }
COMPAT_SYSCALL_DEFINE3(setitimer, int, which,
struct old_itimerval32 __user *, value,
struct old_itimerval32 __user *, ovalue)
{ … }
#endif