My Project
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
uart.h
Go to the documentation of this file.
1 /*
2  * OpenVirtualization:
3  * For additional details and support contact developer@sierraware.com.
4  * Additional documentation can be found at www.openvirtualization.org
5  *
6  * Copyright (C) 2010-2014 SierraWare
7  *
8  * This library is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU General Public License
10  * as published by the Free Software Foundation; either version 2
11  * of the License, or (at your option) any later version.
12  *
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with this program; if not, write to the Free Software
20  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21  *
22  */
23 /*
24  * UART declarations
25  */
26 
27 #ifndef __COMMON_UART_H__
28 #define __COMMON_UART_H__
29 
30 #include <sw_types.h>
31 
37 void serial_puts(char * c);
38 
44 void serial_putc(char c);
45 
51 void serial_init(u32 uart_id);
52 
61 u32 read_uart(u32 reg_offset, u32 uartid);
62 
70 void write_uart(u32 reg_offset, u32 value, u32 uartid);
71 
72 #endif
void serial_puts(char *c)
write a series of characters to UART
Definition: pl011_uart.c:118
void write_uart(u32 reg_offset, u32 value, u32 uartid)
Gets the base address of UART and writes the value onto the reg_ptr.
Definition: pl011_uart.c:68
u32 read_uart(u32 reg_offset, u32 uartid)
Gets the uart base address and returns it.
Definition: pl011_uart.c:55
void serial_init(u32 uart_id)
UART initialization.
Definition: pl011_uart.c:134
void serial_putc(char c)
write a character to UART
Definition: pl011_uart.c:104