Zephyr Project API 4.3.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
pmp.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2025 Google LLC
3 *
4 * SPDX-License-Identifier: Apache-2.0
5 */
6
7#ifndef ZEPHYR_INCLUDE_RISCV_PMP_H_
8#define ZEPHYR_INCLUDE_RISCV_PMP_H_
9
12
26 const void *start;
28 const void *end;
31};
32
45#define PMP_SOC_REGION_DEFINE(name, _start, _end, _perm) \
46 static const STRUCT_SECTION_ITERABLE(pmp_soc_region, name) = { \
47 .start = (const void *)(_start), \
48 .end = (const void *)(_end), \
49 .perm = (_perm), \
50 }
51
77int z_riscv_pmp_change_permissions(size_t region_idx, uint8_t perm);
78
90void z_riscv_pmp_clear_all(void);
91
92#endif /* ZEPHYR_INCLUDE_RISCV_PMP_H_ */
RISCV specific kernel interface header.
__UINT8_TYPE__ uint8_t
Definition stdint.h:88
SoC-specific PMP region descriptor.
Definition pmp.h:24
const void * end
End address of the region (exclusive)
Definition pmp.h:28
uint8_t perm
PMP permission flags (PMP_R, PMP_W, PMP_X combinations)
Definition pmp.h:30
const void * start
Start address of the region (must be aligned to PMP granularity)
Definition pmp.h:26