Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Jul 2019 22:59:51 +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: r350232 - head/sys/powerpc/aim
Message-ID:  <201907222259.x6MMxpJP017951@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jhibbits
Date: Mon Jul 22 22:59:50 2019
New Revision: 350232
URL: https://svnweb.freebsd.org/changeset/base/350232

Log:
  powerpc: Unbreak 64-bit pmap from 350206
  
  oldpvo is never explicitly NULL'd by moea64_pvo_enter(), so don't check for
  NULL to do anything, only check error.
  
  PR:		239372
  Reported by:	Francis Little

Modified:
  head/sys/powerpc/aim/mmu_oea64.c

Modified: head/sys/powerpc/aim/mmu_oea64.c
==============================================================================
--- head/sys/powerpc/aim/mmu_oea64.c	Mon Jul 22 22:41:44 2019	(r350231)
+++ head/sys/powerpc/aim/mmu_oea64.c	Mon Jul 22 22:59:50 2019	(r350232)
@@ -1449,13 +1449,13 @@ moea64_enter(mmu_t mmu, pmap_t pmap, vm_offset_t va, v
 			KASSERT(oldpvo->pvo_pmap == pmap, ("pmap of old "
 			    "mapping does not match new mapping"));
 			moea64_pvo_remove_from_pmap(mmu, oldpvo);
-			error = moea64_pvo_enter(mmu, pvo, pvo_head, NULL);
+			moea64_pvo_enter(mmu, pvo, pvo_head, NULL);
 		}
 		PV_PAGE_UNLOCK(m);
 		PMAP_UNLOCK(pmap);
 
 		/* Free any dead pages */
-		if (oldpvo != NULL) {
+		if (error == EEXIST) {
 			moea64_pvo_remove_from_page(mmu, oldpvo);
 			free_pvo_entry(oldpvo);
 		}
@@ -2521,8 +2521,6 @@ moea64_pvo_enter(mmu_t mmu, struct pvo_entry *pvo, str
 	struct pvo_entry *old_pvo;
 
 	PMAP_LOCK_ASSERT(pvo->pvo_pmap, MA_OWNED);
-	KASSERT(moea64_pvo_find_va(pvo->pvo_pmap, PVO_VADDR(pvo)) == NULL,
-	    ("Existing mapping for VA %#jx", (uintmax_t)PVO_VADDR(pvo)));
 
 	moea64_pvo_enter_calls++;
 



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