From owner-freebsd-current@freebsd.org Sun Mar 19 16:16:47 2017 Return-Path: Delivered-To: freebsd-current@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 8286FD136BF for ; Sun, 19 Mar 2017 16:16:47 +0000 (UTC) (envelope-from slw@zxy.spb.ru) Received: from zxy.spb.ru (zxy.spb.ru [195.70.199.98]) (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 3648D14BF; Sun, 19 Mar 2017 16:16:47 +0000 (UTC) (envelope-from slw@zxy.spb.ru) Received: from slw by zxy.spb.ru with local (Exim 4.86 (FreeBSD)) (envelope-from ) id 1cpdVc-000EMF-Si; Sun, 19 Mar 2017 19:16:44 +0300 Date: Sun, 19 Mar 2017 19:16:44 +0300 From: Slawa Olhovchenkov To: Konstantin Belousov Cc: Dimitry Andric , Rozhuk Ivan , "O. Hartmann" , freebsd-current Subject: Re: CURRENT: FreeBSD not reporting AES-NI on Intel(R) Xeon(R) CPU E5-1650 v3 Message-ID: <20170319161644.GW70430@zxy.spb.ru> References: <20170317123625.60f1a508@freyja.zeit4.iv.bundesimmobilien.de> <20170317120429.GX15630@zxy.spb.ru> <20170317175324.27f1d59d@thor.intern.walstatt.dynvpn.de> <20170319153658.7f2b0038@rimwks> <20170319160733.GA43712@kib.kiev.ua> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170319160733.GA43712@kib.kiev.ua> User-Agent: Mutt/1.5.24 (2015-08-30) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: slw@zxy.spb.ru X-SA-Exim-Scanned: No (on zxy.spb.ru); SAEximRunCond expanded to false X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 19 Mar 2017 16:16:47 -0000 On Sun, Mar 19, 2017 at 06:07:33PM +0200, Konstantin Belousov wrote: > On Sun, Mar 19, 2017 at 04:58:40PM +0100, Dimitry Andric wrote: > > On 19 Mar 2017, at 13:36, Rozhuk Ivan wrote: > > > > > > On Fri, 17 Mar 2017 17:53:24 +0100 > > > "O. Hartmann" wrote: > > > > > >>> Other OS detect AES-NI on this server? > > >> > > >> I havn't ried so far, the box is in heavy use. I'd like to check with > > >> some live USB drive versions and report later. > > >> > > > > > > You can write or find some program that read and decode CPUID and check > > > AES-NI support without reboot. > > > > The kernel already does this at boot time, and show the results, e.g.: > > > > CPU: Intel(R) Core(TM) i7-3770 CPU @ 3.40GHz (3391.68-MHz 686-class CPU) > > Origin="GenuineIntel" Id=0x306a9 Family=0x6 Model=0x3a Stepping=9 > > Features=0xfa3fbff > > Features2=0xffba2203 > > AMD Features=0x28100000 > > AMD Features2=0x1 > > Structured Extended Features=0x202 > > TSC: P-state invariant > > > > Unfortunately the kernel does not expose this information via any > > sysctl, so some time after booting it may have "scrolled away" in > > dmesg. > It is quite pointless to expose the information through a sysctl, because > it is non-privileged and is available to usermode via execution of the > CPUID instruction, which is utilized by utilities listed below. > > Also, look at cpucontrol -i. % cpucontrol -i 0x1 /dev/cpuctl1 cpucontrol: error opening /dev/cpuctl1 for reading: Permission denied > > > > In that case, you can use either the misc/cpuid or the sysutils/cpuid > > ports to show this information, and even quite a lot more. > Or better, sysutils/x86info. % x86info x86info v1.31pre /dev/cpuctl0: Permission denied Found 24 identical CPUs Extended Family: 0 Extended Model: 4 Family: 6 Model: 79 Stepping: 1 Type: 0 (Original OEM) CPU Model (x86info's best guess): Unknown model. Processor name string (BIOS programmed): Intel(R) Xeon(R) CPU E5-2650 v4 @ 2.20GHz Total processor threads: 24 This system has 2 six-core processors with hyper-threading (2 threads per core) running at an estimated 2.20GHz