From owner-freebsd-arm@freebsd.org Wed Jul 15 07:48:03 2015 Return-Path: Delivered-To: freebsd-arm@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 48F9A9A2416 for ; Wed, 15 Jul 2015 07:48:03 +0000 (UTC) (envelope-from daemon-user@freebsd.org) Received: from phabric-backend.isc.freebsd.org (phabric-backend.isc.freebsd.org [IPv6:2001:4f8:3:ffe0:406a:0:50:2]) by mx1.freebsd.org (Postfix) with ESMTP id 2E01C1623 for ; Wed, 15 Jul 2015 07:48:03 +0000 (UTC) (envelope-from daemon-user@freebsd.org) Received: by phabric-backend.isc.freebsd.org (Postfix, from userid 1346) id 1C5ECE3C8; Wed, 15 Jul 2015 07:48:03 +0000 (UTC) Date: Wed, 15 Jul 2015 07:48:03 +0000 To: freebsd-arm@freebsd.org From: "wma_semihalf.com (Wojciech Macek)" Reply-to: D3095+327+6dc882db4fe57193@FreeBSD.org Subject: [Differential] [Request, 7 lines] D3095: Add identify_cpu to ARMv8 init_secondary routine Message-ID: X-Priority: 3 Thread-Topic: D3095: Add identify_cpu to ARMv8 init_secondary routine X-Herald-Rules: <28>, <31>, <32>, <34> X-Phabricator-To: X-Phabricator-To: X-Phabricator-To: X-Phabricator-To: X-Phabricator-Cc: X-Phabricator-Cc: X-Phabricator-Cc: X-Phabricator-Cc: Thread-Index: NDAyNDhmYzQyZTUyMzNjYjI0N2VlZGE3MmQ3 Precedence: bulk X-Phabricator-Sent-This-Message: Yes X-Mail-Transport-Agent: MetaMTA X-Auto-Response-Suppress: All X-Phabricator-Mail-Tags: , , , MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="b1_33f3fa933c5921e896784d4274b7e942" X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.20 List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Jul 2015 07:48:03 -0000 --b1_33f3fa933c5921e896784d4274b7e942 Content-Type: text/plain; charset = "utf-8" Content-Transfer-Encoding: 8bit wma_semihalf.com created this revision. wma_semihalf.com added reviewers: emaste, andrew, zbb. wma_semihalf.com added a subscriber: freebsd-arm-list. wma_semihalf.com set the repository for this revision to rS FreeBSD src repository. Herald added subscribers: emaste, andrew, imp. REVISION SUMMARY Identify current CPU. This is necessary to setup affinity structures and to provide support for runtime chip identification. REPOSITORY rS FreeBSD src repository REVISION DETAIL https://reviews.freebsd.org/D3095 AFFECTED FILES sys/arm64/arm64/mp_machdep.c CHANGE DETAILS diff --git a/sys/arm64/arm64/mp_machdep.c b/sys/arm64/arm64/mp_machdep.c --- a/sys/arm64/arm64/mp_machdep.c +++ b/sys/arm64/arm64/mp_machdep.c @@ -229,6 +229,13 @@ pcpup->pc_curthread = pcpup->pc_idlethread; pcpup->pc_curpcb = pcpup->pc_idlethread->td_pcb; + /* + * Identify current CPU. This is necessary to setup + * affinity registers and to provide support for + * runtime chip identification. + */ + identify_cpu(); + /* Configure the interrupt controller */ arm_init_secondary(); EMAIL PREFERENCES https://reviews.freebsd.org/settings/panel/emailpreferences/ To: wma_semihalf.com, emaste, andrew, zbb Cc: imp, andrew, freebsd-arm-list, emaste --b1_33f3fa933c5921e896784d4274b7e942 Content-Type: text/x-patch; charset=utf-8; name="D3095.6961.patch" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="D3095.6961.patch" ZGlmZiAtLWdpdCBhL3N5cy9hcm02NC9hcm02NC9tcF9tYWNoZGVwLmMgYi9zeXMvYXJtNjQvYXJt NjQvbXBfbWFjaGRlcC5jCi0tLSBhL3N5cy9hcm02NC9hcm02NC9tcF9tYWNoZGVwLmMKKysrIGIv c3lzL2FybTY0L2FybTY0L21wX21hY2hkZXAuYwpAQCAtMjI5LDYgKzIyOSwxMyBAQAogCXBjcHVw LT5wY19jdXJ0aHJlYWQgPSBwY3B1cC0+cGNfaWRsZXRocmVhZDsKIAlwY3B1cC0+cGNfY3VycGNi ID0gcGNwdXAtPnBjX2lkbGV0aHJlYWQtPnRkX3BjYjsKIAorCS8qCisJICogSWRlbnRpZnkgY3Vy cmVudCBDUFUuIFRoaXMgaXMgbmVjZXNzYXJ5IHRvIHNldHVwCisJICogYWZmaW5pdHkgcmVnaXN0 ZXJzIGFuZCB0byBwcm92aWRlIHN1cHBvcnQgZm9yCisJICogcnVudGltZSBjaGlwIGlkZW50aWZp Y2F0aW9uLgorCSAqLworCWlkZW50aWZ5X2NwdSgpOworCiAJLyogQ29uZmlndXJlIHRoZSBpbnRl cnJ1cHQgY29udHJvbGxlciAqLwogCWFybV9pbml0X3NlY29uZGFyeSgpOwogCgo= --b1_33f3fa933c5921e896784d4274b7e942--