2022-02-11 07:30:54 +00:00
|
|
|
/*
|
2023-07-07 09:35:29 +00:00
|
|
|
* SPDX-FileCopyrightText: 2010-2023 Espressif Systems (Shanghai) CO LTD
|
2022-02-11 07:30:54 +00:00
|
|
|
*
|
|
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
|
|
*/
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
2022-09-23 09:28:36 +00:00
|
|
|
#include "esp_bit_defs.h"
|
2022-02-11 07:30:54 +00:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2022-09-23 09:28:36 +00:00
|
|
|
typedef enum {
|
|
|
|
MMU_MEM_CAP_EXEC = BIT(0),
|
|
|
|
MMU_MEM_CAP_READ = BIT(1),
|
|
|
|
MMU_MEM_CAP_WRITE = BIT(2),
|
|
|
|
MMU_MEM_CAP_32BIT = BIT(3),
|
|
|
|
MMU_MEM_CAP_8BIT = BIT(4),
|
|
|
|
} mmu_mem_caps_t;
|
|
|
|
|
2022-02-11 07:30:54 +00:00
|
|
|
/**
|
|
|
|
* MMU Page size
|
|
|
|
*/
|
|
|
|
typedef enum {
|
2023-02-13 11:12:44 +00:00
|
|
|
MMU_PAGE_8KB = 0x2000,
|
2022-06-01 02:14:48 +00:00
|
|
|
MMU_PAGE_16KB = 0x4000,
|
|
|
|
MMU_PAGE_32KB = 0x8000,
|
|
|
|
MMU_PAGE_64KB = 0x10000,
|
2022-02-11 07:30:54 +00:00
|
|
|
} mmu_page_size_t;
|
|
|
|
|
2022-08-18 06:00:46 +00:00
|
|
|
/**
|
2023-02-13 11:12:44 +00:00
|
|
|
* MMU virtual address flags type
|
2022-08-18 06:00:46 +00:00
|
|
|
*/
|
|
|
|
typedef enum {
|
2023-02-13 11:12:44 +00:00
|
|
|
MMU_VADDR_DATA = BIT(0),
|
|
|
|
MMU_VADDR_INSTRUCTION = BIT(1),
|
2022-08-18 06:00:46 +00:00
|
|
|
} mmu_vaddr_t;
|
|
|
|
|
2022-02-11 07:30:54 +00:00
|
|
|
/**
|
|
|
|
* External physical memory
|
|
|
|
*/
|
|
|
|
typedef enum {
|
2022-11-02 11:11:45 +00:00
|
|
|
MMU_TARGET_FLASH0 = BIT(0),
|
|
|
|
MMU_TARGET_PSRAM0 = BIT(1),
|
2022-02-11 07:30:54 +00:00
|
|
|
} mmu_target_t;
|
|
|
|
|
2022-04-18 07:04:10 +00:00
|
|
|
/**
|
|
|
|
* MMU table id
|
|
|
|
*/
|
|
|
|
typedef enum {
|
|
|
|
MMU_TABLE_CORE0,
|
|
|
|
MMU_TABLE_CORE1,
|
|
|
|
} mmu_table_id_t;
|
|
|
|
|
2022-02-11 07:30:54 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|