• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // SPDX-License-Identifier: GPL-2.0-or-later
2 /*
3  * Copyright (c) 2023 Huawei Device Co., Ltd.
4  */
5 
6 #ifndef _JIT_MEMORY_H
7 #define _JIT_MEMORY_H
8 
9 #include <linux/sched.h>
10 #include "jit_space_list.h"
11 #include "jit_process.h"
12 
13 extern void find_jit_memory(struct task_struct *task, unsigned long start, unsigned long size, int *err);
14 extern void check_jit_memory(struct task_struct *task, unsigned long cookie, unsigned long prot,
15 	unsigned long flag, unsigned long size, unsigned long *err);
16 extern void delete_jit_memory(struct task_struct *task, unsigned long start, unsigned long size, int *err);
17 extern void exit_jit_memory(struct task_struct *task);
18 
19 static bool jit_avc_has_perm(u16 tclass, u32 requested, struct task_struct *task);
20 
21 #endif //_JIT_MEMORY_H