]> git.kernelconcepts.de Git - karo-tx-uboot.git/blob - arch/arm/cpu/armv7/uniphier/ph1-ld4/lowlevel_debug.S
Merge branch 'karo-tx-uboot' into kc-merge
[karo-tx-uboot.git] / arch / arm / cpu / armv7 / uniphier / ph1-ld4 / lowlevel_debug.S
1 /*
2  * On-chip UART initializaion for low-level debugging
3  *
4  * Copyright (C) 2014 Panasonic Corporation
5  *   Author: Masahiro Yamada <yamada.m@jp.panasonic.com>
6  *
7  * SPDX-License-Identifier:     GPL-2.0+
8  */
9
10 #include <linux/linkage.h>
11 #include <asm/arch/sg-regs.h>
12
13 #define UART_CLK                36864000
14 #include <asm/arch/debug-uart.S>
15
16 ENTRY(setup_lowlevel_debug)
17                 init_debug_uart r0, r1, r2
18
19                 /* UART Port 0 */
20                 set_pinsel      85, 1, r0, r1
21                 set_pinsel      88, 1, r0, r1
22
23                 ldr             r0, =SG_IECTRL
24                 ldr             r1, [r0]
25                 orr             r1, r1, #1
26                 str             r1, [r0]
27
28                 mov             pc, lr
29 ENDPROC(setup_lowlevel_debug)