From owner-svn-src-all@freebsd.org Tue Oct 18 12:21:47 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 159A7C14751; Tue, 18 Oct 2016 12:21:47 +0000 (UTC) (envelope-from mmel@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DBAEBA9D; Tue, 18 Oct 2016 12:21:46 +0000 (UTC) (envelope-from mmel@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u9ICLkbH073738; Tue, 18 Oct 2016 12:21:46 GMT (envelope-from mmel@FreeBSD.org) Received: (from mmel@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u9ICLkNc073737; Tue, 18 Oct 2016 12:21:46 GMT (envelope-from mmel@FreeBSD.org) Message-Id: <201610181221.u9ICLkNc073737@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mmel set sender to mmel@FreeBSD.org using -f From: Michal Meloun Date: Tue, 18 Oct 2016 12:21:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r307556 - head/sys/arm/nvidia/tegra124 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Oct 2016 12:21:47 -0000 Author: mmel Date: Tue Oct 18 12:21:45 2016 New Revision: 307556 URL: https://svnweb.freebsd.org/changeset/base/307556 Log: TEGRA: Really implement early printf. The original version was cut&pasted from another SoC. Pointy-hat to: mmel MFC after: 2 weeks Modified: head/sys/arm/nvidia/tegra124/tegra124_machdep.c Modified: head/sys/arm/nvidia/tegra124/tegra124_machdep.c ============================================================================== --- head/sys/arm/nvidia/tegra124/tegra124_machdep.c Tue Oct 18 10:33:28 2016 (r307555) +++ head/sys/arm/nvidia/tegra124/tegra124_machdep.c Tue Oct 18 12:21:45 2016 (r307556) @@ -120,18 +120,18 @@ tegra124_cpu_reset(platform_t plat) /* * Early putc routine for EARLY_PRINTF support. To use, add to kernel config: - * option SOCDEV_PA=0x02000000 - * option SOCDEV_VA=0x02000000 + * option SOCDEV_PA=0x70000000 + * option SOCDEV_VA=0x70000000 * option EARLY_PRINTF */ -#if 0 +#ifdef EARLY_PRINTF static void tegra124_early_putc(int c) { - volatile uint32_t * UART_STAT_REG = (uint32_t *)0x02020098; - volatile uint32_t * UART_TX_REG = (uint32_t *)0x02020040; - const uint32_t UART_TXRDY = (1 << 3); + volatile uint32_t * UART_STAT_REG = (uint32_t *)(0x70006314); + volatile uint32_t * UART_TX_REG = (uint32_t *)(0x70006300); + const uint32_t UART_TXRDY = (1 << 6); while ((*UART_STAT_REG & UART_TXRDY) == 0) continue; *UART_TX_REG = c;