xref: /optee_os/core/include/drivers/stm32mp2_rcc_util.h (revision b0323341ea4bb6d3410882fb4ce2dcea3666802c)
111ece294SGabriel Fernandez /* SPDX-License-Identifier: BSD-2-Clause */
211ece294SGabriel Fernandez /*
311ece294SGabriel Fernandez  * Copyright (C) STMicroelectronics 2024 - All Rights Reserved
411ece294SGabriel Fernandez  */
511ece294SGabriel Fernandez 
611ece294SGabriel Fernandez #ifndef __DRIVERS_STM32MP2_RCC_UTIL_H__
711ece294SGabriel Fernandez #define __DRIVERS_STM32MP2_RCC_UTIL_H__
811ece294SGabriel Fernandez 
928c10f9eSGabriel Fernandez #include <drivers/clk.h>
10*b0323341SGabriel Fernandez #include <drivers/rstctrl.h>
1111ece294SGabriel Fernandez #include <types_ext.h>
1211ece294SGabriel Fernandez 
1311ece294SGabriel Fernandez /* Return RCC base address */
1411ece294SGabriel Fernandez vaddr_t stm32_rcc_base(void);
1511ece294SGabriel Fernandez 
1628c10f9eSGabriel Fernandez /* Return the clock handle related to a clock DT binding ID */
1728c10f9eSGabriel Fernandez struct clk *stm32mp_rcc_clock_id_to_clk(unsigned long clock_id);
1828c10f9eSGabriel Fernandez 
19*b0323341SGabriel Fernandez /* Return rstctrl instance related to RCC reset controller DT binding ID */
20*b0323341SGabriel Fernandez struct rstctrl *stm32mp_rcc_reset_id_to_rstctrl(unsigned int binding_id);
21*b0323341SGabriel Fernandez 
2211ece294SGabriel Fernandez #endif /*__DRIVERS_STM32MP2_RCC_UTIL_H__*/
23