mbedtls: provide user mode access
The mbedtls library has some globals which results in faults when user mode tries to access them. Instantiate a memory partition for mbedtls's globals. The linker will place all globals found by building this library into this partition. Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
parent
62fad96802
commit
e686aefe09
7 changed files with 40 additions and 4 deletions
17
include/app_memory/partitions.h
Normal file
17
include/app_memory/partitions.h
Normal file
|
@ -0,0 +1,17 @@
|
|||
/*
|
||||
* Copyright (c) 2019 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
#ifndef ZEPHYR_APP_MEMORY_PARTITIONS_H
|
||||
#define ZEPHYR_APP_MEMORY_PARTITIONS_H
|
||||
|
||||
#ifdef CONFIG_USERSPACE
|
||||
#include <kernel.h> /* For struct k_mem_partition */
|
||||
|
||||
#if defined(CONFIG_MBEDTLS)
|
||||
extern struct k_mem_partition k_mbedtls_partition;
|
||||
#endif /* CONFIG_MBEDTLS */
|
||||
#endif /* CONFIG_USERSPACE */
|
||||
#endif /* ZEPHYR_APP_MEMORY_PARTITIONS_H */
|
Loading…
Add table
Add a link
Reference in a new issue