| 1 |
/* SPDX-License-Identifier: GPL-2.0 */ |
| 2 |
/* |
| 3 |
* Copyright (C) 2022 Xilinx, Inc. |
| 4 |
*/ |
| 5 |
#ifndef _XILINX_MB_MANAGER_H |
| 6 |
#define _XILINX_MB_MANAGER_H |
| 7 |
|
| 8 |
# ifndef __ASSEMBLER__ |
| 9 |
|
| 10 |
#include <linux/of_address.h> |
| 11 |
|
| 12 |
/* |
| 13 |
* When the break vector gets asserted because of error injection, the break |
| 14 |
* signal must be blocked before exiting from the break handler, Below api |
| 15 |
* updates the manager address and control register and error counter callback |
| 16 |
* arguments, which will be used by the break handler to block the break and |
| 17 |
* call the callback function. |
| 18 |
*/ |
| 19 |
void xmb_manager_register(uintptr_t phys_baseaddr, u32 cr_val, |
| 20 |
void (*callback)(void *data), |
| 21 |
void *priv, void (*reset_callback)(void *data)); |
| 22 |
asmlinkage void xmb_inject_err(void); |
| 23 |
|
| 24 |
# endif /* __ASSEMBLER__ */ |
| 25 |
|
| 26 |
/* Error injection offset */ |
| 27 |
#define XMB_INJECT_ERR_OFFSET 0x200 |
| 28 |
|
| 29 |
#endif /* _XILINX_MB_MANAGER_H */ |