1 /* 2 * Arm SCP/MCP Software 3 * Copyright (c) 2017-2022, Arm Limited and Contributors. All rights reserved. 4 * 5 * SPDX-License-Identifier: BSD-3-Clause 6 * 7 * Description: 8 * Message Handling Unit (MHU) v2 Device Driver. 9 */ 10 11 #ifndef MOD_MHU2_H 12 #define MOD_MHU2_H 13 14 #include <fwk_macros.h> 15 16 #include <stdint.h> 17 18 /*! 19 * \addtogroup GroupModules Modules 20 * \{ 21 */ 22 23 /*! 24 * \defgroup GroupMHUv2 Message Handling Unit (MHU) v2 Driver 25 * \{ 26 */ 27 28 /*! 29 * \brief MHU v2 api indicies 30 */ 31 enum mod_mhu2_api_idx { 32 /*! TRANSPORT driver API */ 33 MOD_MHU2_API_IDX_TRANSPORT_DRIVER, 34 /*! Number of APIs */ 35 MOD_MHU2_API_IDX_COUNT, 36 }; 37 38 /*! 39 * \brief MHU v2 device 40 * 41 * \details Abstract representation of a bidirectional MHU channel that consists 42 * of a single receive interrupt line and a pair of register sets, one for 43 * each direction of communication. 44 */ 45 struct mod_mhu2_channel_config { 46 /*! IRQ number of the receive interrupt line */ 47 unsigned int irq; 48 49 /*! Base address of the registers of the incoming MHU */ 50 uintptr_t recv; 51 52 /*! Base address of the registers of the outgoing MHU */ 53 uintptr_t send; 54 55 /*! Channel number for the channel to be used as doorbell */ 56 unsigned int channel; 57 }; 58 59 /*! 60 * \} 61 */ 62 63 /*! 64 * \} 65 */ 66 67 #endif /* MOD_MHU2_H */ 68