mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-30 07:26:46 +07:00
bcd72c3e0a
Originally there was an ifdef case to handle when no debug uart
was selected. In commit 0ea1293009
that case was removed which causes the following build failure,
linux-2.6/arch/arm/kernel/debug.S: Assembler messages:
linux-2.6/arch/arm/kernel/debug.S:174: Error: bad instruction `addruart r1,r2'
linux-2.6/arch/arm/kernel/debug.S:176: Error: bad instruction `waituart r2,r3'
linux-2.6/arch/arm/kernel/debug.S:177: Error: bad instruction `senduart r1,r3'
linux-2.6/arch/arm/kernel/debug.S:178: Error: bad instruction `busyuart r2,r3'
linux-2.6/arch/arm/kernel/debug.S:190: Error: bad instruction `addruart r1,r2'
This is a partial revert to add back the case which was removed with
two caveats. First the API for the addruart macro was updated, and
the new addruart case now return 0xfff00000 so that a know IO mapping
is created instead of a random one.
Cc: Jeremy Kerr <jeremy.kerr@canonical.com>
Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Cc: Jason Wang <jason77.wang@gmail.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: Nicolas Pitre <nico@fluxnic.net>
Cc: Russell King - ARM Linux <linux@arm.linux.org.uk>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
54 lines
1.1 KiB
ArmAsm
54 lines
1.1 KiB
ArmAsm
/* arch/arm/mach-msm7200/include/mach/debug-macro.S
|
|
*
|
|
* Copyright (C) 2007 Google, Inc.
|
|
* Author: Brian Swetland <swetland@google.com>
|
|
*
|
|
* This software is licensed under the terms of the GNU General Public
|
|
* License version 2, as published by the Free Software Foundation, and
|
|
* may be copied, distributed, and modified under those terms.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
*/
|
|
|
|
|
|
|
|
#include <mach/hardware.h>
|
|
#include <mach/msm_iomap.h>
|
|
|
|
#ifdef CONFIG_HAS_MSM_DEBUG_UART_PHYS
|
|
.macro addruart, rp, rv
|
|
ldr \rp, =MSM_DEBUG_UART_PHYS
|
|
ldr \rv, =MSM_DEBUG_UART_BASE
|
|
.endm
|
|
|
|
.macro senduart,rd,rx
|
|
teq \rx, #0
|
|
strne \rd, [\rx, #0x0C]
|
|
.endm
|
|
|
|
.macro waituart,rd,rx
|
|
@ wait for TX_READY
|
|
1001: ldr \rd, [\rx, #0x08]
|
|
tst \rd, #0x04
|
|
beq 1001b
|
|
.endm
|
|
#else
|
|
.macro addruart, rp, rv
|
|
mov \rv, #0xff000000
|
|
orr \rv, \rv, #0x00f00000
|
|
.endm
|
|
|
|
.macro senduart,rd,rx
|
|
.endm
|
|
|
|
.macro waituart,rd,rx
|
|
.endm
|
|
#endif
|
|
|
|
.macro busyuart,rd,rx
|
|
.endm
|