mirror of
https://github.com/apache/nuttx.git
synced 2026-09-11 03:16:45 +00:00
mm/pgalloc: support 32 KB and 64 KB page sizes
Add CONFIG_MM_PGSIZE == 32768 and 65536 to the page-size switch (and the Kconfig help text). The 64 KB size matches the ESP32-S3 cache-MMU page granularity, so an address-environment port there can use one mm_pgalloc() page per cache-MMU page (naturally 64 KB-aligned by the granule allocator) instead of coalescing several smaller pages. Inert for existing configs: MM_PGSIZE is only used when CONFIG_MM_PGALLOC is enabled (BUILD_KERNEL). Assisted-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Signed-off-by: Marco Casaroli <marco.casaroli@gmail.com>
This commit is contained in:
parent
a3d4802ff8
commit
4770f7b46c
2 changed files with 10 additions and 3 deletions
|
|
@ -69,6 +69,12 @@
|
|||
#elif CONFIG_MM_PGSIZE == 16384
|
||||
# define MM_PGSIZE 16384
|
||||
# define MM_PGSHIFT 14
|
||||
#elif CONFIG_MM_PGSIZE == 32768
|
||||
# define MM_PGSIZE 32768
|
||||
# define MM_PGSHIFT 15
|
||||
#elif CONFIG_MM_PGSIZE == 65536
|
||||
# define MM_PGSIZE 65536
|
||||
# define MM_PGSHIFT 16
|
||||
#else
|
||||
# error CONFIG_MM_PGSIZE not supported
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -301,9 +301,10 @@ config MM_PGSIZE
|
|||
int "Page Size"
|
||||
default 4096
|
||||
---help---
|
||||
The MMU page size. Must be one of {1024, 2048, 4096, 8192, or
|
||||
16384}. This is easily extensible, but only those values are
|
||||
currently support.
|
||||
The MMU page size. Must be one of {1024, 2048, 4096, 8192, 16384,
|
||||
32768, or 65536}. This is easily extensible, but only those values
|
||||
are currently support. 64 KB (65536) matches the ESP32-S3 cache-MMU
|
||||
page size.
|
||||
|
||||
config DEBUG_PGALLOC
|
||||
bool "Page Allocator Debug"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue