@@ -39,6 +39,13 @@ config OCRE_WAMR_HEAP_BUFFER_SIZE
3939 help
4040 A static memory allocation for WAMR to use as a heap.
4141
42+ config OCRE_STORAGE_HEAP_BUFFER_SIZE
43+ int "Storage heap buffer size in bytes"
44+ default 500000
45+ depends on MEMC
46+ help
47+ A static memory allocation for container storage to use as a heap.
48+
4249config OCRE_CONTAINER_DEFAULT_HEAP_SIZE
4350 int "Default value for the container heap size"
4451 default 4096
@@ -217,5 +224,53 @@ config OCRE_NETWORKING
217224 default n
218225 help
219226 Enable networking support for containers.
220-
227+
228+ config OCRE_SHARED_HEAP
229+ bool "Enable container shared heap support"
230+ default n
231+ help
232+ Enable shared heap support for containers.
233+
234+ config OCRE_SHARED_HEAP_BUF_SIZE
235+ int "Shared heap buffer size in bytes"
236+ default 65536
237+ depends on OCRE_SHARED_HEAP
238+ help
239+ Size of the pre-allocated buffer for the shared heap.
240+ This memory is shared between WebAssembly modules.
241+
242+ choice OCRE_SHARED_HEAP_MODE
243+ prompt "Shared heap mode"
244+ depends on OCRE_SHARED_HEAP
245+ default OCRE_SHARED_HEAP_BUF_VIRTUAL
246+ help
247+ Select the shared heap memory mode:
248+ - Physical: Map physical hardware registers (e.g., GPIO) to WASM address space
249+ - Virtual: Allocate shared heap from regular RAM
250+
251+ config OCRE_SHARED_HEAP_BUF_PHYSICAL
252+ bool "Physical (hardware register mapping)"
253+ help
254+ Enable physical memory mapping for hardware access.
255+ Maps physical hardware registers (like GPIO at 0x42020000) to WASM address space.
256+ Use this when containers need direct access to hardware peripherals.
257+
258+ config OCRE_SHARED_HEAP_BUF_VIRTUAL
259+ bool "Virtual (RAM allocation)"
260+ help
261+ Enable virtual shared heap allocated from regular RAM.
262+ Use this for normal inter-module communication without
263+ direct hardware access.
264+
265+ endchoice
266+
267+ config OCRE_SHARED_HEAP_BUF_ADDRESS
268+ hex "Shared heap buffer address"
269+ default 0x00
270+ depends on OCRE_SHARED_HEAP
271+ help
272+ Shared heap buffer address.
273+ - For physical mode: Physical address of hardware registers
274+ - For virtual mode: Leave as 0x00 to auto-allocate from RAM
275+
221276endmenu
0 commit comments