FreeBSD kernel kern code
kern_racct.c File Reference
#include <sys/cdefs.h>
#include "opt_kdtrace.h"
#include "opt_sched.h"
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/eventhandler.h>
#include <sys/jail.h>
#include <sys/kernel.h>
#include <sys/kthread.h>
#include <sys/lock.h>
#include <sys/loginclass.h>
#include <sys/malloc.h>
#include <sys/mutex.h>
#include <sys/proc.h>
#include <sys/racct.h>
#include <sys/resourcevar.h>
#include <sys/sbuf.h>
#include <sys/sched.h>
#include <sys/sdt.h>
#include <sys/smp.h>
#include <sys/sx.h>
#include <sys/sysctl.h>
#include <sys/sysent.h>
#include <sys/sysproto.h>
#include <sys/umtx.h>
#include <machine/smp.h>
Include dependency graph for kern_racct.c:

Go to the source code of this file.

Functions

 __FBSDID ("$BSDSUniX$")
 
int racct_add (struct proc *p, int resource, uint64_t amount)
 
void racct_add_cred (struct ucred *cred, int resource, uint64_t amount)
 
void racct_add_force (struct proc *p, int resource, uint64_t amount)
 
int racct_set (struct proc *p, int resource, uint64_t amount)
 
void racct_set_force (struct proc *p, int resource, uint64_t amount)
 
void racct_sub (struct proc *p, int resource, uint64_t amount)
 
void racct_sub_cred (struct ucred *cred, int resource, uint64_t amount)
 
uint64_t racct_get_limit (struct proc *p, int resource)
 
uint64_t racct_get_available (struct proc *p, int resource)
 
void racct_create (struct racct **racctp)
 
void racct_destroy (struct racct **racctp)
 
int racct_proc_fork (struct proc *parent, struct proc *child)
 
void racct_proc_fork_done (struct proc *child)
 
void racct_proc_exit (struct proc *p)
 

Function Documentation

__FBSDID ( "$BSDSUniX$"  )
int racct_add ( struct proc *  p,
int  resource,
uint64_t  amount 
)

Definition at line 1208 of file kern_racct.c.

Referenced by coredump(), create_thread(), kern_msgsnd(), pts_alloc(), pts_alloc_external(), shmget_allocate_segment(), sys_msgget(), and sys_semget().

Here is the caller graph for this function:

void racct_add_cred ( struct ucred *  cred,
int  resource,
uint64_t  amount 
)

Definition at line 1215 of file kern_racct.c.

void racct_add_force ( struct proc *  p,
int  resource,
uint64_t  amount 
)

Definition at line 1220 of file kern_racct.c.

Referenced by proc0_init().

Here is the caller graph for this function:

void racct_create ( struct racct **  racctp)

Definition at line 1263 of file kern_racct.c.

Referenced by loginclass_find(), prison_racct_find_locked(), proc0_init(), and uifind().

Here is the caller graph for this function:

void racct_destroy ( struct racct **  racctp)

Definition at line 1268 of file kern_racct.c.

Referenced by loginclass_find(), loginclass_free(), prison_racct_free_locked(), uifind(), and uifree().

Here is the caller graph for this function:

uint64_t racct_get_available ( struct proc *  p,
int  resource 
)

Definition at line 1256 of file kern_racct.c.

Referenced by coredump(), and sys_semop().

Here is the caller graph for this function:

uint64_t racct_get_limit ( struct proc *  p,
int  resource 
)

Definition at line 1249 of file kern_racct.c.

Referenced by sys_getdtablesize().

Here is the caller graph for this function:

void racct_proc_exit ( struct proc *  p)

Definition at line 1285 of file kern_racct.c.

Referenced by fork1(), and proc_reap().

Here is the caller graph for this function:

int racct_proc_fork ( struct proc *  parent,
struct proc *  child 
)

Definition at line 1273 of file kern_racct.c.

Referenced by fork1().

Here is the caller graph for this function:

void racct_proc_fork_done ( struct proc *  child)

Definition at line 1280 of file kern_racct.c.

Referenced by fork1().

Here is the caller graph for this function:

int racct_set ( struct proc *  p,
int  resource,
uint64_t  amount 
)

Definition at line 1227 of file kern_racct.c.

Referenced by do_aout_hdr(), do_dup(), exec_aout_imgact(), fdalloc(), and fdfree().

Here is the caller graph for this function:

void racct_set_force ( struct proc *  p,
int  resource,
uint64_t  amount 
)

Definition at line 1234 of file kern_racct.c.

void racct_sub ( struct proc *  p,
int  resource,
uint64_t  amount 
)

Definition at line 1239 of file kern_racct.c.

Referenced by create_thread(), exit1(), kern_msgsnd(), proc_reap(), pts_alloc(), pts_alloc_external(), shmget_allocate_segment(), and sys_thr_exit().

Here is the caller graph for this function:

void racct_sub_cred ( struct ucred *  cred,
int  resource,
uint64_t  amount 
)

Definition at line 1244 of file kern_racct.c.

Referenced by kern_msgctl(), kern_msgrcv(), kern_semctl(), ptsdrv_free(), and shm_deallocate_segment().

Here is the caller graph for this function: