1 /*
2  * Copyright (c) 2024, Arm Limited. All rights reserved.
3  *
4  * SPDX-License-Identifier: BSD-3-Clause
5  *
6  */
7 
8 #ifndef __NI_TOWER_UTIL_H__
9 #define __NI_TOWER_UTIL_H__
10 
11 #include "ni_tower_drv.h"
12 #include <stdint.h>
13 
14 /**
15  * \brief Check if a region overlaps with another
16  *
17  * \param[in]   region_base_1   Region 1 base address.
18  * \param[in]   region_end_1    Region 1 end address.
19  * \param[in]   region_base_2   Region 2 base address.
20  * \param[in]   region_end_2    Region 2 end address.
21  *
22  * \return Returns NI_TOWER_ERR_REGION_OVERLAPS is the region overlaps, else
23  * NI_TOWER_SUCCESS as specified in \ref ni_tower_err
24  */
25 enum ni_tower_err ni_tower_check_region_overlaps(uint64_t region_base_1,
26                                                  uint64_t region_end_1,
27                                                  uint64_t region_base_2,
28                                                  uint64_t region_end_2);
29 
30 
31 #endif /* __NI_TOWER_UTIL_H__ */
32