1 /* 2 * Arm SCP/MCP Software 3 * Copyright (c) 2018-2021, Arm Limited and Contributors. All rights reserved. 4 * 5 * SPDX-License-Identifier: BSD-3-Clause 6 */ 7 8 #ifndef FWK_INTERNAL_NOTIFICATION_H 9 #define FWK_INTERNAL_NOTIFICATION_H 10 11 #include <fwk_list.h> 12 #include <fwk_notification.h> 13 14 #include <stdbool.h> 15 #include <stddef.h> 16 17 struct __fwk_notification_subscription { 18 struct fwk_dlist_node dlist_node; 19 20 /* Identifier of the notification source entity. */ 21 fwk_id_t source_id; 22 23 /* Identifier of the notification target entity. */ 24 fwk_id_t target_id; 25 }; 26 27 /* 28 * \brief Initialize the notification framework component. 29 * 30 * \param notification_count The maximum number of notification subscriptions at 31 * any time. 32 * 33 * \retval ::FWK_SUCCESS The notification framework component was initialized. 34 * \retval ::FWK_E_PARAM The maximum number of notification subscriptions is 35 * equal to zero. 36 * \retval ::FWK_E_NOMEM Insufficient memory available to allocate the 37 * notification subscription. 38 */ 39 int __fwk_notification_init(size_t notification_count); 40 41 /* 42 * \brief Reset the notification framework component. 43 * 44 * \note Only for testing. 45 */ 46 void __fwk_notification_reset(void); 47 48 #endif /* FWK_INTERNAL_NOTIFICATION_H */ 49