summaryrefslogtreecommitdiff
path: root/core/include/drivers/hi16xx_uart.h
blob: 83413fc0e20e0a6baba2f4d4eb7c6c2caf12d700 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/* SPDX-License-Identifier: BSD-2-Clause */
/*
 * Copyright (c) 2016, Linaro Limited
 */

/*
 * UART driver for Hisilicon Hi16xx and Phosphor V660 (hip05) SoCs
 */

#ifndef HI16XX_UART_H
#define HI16XX_UART_H

#include <types_ext.h>
#include <drivers/serial.h>

#define HI16XX_UART_REG_SIZE 0xF8

struct hi16xx_uart_data {
	struct io_pa_va base;
	struct serial_chip chip;
};

void hi16xx_uart_init(struct hi16xx_uart_data *pd, paddr_t base,
		      uint32_t uart_clk, uint32_t baud_rate);

#endif /* HI16XX_UART_H */