Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 8 Mar 2019 04:20:33 +0000 (UTC)
From:      Justin Hibbits <jhibbits@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r344916 - head/sys/powerpc/aim
Message-ID:  <201903080420.x284KXVV098370@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jhibbits
Date: Fri Mar  8 04:20:33 2019
New Revision: 344916
URL: https://svnweb.freebsd.org/changeset/base/344916

Log:
  powerpc64: Fix early exit with invalid kernel SLB entries
  
  The check for early exit should be checking the SLB entry itself.  As
  currently written it was checking the address of the SLB, which is always
  non-zero, so would go through the kernel SR restore loop regardless.
  
  Submitted by:	mmacy
  MFC after:	2 weeks

Modified:
  head/sys/powerpc/aim/trap_subr64.S

Modified: head/sys/powerpc/aim/trap_subr64.S
==============================================================================
--- head/sys/powerpc/aim/trap_subr64.S	Fri Mar  8 03:59:53 2019	(r344915)
+++ head/sys/powerpc/aim/trap_subr64.S	Fri Mar  8 04:20:33 2019	(r344916)
@@ -89,7 +89,7 @@ restore_kernsrs:
 	GET_CPUINFO(%r28)
 	addi	%r28,%r28,PC_KERNSLB
 	ld	%r29,16(%r28)		/* One past USER_SLB_SLOT */
-	cmpdi	%r28,0
+	cmpdi	%r29,0
 	beqlr				/* If first kernel entry is invalid,
 					 * SLBs not in use, so exit early */
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201903080420.x284KXVV098370>