From patchwork Mon Jun 17 11:08:03 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonas Jensen X-Patchwork-Id: 2732831 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 2136DC0AB1 for ; Mon, 17 Jun 2013 11:11:24 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 4170B20306 for ; Mon, 17 Jun 2013 11:11:23 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1098320304 for ; Mon, 17 Jun 2013 11:11:22 +0000 (UTC) Received: from merlin.infradead.org ([205.233.59.134]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UoXJn-0005bm-Qk; Mon, 17 Jun 2013 11:09:52 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UoXJU-0004GD-9W; Mon, 17 Jun 2013 11:09:32 +0000 Received: from mail-lb0-f182.google.com ([209.85.217.182]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UoXJG-0004Ce-3b for linux-arm-kernel@lists.infradead.org; Mon, 17 Jun 2013 11:09:19 +0000 Received: by mail-lb0-f182.google.com with SMTP id r11so2399691lbv.27 for ; Mon, 17 Jun 2013 04:08:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references; bh=JQW1HJDou+kCUD0ucv83zD9rGYJkn16Rvw/yM+JuC/o=; b=JyoDqAWS+nflJQVk0Ae+kg1eKRlzKiyZkHbCJDq1aV6ltRiG2NO+A/FB8nX6J8hR+z 2/XZEcOTfbTApW4f5InzplBXjuyCWf/Qe8ZyjPqwXQKYDhGh9So3zBdK4OjHWhEknf8m LUvWj3/RilZDvPvsoPqX0fuKcC08Af3gTYHJLE+1B/DtozMz6ADQuIrwipKxo7l9+XYp 1FMNR3HZzzRb9FmGTs27VdPfzC5/GiX67L543i5rYq25vaE5ZNXPcgCyXYaOSu1QHCSM jWjdLKcBLXHW/s4yzbTELMh5LQgwONzQXVyYm+JXgebIlIbnASNqk9VkZTXe4rV2nDTh VUGg== X-Received: by 10.152.121.73 with SMTP id li9mr6549063lab.42.1371467334362; Mon, 17 Jun 2013 04:08:54 -0700 (PDT) Received: from localhost.localdomain (static-213-115-41-10.sme.bredbandsbolaget.se. [213.115.41.10]) by mx.google.com with ESMTPSA id rx1sm594351lbb.0.2013.06.17.04.08.52 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Mon, 17 Jun 2013 04:08:53 -0700 (PDT) From: Jonas Jensen To: linux-arm-kernel@lists.infradead.org Subject: [PATCH v2 3/3] ARM: mach-moxart: add MOXA ART UART debug files Date: Mon, 17 Jun 2013 13:08:03 +0200 Message-Id: <1371467283-6981-3-git-send-email-jonas.jensen@gmail.com> X-Mailer: git-send-email 1.7.2.5 In-Reply-To: <1371467283-6981-1-git-send-email-jonas.jensen@gmail.com> References: <1371467283-6981-1-git-send-email-jonas.jensen@gmail.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130617_070918_418826_30DD30CA X-CRM114-Status: GOOD ( 13.54 ) X-Spam-Score: -2.7 (--) Cc: devicetree-discuss@lists.ozlabs.org, arm@kernel.org, linux@arm.linux.org.uk, linux-kernel@vger.kernel.org, Jonas Jensen X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-5.2 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add MOXA ART kernel low-level debugging port support. Signed-off-by: Jonas Jensen --- arch/arm/Kconfig.debug | 8 ++++++++ arch/arm/include/debug/moxart.S | 16 ++++++++++++++++ 2 files changed, 24 insertions(+), 0 deletions(-) create mode 100644 arch/arm/include/debug/moxart.S diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug index e6a6ab1..d1ed6e5 100644 --- a/arch/arm/Kconfig.debug +++ b/arch/arm/Kconfig.debug @@ -447,6 +447,13 @@ choice Say Y here if you want kernel low-level debugging support on Allwinner A1X based platforms on the UART1. + config DEBUG_MOXART_UART0 + bool "Kernel low-level debugging messages via MOXART UART0" + depends on ARCH_MOXART + help + Say Y here if you want kernel low-level debugging support + on MOXART based platforms on the UART0. + config DEBUG_TEGRA_UART depends on ARCH_TEGRA bool "Use Tegra UART for low-level debug" @@ -668,6 +675,7 @@ config DEBUG_LL_INCLUDE default "debug/sirf.S" if DEBUG_SIRFPRIMA2_UART1 || DEBUG_SIRFMARCO_UART1 default "debug/socfpga.S" if DEBUG_SOCFPGA_UART default "debug/sunxi.S" if DEBUG_SUNXI_UART0 || DEBUG_SUNXI_UART1 + default "debug/moxart.S" if DEBUG_MOXART_UART0 default "debug/tegra.S" if DEBUG_TEGRA_UART default "debug/ux500.S" if DEBUG_UX500_UART default "debug/vexpress.S" if DEBUG_VEXPRESS_UART0_DETECT || \ diff --git a/arch/arm/include/debug/moxart.S b/arch/arm/include/debug/moxart.S new file mode 100644 index 0000000..7ac7c76 --- /dev/null +++ b/arch/arm/include/debug/moxart.S @@ -0,0 +1,16 @@ +/* Copyright (C) 2013 Jonas Jensen + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation; either version 2 of the License, + * or (at your option) any later version. */ + +#define MOXART_UART_DEBUG_PHYS_BASE 0x98200000 +#define MOXART_UART_DEBUG_VIRT_BASE 0xf9820000 + +.macro addruart, rp, rv, tmp + ldr \rp, =MOXART_UART_DEBUG_PHYS_BASE + ldr \rv, =MOXART_UART_DEBUG_VIRT_BASE +.endm + +#define UART_SHIFT 2 +#include