blob: 5331dbb067d681c7a44d7d4038d9654f60d28d2b [file] [log] [blame]
Raef Coles237af692022-07-20 10:36:43 +01001/*
2 * Copyright (c) 2020-2022, Arm Limited. All rights reserved.
3 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 *
6 */
7
8/* Interop between TF-M fih.h and mcuboot fault_injection_hardening.h, so that
9 * platform code can target fih.h and for bl2 this will be redirected to
10 * fault_injection_hardening.h
11 */
12
13#ifndef __INTEROP_FIH_H__
14#define __INTEROP_FIH_H__
15
16#ifdef __cplusplus
17extern "C" {
18#endif /* __cplusplus */
19
20#include "stdint.h"
21
Raef Coles237af692022-07-20 10:36:43 +010022/*
23 * FIH return type macro changes the function return types to fih_int.
24 * All functions that need to be protected by FIH and called via FIH_CALL must
25 * return a fih_int type.
26 */
27#define FIH_RET_TYPE(type) fih_int
28
29#include "bootutil/fault_injection_hardening.h"
30
Raef Coles237af692022-07-20 10:36:43 +010031#ifdef __cplusplus
32}
33#endif /* __cplusplus */
34
35#endif /* __INTEROP_FIH_H__ */