@@ -421,7 +421,7 @@ const void *z_vrfy_mod_fast_get(struct processing_module *mod, const void * cons
421421 struct module_resources * res = & mod -> priv .resources ;
422422
423423 K_OOPS (K_SYSCALL_MEMORY_WRITE (mod , sizeof (* mod )));
424- K_OOPS (K_SYSCALL_MEMORY_WRITE (res -> heap , sizeof ( * res -> heap ) ));
424+ K_OOPS (K_SYSCALL_MEMORY_WRITE (res -> heap -> heap . init_mem , res -> heap -> heap . init_bytes ));
425425 K_OOPS (K_SYSCALL_MEMORY_READ (dram_ptr , size ));
426426
427427 return z_impl_mod_fast_get (mod , dram_ptr , size );
@@ -435,7 +435,7 @@ void *z_vrfy_mod_alloc_ext(struct processing_module *mod, uint32_t flags, size_t
435435 struct module_resources * res = & mod -> priv .resources ;
436436
437437 K_OOPS (K_SYSCALL_MEMORY_WRITE (mod , sizeof (* mod )));
438- K_OOPS (K_SYSCALL_MEMORY_WRITE (res -> heap , sizeof ( * res -> heap ) ));
438+ K_OOPS (K_SYSCALL_MEMORY_WRITE (res -> heap -> heap . init_mem , res -> heap -> heap . init_bytes ));
439439
440440 return z_impl_mod_alloc_ext (mod , flags , size , alignment );
441441}
@@ -446,7 +446,7 @@ int z_vrfy_mod_free(struct processing_module *mod, const void *ptr)
446446 struct module_resources * res = & mod -> priv .resources ;
447447
448448 K_OOPS (K_SYSCALL_MEMORY_WRITE (mod , sizeof (* mod )));
449- K_OOPS (K_SYSCALL_MEMORY_WRITE (res -> heap , sizeof ( * res -> heap ) ));
449+ K_OOPS (K_SYSCALL_MEMORY_WRITE (res -> heap -> heap . init_mem , res -> heap -> heap . init_bytes ));
450450
451451 return z_impl_mod_free (mod , ptr );
452452}
0 commit comments