summaryrefslogtreecommitdiff
path: root/src/arch/riscv/include/arch/pmp.h
blob: b25fc965bcdbbcbddd5eea1b650f806f34277757 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/* SPDX-License-Identifier: GPL-2.0-only */

#ifndef __RISCV_PMP_H__
#define __RISCV_PMP_H__

#include <stdint.h>

/*
 * this function needs to be implemented by a specific SoC.
 * return number of PMP entries for current hart
 */
int pmp_entries_num(void);

/* reset PMP setting */
void reset_pmp(void);

/* set up PMP record */
void setup_pmp(uintptr_t base, uintptr_t size, uintptr_t flags);

#endif /* __RISCV_PMP_H__ */