From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1XXHaF-0004iz-Ks for mharc-grub-devel@gnu.org; Thu, 25 Sep 2014 18:32:19 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:45719) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XXHa9-0004gO-7Q for grub-devel@gnu.org; Thu, 25 Sep 2014 18:32:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XXHa1-0001Ho-5L for grub-devel@gnu.org; Thu, 25 Sep 2014 18:32:13 -0400 Received: from 177-91-79-176.rev.netcorporativa.com.br ([177.91.79.176]:40314 helo=beren) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XXHa0-0001Gd-Sh for grub-devel@gnu.org; Thu, 25 Sep 2014 18:32:05 -0400 Received: from beren (localhost.localdomain [127.0.0.1]) by beren (8.14.7/8.14.7) with ESMTP id s8PLT7Sh001445; Thu, 25 Sep 2014 18:29:07 -0300 Received: (from pfsmorigo@localhost) by beren (8.14.7/8.14.7/Submit) id s8PLT5Px000556; Thu, 25 Sep 2014 18:29:05 -0300 From: Paulo Flabiano Smorigo To: grub-devel@gnu.org Subject: [PATCH] Disable VSX instruction Date: Thu, 25 Sep 2014 18:28:01 -0300 Message-Id: <1411680481-24782-1-git-send-email-pfsmorigo@linux.vnet.ibm.com> X-Mailer: git-send-email 1.8.1.4 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 177.91.79.176 Cc: Paulo Flabiano Smorigo X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Sep 2014 22:32:18 -0000 VSX bit is enabled by default for Power7 and Power8 CPU models, so we need to disable them in order to avoid instruction exceptions. Kernel will activate it when necessary. Also-By: Adhemerval Zanella --- ChangeLog | 10 ++++++++++ grub-core/kern/powerpc/ieee1275/startup.S | 10 ++++++++++ 2 files changed, 20 insertions(+) diff --git a/ChangeLog b/ChangeLog index 192e8bc..c1b0637 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2014-09-25 Paulo Flabiano Smroigo + + Disable VSX instruction + + VSX bit is enabled by default for Power7 and Power8 CPU models, so we + need to disable them in order to avoid instruction exceptions. Kernel + will activate it when necessary. + + * grub-core/kern/powerpc/ieee1275/startup.S: Disable VSX. + 2014-09-25 Colin Watson Fix in-tree --platform=none diff --git a/grub-core/kern/powerpc/ieee1275/startup.S b/grub-core/kern/powerpc/ieee1275/startup.S index 21c884b..c4621a6 100644 --- a/grub-core/kern/powerpc/ieee1275/startup.S +++ b/grub-core/kern/powerpc/ieee1275/startup.S @@ -20,6 +20,8 @@ #include #include +#define MSR_VSX 0x80 + .extern __bss_start .extern _end @@ -28,6 +30,14 @@ .globl start, _start start: _start: + _start: + + /* Disable VSX interrupt instruction */ + mfmsr 0 + oris 0,0,MSR_VSX + mtmsrd 0 + isync + li 2, 0 li 13, 0 -- 1.8.1.4