/* * This is the header file for user programs to receive signals * on VM events. Use it ONLY with the vmsig-patched kernel * (linux-2.6.13-vmsig). The vmsig_register(flag) system call is * used to tell the kernel which VM events you want to receive * signals on. * * Yi Feng */ #ifndef __LINUX_VMSIG_H #define __LINUX_VMSIG_H #include #include /* The signal number we use - this is a real-time signal. */ #define SIGVM 35 /* The VM events you can specify in vmsig_register(). */ #define VM_EVICTING_CLEAN 0x1 #define VM_EVICTING_DIRTY 0x2 #define VM_SWAPPED_OUT 0x4 #define VM_FAULTED_IN 0x8 #define VM_PREFETCHED 0x10 /* * A new advice flag for madvise() that lets the kernel swap out * the specified pages under memory pressure. If these pages don't * contain useful data, the user should use madvise() with the * MADV_DONTNEED flag. */ #define MADV_RELINQUISH 0x5 /* The system call interface. */ #define __NR_vmsig_register 294 _syscall1(long, vmsig_register, unsigned int, flag) #endif