/* Output a character in polled mode. 
If the hardware flow control is enabled then the handshake signal CTS has to be asserted in order to send a character. */
static void uart_xec_poll_out(const struct device *dev, unsigned char c)
/* Output a character in polled mode. 
If the hardware flow control is enabled then the handshake signal CTS has to be asserted in order to send a character. */
static void uart_xec_poll_out(const struct device *dev, unsigned char c)
{
	const struct uart_xec_device_config * const dev_cfg = dev->config;
	struct uart_xec_dev_data *dev_data = dev->data;
	struct uart_regs *regs = dev_cfg->regs;
	k_spinlock_key_t key = k_spin_lock(&dev_data->lock);
	while ((regs->LSR & LSR_THRE) == 0) {
		;
	}
	regs->RTXB = c;
	k_spin_unlock(&dev_data->lock, key);
}