1 
2 /*
3  * Arm SCP/MCP Software
4  * Copyright (c) 2018-2023, Arm Limited and Contributors. All rights reserved.
5  *
6  * SPDX-License-Identifier: BSD-3-Clause
7  */
8 
9 #ifndef MOD_APCONTEXT_H
10 #define MOD_APCONTEXT_H
11 
12 #include <fwk_id.h>
13 
14 #include <stddef.h>
15 #include <stdint.h>
16 
17 /*!
18  * \ingroup GroupModules Modules
19  * \defgroup GroupModuleAPContext AP Context
20  *
21  * \brief Application Processor (AP) context module.
22  *
23  * \details This module implements the AP context zero-initialization.
24  * \{
25  */
26 
27 /*!
28  * \brief Platform notification source and notification id
29  *
30  * \details On platforms that require platform configuration (in addition to
31  *      the clock configuration) to access the AP context memory region, the
32  *      platform notification can be subscribed. This is optional for a platform
33  *      and if provided as module configuration data, the AP context memory
34  *      region will be accessed only after this notification is processed.
35  */
36 struct mod_transport_platform_notification {
37     /*! Identifier of the notification id */
38     const fwk_id_t notification_id;
39 
40     /*! Identifier of the module sending the notification */
41     const fwk_id_t source_id;
42 };
43 
44 /*!
45  * \brief AP context configuration data
46  */
47 struct mod_apcontext_config {
48     /*! Base address of the AP context */
49     uintptr_t base;
50 
51     /*! Size of the AP context */
52     size_t size;
53 
54     /*! Identifier of the clock this module depends on */
55     fwk_id_t clock_id;
56 
57     /*!
58      * Platform notification source and notification id (optional)
59      */
60     struct mod_transport_platform_notification platform_notification;
61 };
62 
63 /*!
64  * \}
65  */
66 
67 #endif /* MOD_APCONTEXT_H */
68