xref: /netbsd-src/sys/external/gpl2/dts/dist/include/dt-bindings/mfd/stm32f7-rcc.h (revision a2acc37588a86b7bc7e3ea5039a71b9c3a9dcc30)
1*a2acc375Sjmcneill /*	$NetBSD: stm32f7-rcc.h,v 1.1.1.3 2018/04/28 18:25:53 jmcneill Exp $	*/
263341816Sjmcneill 
36cafeaffSjmcneill /* SPDX-License-Identifier: GPL-2.0 */
463341816Sjmcneill /*
563341816Sjmcneill  * This header provides constants for the STM32F7 RCC IP
663341816Sjmcneill  */
763341816Sjmcneill 
863341816Sjmcneill #ifndef _DT_BINDINGS_MFD_STM32F7_RCC_H
963341816Sjmcneill #define _DT_BINDINGS_MFD_STM32F7_RCC_H
1063341816Sjmcneill 
1163341816Sjmcneill /* AHB1 */
1263341816Sjmcneill #define STM32F7_RCC_AHB1_GPIOA		0
1363341816Sjmcneill #define STM32F7_RCC_AHB1_GPIOB		1
1463341816Sjmcneill #define STM32F7_RCC_AHB1_GPIOC		2
1563341816Sjmcneill #define STM32F7_RCC_AHB1_GPIOD		3
1663341816Sjmcneill #define STM32F7_RCC_AHB1_GPIOE		4
1763341816Sjmcneill #define STM32F7_RCC_AHB1_GPIOF		5
1863341816Sjmcneill #define STM32F7_RCC_AHB1_GPIOG		6
1963341816Sjmcneill #define STM32F7_RCC_AHB1_GPIOH		7
2063341816Sjmcneill #define STM32F7_RCC_AHB1_GPIOI		8
2163341816Sjmcneill #define STM32F7_RCC_AHB1_GPIOJ		9
2263341816Sjmcneill #define STM32F7_RCC_AHB1_GPIOK		10
2363341816Sjmcneill #define STM32F7_RCC_AHB1_CRC		12
2463341816Sjmcneill #define STM32F7_RCC_AHB1_BKPSRAM	18
2563341816Sjmcneill #define STM32F7_RCC_AHB1_DTCMRAM	20
2663341816Sjmcneill #define STM32F7_RCC_AHB1_DMA1		21
2763341816Sjmcneill #define STM32F7_RCC_AHB1_DMA2		22
2863341816Sjmcneill #define STM32F7_RCC_AHB1_DMA2D		23
2963341816Sjmcneill #define STM32F7_RCC_AHB1_ETHMAC		25
3063341816Sjmcneill #define STM32F7_RCC_AHB1_ETHMACTX	26
3163341816Sjmcneill #define STM32F7_RCC_AHB1_ETHMACRX	27
3263341816Sjmcneill #define STM32FF_RCC_AHB1_ETHMACPTP	28
3363341816Sjmcneill #define STM32F7_RCC_AHB1_OTGHS		29
3463341816Sjmcneill #define STM32F7_RCC_AHB1_OTGHSULPI	30
3563341816Sjmcneill 
3663341816Sjmcneill #define STM32F7_AHB1_RESET(bit) (STM32F7_RCC_AHB1_##bit + (0x10 * 8))
3763341816Sjmcneill #define STM32F7_AHB1_CLOCK(bit) (STM32F7_RCC_AHB1_##bit)
3863341816Sjmcneill 
3963341816Sjmcneill 
4063341816Sjmcneill /* AHB2 */
4163341816Sjmcneill #define STM32F7_RCC_AHB2_DCMI		0
4263341816Sjmcneill #define STM32F7_RCC_AHB2_CRYP		4
4363341816Sjmcneill #define STM32F7_RCC_AHB2_HASH		5
4463341816Sjmcneill #define STM32F7_RCC_AHB2_RNG		6
4563341816Sjmcneill #define STM32F7_RCC_AHB2_OTGFS		7
4663341816Sjmcneill 
4763341816Sjmcneill #define STM32F7_AHB2_RESET(bit)	(STM32F7_RCC_AHB2_##bit + (0x14 * 8))
4863341816Sjmcneill #define STM32F7_AHB2_CLOCK(bit)	(STM32F7_RCC_AHB2_##bit + 0x20)
4963341816Sjmcneill 
5063341816Sjmcneill /* AHB3 */
5163341816Sjmcneill #define STM32F7_RCC_AHB3_FMC		0
5263341816Sjmcneill #define STM32F7_RCC_AHB3_QSPI		1
5363341816Sjmcneill 
5463341816Sjmcneill #define STM32F7_AHB3_RESET(bit)	(STM32F7_RCC_AHB3_##bit + (0x18 * 8))
5563341816Sjmcneill #define STM32F7_AHB3_CLOCK(bit)	(STM32F7_RCC_AHB3_##bit + 0x40)
5663341816Sjmcneill 
5763341816Sjmcneill /* APB1 */
5863341816Sjmcneill #define STM32F7_RCC_APB1_TIM2		0
5963341816Sjmcneill #define STM32F7_RCC_APB1_TIM3		1
6063341816Sjmcneill #define STM32F7_RCC_APB1_TIM4		2
6163341816Sjmcneill #define STM32F7_RCC_APB1_TIM5		3
6263341816Sjmcneill #define STM32F7_RCC_APB1_TIM6		4
6363341816Sjmcneill #define STM32F7_RCC_APB1_TIM7		5
6463341816Sjmcneill #define STM32F7_RCC_APB1_TIM12		6
6563341816Sjmcneill #define STM32F7_RCC_APB1_TIM13		7
6663341816Sjmcneill #define STM32F7_RCC_APB1_TIM14		8
6763341816Sjmcneill #define STM32F7_RCC_APB1_LPTIM1		9
6863341816Sjmcneill #define STM32F7_RCC_APB1_WWDG		11
6963341816Sjmcneill #define STM32F7_RCC_APB1_SPI2		14
7063341816Sjmcneill #define STM32F7_RCC_APB1_SPI3		15
7163341816Sjmcneill #define STM32F7_RCC_APB1_SPDIFRX	16
7263341816Sjmcneill #define STM32F7_RCC_APB1_UART2		17
7363341816Sjmcneill #define STM32F7_RCC_APB1_UART3		18
7463341816Sjmcneill #define STM32F7_RCC_APB1_UART4		19
7563341816Sjmcneill #define STM32F7_RCC_APB1_UART5		20
7663341816Sjmcneill #define STM32F7_RCC_APB1_I2C1		21
7763341816Sjmcneill #define STM32F7_RCC_APB1_I2C2		22
7863341816Sjmcneill #define STM32F7_RCC_APB1_I2C3		23
7963341816Sjmcneill #define STM32F7_RCC_APB1_I2C4		24
8063341816Sjmcneill #define STM32F7_RCC_APB1_CAN1		25
8163341816Sjmcneill #define STM32F7_RCC_APB1_CAN2		26
8263341816Sjmcneill #define STM32F7_RCC_APB1_CEC		27
8363341816Sjmcneill #define STM32F7_RCC_APB1_PWR		28
8463341816Sjmcneill #define STM32F7_RCC_APB1_DAC		29
8563341816Sjmcneill #define STM32F7_RCC_APB1_UART7		30
8663341816Sjmcneill #define STM32F7_RCC_APB1_UART8		31
8763341816Sjmcneill 
8863341816Sjmcneill #define STM32F7_APB1_RESET(bit)	(STM32F7_RCC_APB1_##bit + (0x20 * 8))
8963341816Sjmcneill #define STM32F7_APB1_CLOCK(bit)	(STM32F7_RCC_APB1_##bit + 0x80)
9063341816Sjmcneill 
9163341816Sjmcneill /* APB2 */
9263341816Sjmcneill #define STM32F7_RCC_APB2_TIM1		0
9363341816Sjmcneill #define STM32F7_RCC_APB2_TIM8		1
9463341816Sjmcneill #define STM32F7_RCC_APB2_USART1		4
9563341816Sjmcneill #define STM32F7_RCC_APB2_USART6		5
96*a2acc375Sjmcneill #define STM32F7_RCC_APB2_SDMMC2		7
9763341816Sjmcneill #define STM32F7_RCC_APB2_ADC1		8
9863341816Sjmcneill #define STM32F7_RCC_APB2_ADC2		9
9963341816Sjmcneill #define STM32F7_RCC_APB2_ADC3		10
10063341816Sjmcneill #define STM32F7_RCC_APB2_SDMMC1		11
10163341816Sjmcneill #define STM32F7_RCC_APB2_SPI1		12
10263341816Sjmcneill #define STM32F7_RCC_APB2_SPI4		13
10363341816Sjmcneill #define STM32F7_RCC_APB2_SYSCFG		14
10463341816Sjmcneill #define STM32F7_RCC_APB2_TIM9		16
10563341816Sjmcneill #define STM32F7_RCC_APB2_TIM10		17
10663341816Sjmcneill #define STM32F7_RCC_APB2_TIM11		18
10763341816Sjmcneill #define STM32F7_RCC_APB2_SPI5		20
10863341816Sjmcneill #define STM32F7_RCC_APB2_SPI6		21
10963341816Sjmcneill #define STM32F7_RCC_APB2_SAI1		22
11063341816Sjmcneill #define STM32F7_RCC_APB2_SAI2		23
11163341816Sjmcneill #define STM32F7_RCC_APB2_LTDC		26
11263341816Sjmcneill 
11363341816Sjmcneill #define STM32F7_APB2_RESET(bit)	(STM32F7_RCC_APB2_##bit + (0x24 * 8))
11463341816Sjmcneill #define STM32F7_APB2_CLOCK(bit)	(STM32F7_RCC_APB2_##bit + 0xA0)
11563341816Sjmcneill 
11663341816Sjmcneill #endif /* _DT_BINDINGS_MFD_STM32F7_RCC_H */
117