#include "lkdtm.h"
#include <linux/slab.h>
#include <linux/vmalloc.h>
#include <linux/mman.h>
#include <linux/uaccess.h>
#include <asm/cacheflush.h>
#include <asm/sections.h>
#define CODE_WRITE …
#define CODE_AS_IS …
#define EXEC_SIZE …
static u8 data_area[EXEC_SIZE];
static const unsigned long rodata = …;
static unsigned long ro_after_init __ro_after_init = …;
static noinline void do_nothing(void)
{ … }
static noinline void do_overwritten(void)
{ … }
static noinline void do_almost_nothing(void)
{ … }
static void *setup_function_descriptor(func_desc_t *fdesc, void *dst)
{ … }
static noinline __nocfi void execute_location(void *dst, bool write)
{ … }
static void execute_user_location(void *dst)
{ … }
static void lkdtm_WRITE_RO(void)
{ … }
static void lkdtm_WRITE_RO_AFTER_INIT(void)
{ … }
static void lkdtm_WRITE_KERN(void)
{ … }
static void lkdtm_WRITE_OPD(void)
{ … }
static void lkdtm_EXEC_DATA(void)
{ … }
static void lkdtm_EXEC_STACK(void)
{ … }
static void lkdtm_EXEC_KMALLOC(void)
{ … }
static void lkdtm_EXEC_VMALLOC(void)
{ … }
static void lkdtm_EXEC_RODATA(void)
{ … }
static void lkdtm_EXEC_USERSPACE(void)
{ … }
static void lkdtm_EXEC_NULL(void)
{ … }
static void lkdtm_ACCESS_USERSPACE(void)
{ … }
static void lkdtm_ACCESS_NULL(void)
{ … }
void __init lkdtm_perms_init(void)
{ … }
static struct crashtype crashtypes[] = …;
struct crashtype_category perms_crashtypes = …;