From owner-svn-src-head@FreeBSD.ORG Tue Oct 30 06:07:31 2012 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 835D234F; Tue, 30 Oct 2012 06:07:31 +0000 (UTC) (envelope-from jmallett@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6A18F8FC12; Tue, 30 Oct 2012 06:07:31 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q9U67V5Q028944; Tue, 30 Oct 2012 06:07:31 GMT (envelope-from jmallett@svn.freebsd.org) Received: (from jmallett@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q9U67VFd028939; Tue, 30 Oct 2012 06:07:31 GMT (envelope-from jmallett@svn.freebsd.org) Message-Id: <201210300607.q9U67VFd028939@svn.freebsd.org> From: Juli Mallett Date: Tue, 30 Oct 2012 06:07:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r242342 - in head/sys: contrib/octeon-sdk mips/cavium 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.14 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: Tue, 30 Oct 2012 06:07:31 -0000 Author: jmallett Date: Tue Oct 30 06:07:30 2012 New Revision: 242342 URL: http://svn.freebsd.org/changeset/base/242342 Log: Speed feature tests and initialize helper configuration that some CPUs require. Modified: head/sys/contrib/octeon-sdk/octeon-feature.c head/sys/contrib/octeon-sdk/octeon-feature.h head/sys/mips/cavium/files.octeon1 head/sys/mips/cavium/octeon_machdep.c Modified: head/sys/contrib/octeon-sdk/octeon-feature.c ============================================================================== --- head/sys/contrib/octeon-sdk/octeon-feature.c Tue Oct 30 04:31:32 2012 (r242341) +++ head/sys/contrib/octeon-sdk/octeon-feature.c Tue Oct 30 06:07:30 2012 (r242342) @@ -139,7 +139,7 @@ feature_check: cvmx_dprintf("unknown error %d.\n", val); break; } -#if !defined(CVMX_BUILD_FOR_LINUX_KERNEL) && !defined(__U_BOOT__) && !defined(CVMX_BUILD_FOR_TOOLCHAIN) +#if !defined(CVMX_BUILD_FOR_LINUX_KERNEL) && !defined(__U_BOOT__) && !defined(CVMX_BUILD_FOR_TOOLCHAIN) && !defined(CVMX_BUILD_FOR_FREEBSD_KERNEL) exit (1); #endif } Modified: head/sys/contrib/octeon-sdk/octeon-feature.h ============================================================================== --- head/sys/contrib/octeon-sdk/octeon-feature.h Tue Oct 30 04:31:32 2012 (r242341) +++ head/sys/contrib/octeon-sdk/octeon-feature.h Tue Oct 30 06:07:30 2012 (r242342) @@ -281,7 +281,7 @@ extern uint8_t octeon_feature_map[FEATUR #if defined(__U_BOOT__) || defined(CVMX_BUILD_FOR_LINUX_HOST) || defined(CVMX_BUILD_FOR_TOOLCHAIN) #define octeon_has_feature old_octeon_has_feature #else -#if defined(USE_RUNTIME_MODEL_CHECKS) +#if defined(USE_RUNTIME_MODEL_CHECKS) || (defined(__FreeBSD__) && defined(_KERNEL)) static inline int octeon_has_feature(octeon_feature_t feature) { int byte, bit; Modified: head/sys/mips/cavium/files.octeon1 ============================================================================== --- head/sys/mips/cavium/files.octeon1 Tue Oct 30 04:31:32 2012 (r242341) +++ head/sys/mips/cavium/files.octeon1 Tue Oct 30 06:07:30 2012 (r242342) @@ -61,6 +61,7 @@ contrib/octeon-sdk/cvmx-clock.c standa contrib/octeon-sdk/cvmx-ebt3000.c standard contrib/octeon-sdk/cvmx-fpa.c standard contrib/octeon-sdk/cvmx-helper.c standard +contrib/octeon-sdk/cvmx-helper-cfg.c standard contrib/octeon-sdk/cvmx-helper-board.c standard contrib/octeon-sdk/cvmx-helper-cfg.c standard contrib/octeon-sdk/cvmx-helper-errata.c standard @@ -89,6 +90,7 @@ contrib/octeon-sdk/cvmx-sysinfo.c stand contrib/octeon-sdk/cvmx-thunder.c standard contrib/octeon-sdk/cvmx-twsi.c standard contrib/octeon-sdk/cvmx-warn.c standard +contrib/octeon-sdk/octeon-feature.c standard contrib/octeon-sdk/octeon-model.c standard # HWPMC Modified: head/sys/mips/cavium/octeon_machdep.c ============================================================================== --- head/sys/mips/cavium/octeon_machdep.c Tue Oct 30 04:31:32 2012 (r242341) +++ head/sys/mips/cavium/octeon_machdep.c Tue Oct 30 06:07:30 2012 (r242342) @@ -76,6 +76,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include @@ -598,6 +599,10 @@ octeon_boot_params_init(register_t ptr) panic("Your boot loader did not supply a memory descriptor."); cvmx_bootmem_init(cvmx_sysinfo_get()->phy_mem_desc_addr); + octeon_feature_init(); + + __cvmx_helper_cfg_init(); + printf("Boot Descriptor Ver: %u -> %u/%u", app_desc_ptr->desc_version, octeon_bootinfo->major_version, octeon_bootinfo->minor_version);