xref: /optee_os/core/include/drivers/scif.h (revision 1aab5c1192195d263bd48b2ec95aa8cb2a13a6a0)
1*1aab5c11SVolodymyr Babchuk /*
2*1aab5c11SVolodymyr Babchuk  * Copyright (c) 2016, GlobalLogic
3*1aab5c11SVolodymyr Babchuk  * All rights reserved.
4*1aab5c11SVolodymyr Babchuk  *
5*1aab5c11SVolodymyr Babchuk  * Redistribution and use in source and binary forms, with or without
6*1aab5c11SVolodymyr Babchuk  * modification, are permitted provided that the following conditions are met:
7*1aab5c11SVolodymyr Babchuk  *
8*1aab5c11SVolodymyr Babchuk  * 1. Redistributions of source code must retain the above copyright notice,
9*1aab5c11SVolodymyr Babchuk  * this list of conditions and the following disclaimer.
10*1aab5c11SVolodymyr Babchuk  *
11*1aab5c11SVolodymyr Babchuk  * 2. Redistributions in binary form must reproduce the above copyright notice,
12*1aab5c11SVolodymyr Babchuk  * this list of conditions and the following disclaimer in the documentation
13*1aab5c11SVolodymyr Babchuk  * and/or other materials provided with the distribution.
14*1aab5c11SVolodymyr Babchuk  *
15*1aab5c11SVolodymyr Babchuk  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
16*1aab5c11SVolodymyr Babchuk  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
17*1aab5c11SVolodymyr Babchuk  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
18*1aab5c11SVolodymyr Babchuk  * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
19*1aab5c11SVolodymyr Babchuk  * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
20*1aab5c11SVolodymyr Babchuk  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
21*1aab5c11SVolodymyr Babchuk  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
22*1aab5c11SVolodymyr Babchuk  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
23*1aab5c11SVolodymyr Babchuk  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
24*1aab5c11SVolodymyr Babchuk  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
25*1aab5c11SVolodymyr Babchuk  * POSSIBILITY OF SUCH DAMAGE.
26*1aab5c11SVolodymyr Babchuk  */
27*1aab5c11SVolodymyr Babchuk #ifndef SCIF_H
28*1aab5c11SVolodymyr Babchuk #define SCIF_H
29*1aab5c11SVolodymyr Babchuk 
30*1aab5c11SVolodymyr Babchuk #include <types_ext.h>
31*1aab5c11SVolodymyr Babchuk 
32*1aab5c11SVolodymyr Babchuk #define SCIF_REG_SIZE	0x1000
33*1aab5c11SVolodymyr Babchuk 
34*1aab5c11SVolodymyr Babchuk void scif_uart_flush(vaddr_t base);
35*1aab5c11SVolodymyr Babchuk 
36*1aab5c11SVolodymyr Babchuk void scif_uart_init(vaddr_t base);
37*1aab5c11SVolodymyr Babchuk 
38*1aab5c11SVolodymyr Babchuk void scif_uart_putc(int ch, vaddr_t base);
39*1aab5c11SVolodymyr Babchuk 
40*1aab5c11SVolodymyr Babchuk #endif /* SCIF */
41