From owner-svn-src-head@FreeBSD.ORG Fri May 2 01:20:14 2014 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 2334CE4F; Fri, 2 May 2014 01:20:14 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::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 105F014C0; Fri, 2 May 2014 01:20:14 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s421KDAa052864; Fri, 2 May 2014 01:20:13 GMT (envelope-from ganbold@svn.freebsd.org) Received: (from ganbold@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s421KDhD052863; Fri, 2 May 2014 01:20:13 GMT (envelope-from ganbold@svn.freebsd.org) Message-Id: <201405020120.s421KDhD052863@svn.freebsd.org> From: Ganbold Tsagaankhuu Date: Fri, 2 May 2014 01:20:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r265207 - head/sys/arm/rockchip X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 02 May 2014 01:20:14 -0000 Author: ganbold Date: Fri May 2 01:20:13 2014 New Revision: 265207 URL: http://svnweb.freebsd.org/changeset/base/265207 Log: Switch to use arm_devmap_add_entry() to setup static device mapping. Approved by: stas (mentor) Modified: head/sys/arm/rockchip/rk30xx_machdep.c Modified: head/sys/arm/rockchip/rk30xx_machdep.c ============================================================================== --- head/sys/arm/rockchip/rk30xx_machdep.c Fri May 2 00:52:13 2014 (r265206) +++ head/sys/arm/rockchip/rk30xx_machdep.c Fri May 2 01:20:13 2014 (r265207) @@ -51,14 +51,11 @@ __FBSDID("$FreeBSD$"); #include -/* Start of address space used for bootstrap map */ -#define DEVMAP_BOOTSTRAP_MAP_START 0xF0000000 - vm_offset_t initarm_lastaddr(void) { - return (DEVMAP_BOOTSTRAP_MAP_START); + return (arm_devmap_lastaddr()); } void @@ -81,27 +78,14 @@ initarm_late_init(void) CPU_CONTROL_DC_ENABLE|CPU_CONTROL_IC_ENABLE); } -#define FDT_DEVMAP_MAX (1 + 2 + 1 + 1) -static struct arm_devmap_entry fdt_devmap[FDT_DEVMAP_MAX] = { - { 0, 0, 0, 0, 0, } -}; - /* - * Construct pmap_devmap[] with DT-derived config data. + * Set up static device mappings. */ int initarm_devmap_init(void) { - int i = 0; - - fdt_devmap[i].pd_va = 0xF0000000; - fdt_devmap[i].pd_pa = 0x20000000; - fdt_devmap[i].pd_size = 0x100000; - fdt_devmap[i].pd_prot = VM_PROT_READ | VM_PROT_WRITE; - fdt_devmap[i].pd_cache = PTE_DEVICE; - i++; - arm_devmap_register_table(&fdt_devmap[0]); + arm_devmap_add_entry(0x20000000, 0x00100000); return (0); }