/* Set the baud rate. 
This routine set the given baud rate for the UART. */
static void baudrate_set(const struct device *dev, uint32_t baudrate, uint32_t sys_clk_freq_hz)
/* Set the baud rate. 
This routine set the given baud rate for the UART. */
static void baudrate_set(const struct device *dev, uint32_t baudrate, uint32_t sys_clk_freq_hz)
{
	const struct uart_stellaris_config *config = dev->config;
	uint32_t brdi, brdf, div, rem;
	div = (baudrate * 16U);
	rem = sys_clk_freq_hz % div;
	brdf = ((((rem * 64U) << 1) / div) + 1) >> 1;
	brdi = sys_clk_freq_hz / div;
	config->uart->ibrd = (uint16_t)(brdi & 0xffff);
	config->uart->fbrd = (uint8_t)(brdf & 0x3f);
}