Marc Moreno Berengue | 8e0fa7a | 2018-10-04 18:25:13 +0100 | [diff] [blame] | 1 | /* |
Tamas Kaman | 262dc7b | 2019-03-20 13:37:12 +0100 | [diff] [blame^] | 2 | * Copyright (c) 2018-2019, Arm Limited. All rights reserved. |
Marc Moreno Berengue | 8e0fa7a | 2018-10-04 18:25:13 +0100 | [diff] [blame] | 3 | * |
| 4 | * SPDX-License-Identifier: BSD-3-Clause |
| 5 | * |
| 6 | */ |
| 7 | |
| 8 | #ifndef __TFM_PLATFORM_SYSTEM_H__ |
| 9 | #define __TFM_PLATFORM_SYSTEM_H__ |
| 10 | /** |
| 11 | * \note The interfaces defined in this file must be implemented for each |
| 12 | * target. |
| 13 | */ |
| 14 | |
| 15 | #include "tfm_plat_defs.h" |
Tamas Kaman | 262dc7b | 2019-03-20 13:37:12 +0100 | [diff] [blame^] | 16 | #include "psa_client.h" |
| 17 | #include "tfm_plat_defs.h" |
Marc Moreno Berengue | 8e0fa7a | 2018-10-04 18:25:13 +0100 | [diff] [blame] | 18 | |
| 19 | #ifdef __cplusplus |
| 20 | extern "C" { |
| 21 | #endif |
| 22 | |
| 23 | /** |
| 24 | * \brief Resets the system. |
| 25 | * |
| 26 | * \details Requests a system reset to reset the MCU. |
| 27 | */ |
| 28 | TFM_LINK_SET_OBJECT_IN_PARTITION_SECTION("TFM_SP_PLATFORM") |
| 29 | void tfm_platform_hal_system_reset(void); |
| 30 | |
Tamas Kaman | 262dc7b | 2019-03-20 13:37:12 +0100 | [diff] [blame^] | 31 | /*! |
| 32 | * \brief Performs pin services of the platform |
| 33 | * |
| 34 | * \param[in] in_vec Pointer to in_vec array, which contains input |
| 35 | * arguments for the pin service |
| 36 | * \param[in] num_invec Number of elements in in_vec array |
| 37 | * \param[in,out] out_vec Pointer out_vec array, which contains output data |
| 38 | * of the pin service |
| 39 | * \param[in] num_outvec Number of elements in out_vec array |
| 40 | * |
| 41 | * \return Returns values as specified by the \ref tfm_plat_err_t |
| 42 | */ |
| 43 | TFM_LINK_SET_OBJECT_IN_PARTITION_SECTION("TFM_SP_PLATFORM") |
| 44 | enum tfm_plat_err_t |
| 45 | tfm_platform_hal_pin_service(const psa_invec *in_vec, uint32_t num_invec, |
| 46 | const psa_outvec *out_vec, uint32_t num_outvec); |
| 47 | |
Marc Moreno Berengue | 8e0fa7a | 2018-10-04 18:25:13 +0100 | [diff] [blame] | 48 | #ifdef __cplusplus |
| 49 | } |
| 50 | #endif |
| 51 | |
| 52 | #endif /* __TFM_PLATFORM_SYSTEM_H__ */ |