/* Get the peripheral clock speed for the USART at base specified.  */
uint32_t rcc_get_usart_clk_freq(uint32_t usart)
/* Get the peripheral clock speed for the USART at base specified.  */
uint32_t rcc_get_usart_clk_freq(uint32_t usart)
{
	if (usart == USART1_BASE) {
		return rcc_get_clksel_freq(RCC_CCIPR_USART1SEL_SHIFT);
	} else if (usart == USART2_BASE) {
		return rcc_get_clksel_freq(RCC_CCIPR_USART2SEL_SHIFT);
	} else if (usart == USART3_BASE) {
		return rcc_get_clksel_freq(RCC_CCIPR_USART3SEL_SHIFT);
	} else if (usart == LPUART1_BASE) {
		return rcc_get_clksel_freq(RCC_CCIPR_LPUART1SEL_SHIFT);
	} else if (usart == LPUART2_BASE) {
		return rcc_get_clksel_freq(RCC_CCIPR_LPUART2SEL_SHIFT);
	}
	cm3_assert_not_reached();
}