From owner-svn-src-head@freebsd.org Thu Oct 13 09:06:31 2016 Return-Path: Delivered-To: svn-src-head@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 1690FC109ED; Thu, 13 Oct 2016 09:06:31 +0000 (UTC) (envelope-from andrew@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 BC877A73; Thu, 13 Oct 2016 09:06:30 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u9D96TJk054235; Thu, 13 Oct 2016 09:06:29 GMT (envelope-from andrew@FreeBSD.org) Received: (from andrew@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u9D96T5I054233; Thu, 13 Oct 2016 09:06:29 GMT (envelope-from andrew@FreeBSD.org) Message-Id: <201610130906.u9D96T5I054233@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: andrew set sender to andrew@FreeBSD.org using -f From: Andrew Turner Date: Thu, 13 Oct 2016 09:06:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r307210 - head/sys/arm64/arm64 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.23 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: Thu, 13 Oct 2016 09:06:31 -0000 Author: andrew Date: Thu Oct 13 09:06:29 2016 New Revision: 307210 URL: https://svnweb.freebsd.org/changeset/base/307210 Log: Move printing the AArch64 ID registers to a new SYSINIT, the previous location only prints them when booting on SMP with multiple cores. MFC after: 1 week Sponsored by: DARPA, AFRL Modified: head/sys/arm64/arm64/identcpu.c head/sys/arm64/arm64/mp_machdep.c Modified: head/sys/arm64/arm64/identcpu.c ============================================================================== --- head/sys/arm64/arm64/identcpu.c Thu Oct 13 09:00:44 2016 (r307209) +++ head/sys/arm64/arm64/identcpu.c Thu Oct 13 09:06:29 2016 (r307210) @@ -33,7 +33,9 @@ __FBSDID("$FreeBSD$"); #include +#include #include +#include #include #include @@ -151,6 +153,17 @@ const struct cpu_implementers cpu_implem CPU_IMPLEMENTER_NONE, }; +static void +identify_cpu_sysinit(void *dummy __unused) +{ + int cpu; + + CPU_FOREACH(cpu) { + print_cpu_features(cpu); + } +} +SYSINIT(idenrity_cpu, SI_SUB_SMP, SI_ORDER_ANY, identify_cpu_sysinit, NULL); + void print_cpu_features(u_int cpu) { Modified: head/sys/arm64/arm64/mp_machdep.c ============================================================================== --- head/sys/arm64/arm64/mp_machdep.c Thu Oct 13 09:00:44 2016 (r307209) +++ head/sys/arm64/arm64/mp_machdep.c Thu Oct 13 09:06:29 2016 (r307210) @@ -201,7 +201,7 @@ arm64_cpu_attach(device_t dev) static void release_aps(void *dummy __unused) { - int cpu, i; + int i; intr_pic_ipi_setup(IPI_AST, "ast", ipi_ast, NULL); intr_pic_ipi_setup(IPI_PREEMPT, "preempt", ipi_preempt, NULL); @@ -217,14 +217,8 @@ release_aps(void *dummy __unused) printf("Release APs\n"); for (i = 0; i < 2000; i++) { - if (smp_started) { - for (cpu = 0; cpu <= mp_maxid; cpu++) { - if (CPU_ABSENT(cpu)) - continue; - print_cpu_features(cpu); - } + if (smp_started) return; - } DELAY(1000); }