linux/mm/execmem.c

// SPDX-License-Identifier: GPL-2.0
/*
 * Copyright (C) 2002 Richard Henderson
 * Copyright (C) 2001 Rusty Russell, 2002, 2010 Rusty Russell IBM.
 * Copyright (C) 2023 Luis Chamberlain <[email protected]>
 * Copyright (C) 2024 Mike Rapoport IBM.
 */

#include <linux/mm.h>
#include <linux/vmalloc.h>
#include <linux/execmem.h>
#include <linux/moduleloader.h>

static struct execmem_info *execmem_info __ro_after_init;
static struct execmem_info default_execmem_info __ro_after_init;

static void *__execmem_alloc(struct execmem_range *range, size_t size)
{}

void *execmem_alloc(enum execmem_type type, size_t size)
{}

void execmem_free(void *ptr)
{}

static bool execmem_validate(struct execmem_info *info)
{}

static void execmem_init_missing(struct execmem_info *info)
{}

struct execmem_info * __weak execmem_arch_setup(void)
{}

static void __init __execmem_init(void)
{}

#ifdef CONFIG_ARCH_WANTS_EXECMEM_LATE
static int __init execmem_late_init(void)
{
	__execmem_init();
	return 0;
}
core_initcall(execmem_late_init);
#else
void __init execmem_init(void)
{}
#endif