191 lines
12 KiB
C
191 lines
12 KiB
C
/* SPDX-License-Identifier: Apache-2.0 */
|
|
|
|
/* SoC level DTS fixup file */
|
|
|
|
#define DT_NUM_IRQ_PRIO_BITS DT_ARM_V6M_NVIC_E000E100_ARM_NUM_IRQ_PRIORITY_BITS
|
|
|
|
#define DT_GPIO_STM32_GPIOA_BASE_ADDRESS DT_ST_STM32_GPIO_48000000_BASE_ADDRESS
|
|
#define DT_GPIO_STM32_GPIOA_CLOCK_BITS_0 DT_ST_STM32_GPIO_48000000_CLOCK_BITS_0
|
|
#define DT_GPIO_STM32_GPIOA_CLOCK_BUS_0 DT_ST_STM32_GPIO_48000000_CLOCK_BUS_0
|
|
#define DT_GPIO_STM32_GPIOA_CLOCK_CONTROLLER DT_ST_STM32_GPIO_48000000_CLOCK_CONTROLLER
|
|
#define DT_GPIO_STM32_GPIOA_LABEL DT_ST_STM32_GPIO_48000000_LABEL
|
|
#define DT_GPIO_STM32_GPIOA_SIZE DT_ST_STM32_GPIO_48000000_SIZE
|
|
#define DT_GPIO_STM32_GPIOA_CLOCK_BITS DT_ST_STM32_GPIO_48000000_CLOCK_BITS
|
|
#define DT_GPIO_STM32_GPIOA_CLOCK_BUS DT_ST_STM32_GPIO_48000000_CLOCK_BUS
|
|
|
|
#define DT_GPIO_STM32_GPIOB_BASE_ADDRESS DT_ST_STM32_GPIO_48000400_BASE_ADDRESS
|
|
#define DT_GPIO_STM32_GPIOB_CLOCK_BITS_0 DT_ST_STM32_GPIO_48000400_CLOCK_BITS_0
|
|
#define DT_GPIO_STM32_GPIOB_CLOCK_BUS_0 DT_ST_STM32_GPIO_48000400_CLOCK_BUS_0
|
|
#define DT_GPIO_STM32_GPIOB_CLOCK_CONTROLLER DT_ST_STM32_GPIO_48000400_CLOCK_CONTROLLER
|
|
#define DT_GPIO_STM32_GPIOB_LABEL DT_ST_STM32_GPIO_48000400_LABEL
|
|
#define DT_GPIO_STM32_GPIOB_SIZE DT_ST_STM32_GPIO_48000400_SIZE
|
|
#define DT_GPIO_STM32_GPIOB_CLOCK_BITS DT_ST_STM32_GPIO_48000400_CLOCK_BITS
|
|
#define DT_GPIO_STM32_GPIOB_CLOCK_BUS DT_ST_STM32_GPIO_48000400_CLOCK_BUS
|
|
|
|
#define DT_GPIO_STM32_GPIOC_BASE_ADDRESS DT_ST_STM32_GPIO_48000800_BASE_ADDRESS
|
|
#define DT_GPIO_STM32_GPIOC_CLOCK_BITS_0 DT_ST_STM32_GPIO_48000800_CLOCK_BITS_0
|
|
#define DT_GPIO_STM32_GPIOC_CLOCK_BUS_0 DT_ST_STM32_GPIO_48000800_CLOCK_BUS_0
|
|
#define DT_GPIO_STM32_GPIOC_CLOCK_CONTROLLER DT_ST_STM32_GPIO_48000800_CLOCK_CONTROLLER
|
|
#define DT_GPIO_STM32_GPIOC_LABEL DT_ST_STM32_GPIO_48000800_LABEL
|
|
#define DT_GPIO_STM32_GPIOC_SIZE DT_ST_STM32_GPIO_48000800_SIZE
|
|
#define DT_GPIO_STM32_GPIOC_CLOCK_BITS DT_ST_STM32_GPIO_48000800_CLOCK_BITS
|
|
#define DT_GPIO_STM32_GPIOC_CLOCK_BUS DT_ST_STM32_GPIO_48000800_CLOCK_BUS
|
|
|
|
#define DT_GPIO_STM32_GPIOD_BASE_ADDRESS DT_ST_STM32_GPIO_48000C00_BASE_ADDRESS
|
|
#define DT_GPIO_STM32_GPIOD_CLOCK_BITS_0 DT_ST_STM32_GPIO_48000C00_CLOCK_BITS_0
|
|
#define DT_GPIO_STM32_GPIOD_CLOCK_BUS_0 DT_ST_STM32_GPIO_48000C00_CLOCK_BUS_0
|
|
#define DT_GPIO_STM32_GPIOD_CLOCK_CONTROLLER DT_ST_STM32_GPIO_48000C00_CLOCK_CONTROLLER
|
|
#define DT_GPIO_STM32_GPIOD_LABEL DT_ST_STM32_GPIO_48000C00_LABEL
|
|
#define DT_GPIO_STM32_GPIOD_SIZE DT_ST_STM32_GPIO_48000C00_SIZE
|
|
#define DT_GPIO_STM32_GPIOD_CLOCK_BITS DT_ST_STM32_GPIO_48000C00_CLOCK_BITS
|
|
#define DT_GPIO_STM32_GPIOD_CLOCK_BUS DT_ST_STM32_GPIO_48000C00_CLOCK_BUS
|
|
|
|
#define DT_GPIO_STM32_GPIOE_BASE_ADDRESS DT_ST_STM32_GPIO_48001000_BASE_ADDRESS
|
|
#define DT_GPIO_STM32_GPIOE_CLOCK_BITS_0 DT_ST_STM32_GPIO_48001000_CLOCK_BITS_0
|
|
#define DT_GPIO_STM32_GPIOE_CLOCK_BUS_0 DT_ST_STM32_GPIO_48001000_CLOCK_BUS_0
|
|
#define DT_GPIO_STM32_GPIOE_CLOCK_CONTROLLER DT_ST_STM32_GPIO_48001000_CLOCK_CONTROLLER
|
|
#define DT_GPIO_STM32_GPIOE_LABEL DT_ST_STM32_GPIO_48001000_LABEL
|
|
#define DT_GPIO_STM32_GPIOE_SIZE DT_ST_STM32_GPIO_48001000_SIZE
|
|
#define DT_GPIO_STM32_GPIOE_CLOCK_BITS DT_ST_STM32_GPIO_48001000_CLOCK_BITS
|
|
#define DT_GPIO_STM32_GPIOE_CLOCK_BUS DT_ST_STM32_GPIO_48001000_CLOCK_BUS
|
|
|
|
#define DT_GPIO_STM32_GPIOF_BASE_ADDRESS DT_ST_STM32_GPIO_48001400_BASE_ADDRESS
|
|
#define DT_GPIO_STM32_GPIOF_CLOCK_BITS_0 DT_ST_STM32_GPIO_48001400_CLOCK_BITS_0
|
|
#define DT_GPIO_STM32_GPIOF_CLOCK_BUS_0 DT_ST_STM32_GPIO_48001400_CLOCK_BUS_0
|
|
#define DT_GPIO_STM32_GPIOF_CLOCK_CONTROLLER DT_ST_STM32_GPIO_48001400_CLOCK_CONTROLLER
|
|
#define DT_GPIO_STM32_GPIOF_LABEL DT_ST_STM32_GPIO_48001400_LABEL
|
|
#define DT_GPIO_STM32_GPIOF_SIZE DT_ST_STM32_GPIO_48001400_SIZE
|
|
#define DT_GPIO_STM32_GPIOF_CLOCK_BITS DT_ST_STM32_GPIO_48001400_CLOCK_BITS
|
|
#define DT_GPIO_STM32_GPIOF_CLOCK_BUS DT_ST_STM32_GPIO_48001400_CLOCK_BUS
|
|
|
|
#define DT_UART_STM32_USART_1_BASE_ADDRESS DT_ST_STM32_USART_40013800_BASE_ADDRESS
|
|
#define DT_UART_STM32_USART_1_BAUD_RATE DT_ST_STM32_USART_40013800_CURRENT_SPEED
|
|
#define DT_UART_STM32_USART_1_IRQ_PRI DT_ST_STM32_USART_40013800_IRQ_0_PRIORITY
|
|
#define DT_UART_STM32_USART_1_NAME DT_ST_STM32_USART_40013800_LABEL
|
|
#define DT_USART_1_IRQ DT_ST_STM32_USART_40013800_IRQ_0
|
|
#define DT_UART_STM32_USART_1_CLOCK_BITS DT_ST_STM32_USART_40013800_CLOCK_BITS
|
|
#define DT_UART_STM32_USART_1_CLOCK_BUS DT_ST_STM32_USART_40013800_CLOCK_BUS
|
|
#define DT_UART_STM32_USART_1_HW_FLOW_CONTROL DT_ST_STM32_USART_40013800_HW_FLOW_CONTROL
|
|
|
|
#define DT_UART_STM32_USART_2_BASE_ADDRESS DT_ST_STM32_USART_40004400_BASE_ADDRESS
|
|
#define DT_UART_STM32_USART_2_BAUD_RATE DT_ST_STM32_USART_40004400_CURRENT_SPEED
|
|
#define DT_UART_STM32_USART_2_IRQ_PRI DT_ST_STM32_USART_40004400_IRQ_0_PRIORITY
|
|
#define DT_UART_STM32_USART_2_NAME DT_ST_STM32_USART_40004400_LABEL
|
|
#define DT_USART_2_IRQ DT_ST_STM32_USART_40004400_IRQ_0
|
|
#define DT_UART_STM32_USART_2_CLOCK_BITS DT_ST_STM32_USART_40004400_CLOCK_BITS
|
|
#define DT_UART_STM32_USART_2_CLOCK_BUS DT_ST_STM32_USART_40004400_CLOCK_BUS
|
|
#define DT_UART_STM32_USART_2_HW_FLOW_CONTROL DT_ST_STM32_USART_40004400_HW_FLOW_CONTROL
|
|
|
|
#define DT_I2C_1_BASE_ADDRESS DT_ST_STM32_I2C_V2_40005400_BASE_ADDRESS
|
|
#define DT_I2C_1_COMBINED_IRQ_PRI DT_ST_STM32_I2C_V2_40005400_IRQ_COMBINED_PRIORITY
|
|
#define CONFIG_I2C_1_NAME DT_ST_STM32_I2C_V2_40005400_LABEL
|
|
#define DT_I2C_1_COMBINED_IRQ DT_ST_STM32_I2C_V2_40005400_IRQ_COMBINED
|
|
#define DT_I2C_1_BITRATE DT_ST_STM32_I2C_V2_40005400_CLOCK_FREQUENCY
|
|
#define DT_I2C_1_CLOCK_BITS DT_ST_STM32_I2C_V2_40005400_CLOCK_BITS
|
|
#define DT_I2C_1_CLOCK_BUS DT_ST_STM32_I2C_V2_40005400_CLOCK_BUS
|
|
|
|
#define DT_I2C_2_BASE_ADDRESS DT_ST_STM32_I2C_V2_40005800_BASE_ADDRESS
|
|
#define DT_I2C_2_COMBINED_IRQ_PRI DT_ST_STM32_I2C_V2_40005800_IRQ_COMBINED_PRIORITY
|
|
#define CONFIG_I2C_2_NAME DT_ST_STM32_I2C_V2_40005800_LABEL
|
|
#define DT_I2C_2_COMBINED_IRQ DT_ST_STM32_I2C_V2_40005800_IRQ_COMBINED
|
|
#define DT_I2C_2_BITRATE DT_ST_STM32_I2C_V2_40005800_CLOCK_FREQUENCY
|
|
#define DT_I2C_2_CLOCK_BITS DT_ST_STM32_I2C_V2_40005800_CLOCK_BITS
|
|
#define DT_I2C_2_CLOCK_BUS DT_ST_STM32_I2C_V2_40005800_CLOCK_BUS
|
|
|
|
#define DT_SPI_1_BASE_ADDRESS DT_ST_STM32_SPI_FIFO_40013000_BASE_ADDRESS
|
|
#define DT_SPI_1_IRQ_PRI DT_ST_STM32_SPI_FIFO_40013000_IRQ_0_PRIORITY
|
|
#define DT_SPI_1_NAME DT_ST_STM32_SPI_FIFO_40013000_LABEL
|
|
#define DT_SPI_1_IRQ DT_ST_STM32_SPI_FIFO_40013000_IRQ_0
|
|
#define DT_SPI_1_CLOCK_BITS DT_ST_STM32_SPI_FIFO_40013000_CLOCK_BITS
|
|
#define DT_SPI_1_CLOCK_BUS DT_ST_STM32_SPI_FIFO_40013000_CLOCK_BUS
|
|
|
|
|
|
#define DT_SPI_2_BASE_ADDRESS DT_ST_STM32_SPI_FIFO_40003800_BASE_ADDRESS
|
|
#define DT_SPI_2_IRQ_PRI DT_ST_STM32_SPI_FIFO_40003800_IRQ_0_PRIORITY
|
|
#define DT_SPI_2_NAME DT_ST_STM32_SPI_FIFO_40003800_LABEL
|
|
#define DT_SPI_2_IRQ DT_ST_STM32_SPI_FIFO_40003800_IRQ_0
|
|
#define DT_SPI_2_CLOCK_BITS DT_ST_STM32_SPI_FIFO_40003800_CLOCK_BITS
|
|
#define DT_SPI_2_CLOCK_BUS DT_ST_STM32_SPI_FIFO_40003800_CLOCK_BUS
|
|
|
|
#define DT_CAN_1_BASE_ADDRESS DT_ST_STM32_CAN_40006400_BASE_ADDRESS
|
|
#define DT_CAN_1_BUS_SPEED DT_ST_STM32_CAN_40006400_BUS_SPEED
|
|
#define DT_CAN_1_NAME DT_ST_STM32_CAN_40006400_LABEL
|
|
#define DT_CAN_1_IRQ DT_ST_STM32_CAN_40006400_IRQ_0
|
|
#define DT_CAN_1_IRQ_PRIORITY DT_ST_STM32_CAN_40006400_IRQ_0_PRIORITY
|
|
#define DT_CAN_1_SJW DT_ST_STM32_CAN_40006400_SJW
|
|
#define DT_CAN_1_PROP_SEG_PHASE_SEG1 DT_ST_STM32_CAN_40006400_PROP_SEG_PHASE_SEG1
|
|
#define DT_CAN_1_PHASE_SEG2 DT_ST_STM32_CAN_40006400_PHASE_SEG2
|
|
#define DT_CAN_1_CLOCK_BUS DT_ST_STM32_CAN_40006400_CLOCK_BUS
|
|
#define DT_CAN_1_CLOCK_BITS DT_ST_STM32_CAN_40006400_CLOCK_BITS
|
|
|
|
#define DT_FLASH_DEV_BASE_ADDRESS DT_ST_STM32F0_FLASH_CONTROLLER_40022000_BASE_ADDRESS
|
|
#define DT_FLASH_DEV_NAME DT_ST_STM32F0_FLASH_CONTROLLER_40022000_LABEL
|
|
|
|
#define DT_USB_BASE_ADDRESS DT_ST_STM32_USB_40005C00_BASE_ADDRESS
|
|
#define DT_USB_IRQ DT_ST_STM32_USB_40005C00_IRQ_USB
|
|
#define DT_USB_IRQ_PRI DT_ST_STM32_USB_40005C00_IRQ_USB_PRIORITY
|
|
#define DT_USB_NUM_BIDIR_ENDPOINTS DT_ST_STM32_USB_40005C00_NUM_BIDIR_ENDPOINTS
|
|
#define DT_USB_RAM_SIZE DT_ST_STM32_USB_40005C00_RAM_SIZE
|
|
|
|
#ifdef DT_ST_STM32_USB_40005C00_ENABLE_PIN_REMAP
|
|
#define DT_USB_ENABLE_PIN_REMAP DT_ST_STM32_USB_40005C00_ENABLE_PIN_REMAP
|
|
#endif /* ST_STM32_USB_40005C00_ENABLE_PIN_REMAP */
|
|
|
|
#define DT_PWM_STM32_1_DEV_NAME DT_ST_STM32_PWM_40012C00_PWM_LABEL
|
|
#define DT_PWM_STM32_1_PRESCALER DT_ST_STM32_PWM_40012C00_PWM_ST_PRESCALER
|
|
#define DT_TIM_STM32_1_BASE_ADDRESS DT_ST_STM32_TIMERS_40012C00_BASE_ADDRESS
|
|
#define DT_TIM_STM32_1_CLOCK_BITS DT_ST_STM32_TIMERS_40012C00_CLOCK_BITS
|
|
#define DT_TIM_STM32_1_CLOCK_BUS DT_ST_STM32_TIMERS_40012C00_CLOCK_BUS
|
|
|
|
#define DT_PWM_STM32_2_DEV_NAME DT_ST_STM32_PWM_40000000_PWM_LABEL
|
|
#define DT_PWM_STM32_2_PRESCALER DT_ST_STM32_PWM_40000000_PWM_ST_PRESCALER
|
|
#define DT_TIM_STM32_2_BASE_ADDRESS DT_ST_STM32_TIMERS_40000000_BASE_ADDRESS
|
|
#define DT_TIM_STM32_2_CLOCK_BITS DT_ST_STM32_TIMERS_40000000_CLOCK_BITS
|
|
#define DT_TIM_STM32_2_CLOCK_BUS DT_ST_STM32_TIMERS_40000000_CLOCK_BUS
|
|
|
|
#define DT_PWM_STM32_3_DEV_NAME DT_ST_STM32_PWM_40000400_PWM_LABEL
|
|
#define DT_PWM_STM32_3_PRESCALER DT_ST_STM32_PWM_40000400_PWM_ST_PRESCALER
|
|
#define DT_TIM_STM32_3_BASE_ADDRESS DT_ST_STM32_TIMERS_40000400_BASE_ADDRESS
|
|
#define DT_TIM_STM32_3_CLOCK_BITS DT_ST_STM32_TIMERS_40000400_CLOCK_BITS
|
|
#define DT_TIM_STM32_3_CLOCK_BUS DT_ST_STM32_TIMERS_40000400_CLOCK_BUS
|
|
|
|
#define DT_PWM_STM32_6_DEV_NAME DT_ST_STM32_PWM_40001000_PWM_LABEL
|
|
#define DT_PWM_STM32_6_PRESCALER DT_ST_STM32_PWM_40001000_PWM_ST_PRESCALER
|
|
#define DT_TIM_STM32_6_BASE_ADDRESS DT_ST_STM32_TIMERS_40001000_BASE_ADDRESS
|
|
#define DT_TIM_STM32_6_CLOCK_BITS DT_ST_STM32_TIMERS_40001000_CLOCK_BITS
|
|
#define DT_TIM_STM32_6_CLOCK_BUS DT_ST_STM32_TIMERS_40001000_CLOCK_BUS
|
|
|
|
#define DT_PWM_STM32_7_DEV_NAME DT_ST_STM32_PWM_40001400_PWM_LABEL
|
|
#define DT_PWM_STM32_7_PRESCALER DT_ST_STM32_PWM_40001400_PWM_ST_PRESCALER
|
|
#define DT_TIM_STM32_7_BASE_ADDRESS DT_ST_STM32_TIMERS_40001400_BASE_ADDRESS
|
|
#define DT_TIM_STM32_7_CLOCK_BITS DT_ST_STM32_TIMERS_40001400_CLOCK_BITS
|
|
#define DT_TIM_STM32_7_CLOCK_BUS DT_ST_STM32_TIMERS_40001400_CLOCK_BUS
|
|
|
|
#define DT_PWM_STM32_14_DEV_NAME DT_ST_STM32_PWM_40002000_PWM_LABEL
|
|
#define DT_PWM_STM32_14_PRESCALER DT_ST_STM32_PWM_40002000_PWM_ST_PRESCALER
|
|
#define DT_TIM_STM32_14_BASE_ADDRESS DT_ST_STM32_TIMERS_40002000_BASE_ADDRESS
|
|
#define DT_TIM_STM32_14_CLOCK_BITS DT_ST_STM32_TIMERS_40002000_CLOCK_BITS
|
|
#define DT_TIM_STM32_14_CLOCK_BUS DT_ST_STM32_TIMERS_40002000_CLOCK_BUS
|
|
|
|
#define DT_PWM_STM32_15_DEV_NAME DT_ST_STM32_PWM_40014000_PWM_LABEL
|
|
#define DT_PWM_STM32_15_PRESCALER DT_ST_STM32_PWM_40014000_PWM_ST_PRESCALER
|
|
#define DT_TIM_STM32_15_BASE_ADDRESS DT_ST_STM32_TIMERS_40014000_BASE_ADDRESS
|
|
#define DT_TIM_STM32_15_CLOCK_BITS DT_ST_STM32_TIMERS_40014000_CLOCK_BITS
|
|
#define DT_TIM_STM32_15_CLOCK_BUS DT_ST_STM32_TIMERS_40014000_CLOCK_BUS
|
|
|
|
#define DT_PWM_STM32_16_DEV_NAME DT_ST_STM32_PWM_40014400_PWM_LABEL
|
|
#define DT_PWM_STM32_16_PRESCALER DT_ST_STM32_PWM_40014400_PWM_ST_PRESCALER
|
|
#define DT_TIM_STM32_16_BASE_ADDRESS DT_ST_STM32_TIMERS_40014400_BASE_ADDRESS
|
|
#define DT_TIM_STM32_16_CLOCK_BITS DT_ST_STM32_TIMERS_40014400_CLOCK_BITS
|
|
#define DT_TIM_STM32_16_CLOCK_BUS DT_ST_STM32_TIMERS_40014400_CLOCK_BUS
|
|
|
|
#define DT_PWM_STM32_17_DEV_NAME DT_ST_STM32_PWM_40014800_PWM_LABEL
|
|
#define DT_PWM_STM32_17_PRESCALER DT_ST_STM32_PWM_40014800_PWM_ST_PRESCALER
|
|
#define DT_TIM_STM32_17_BASE_ADDRESS DT_ST_STM32_TIMERS_40014800_BASE_ADDRESS
|
|
#define DT_TIM_STM32_17_CLOCK_BITS DT_ST_STM32_TIMERS_40014800_CLOCK_BITS
|
|
#define DT_TIM_STM32_17_CLOCK_BUS DT_ST_STM32_TIMERS_40014800_CLOCK_BUS
|
|
|
|
#define DT_WDT_0_NAME DT_ST_STM32_WATCHDOG_0_LABEL
|
|
|
|
/* End of SoC Level DTS fixup file */
|