aboutsummaryrefslogtreecommitdiff
path: root/sys/powerpc
diff options
context:
space:
mode:
authorLeandro Lupori <luporl@FreeBSD.org>2020-11-06 18:50:00 +0000
committerLeandro Lupori <luporl@FreeBSD.org>2020-11-06 18:50:00 +0000
commit8b2133d4e18e7dd0a5984fb2cdec3da4f84bac3c (patch)
tree21da3ac6ed447b3b70acbbfc03e73d39473ac576 /sys/powerpc
parent3acf4d23746ee8c4bb46952b13291b2461145c0e (diff)
downloadsrc-8b2133d4e18e7dd0a5984fb2cdec3da4f84bac3c.tar.gz
src-8b2133d4e18e7dd0a5984fb2cdec3da4f84bac3c.zip
Fix powerpc and LINT builds
Fix build errors introduced by r367417 and r367390: - Guard label reached only by powerpc64 - Guard vm_reserv_level_iffullpop call, that is not defined on powerpc variants that don't support superpages - Add missing hwpmc file, for when hwpmc is built into kernel
Notes
Notes: svn path=/head/; revision=367427
Diffstat (limited to 'sys/powerpc')
-rw-r--r--sys/powerpc/aim/mmu_oea64.c2
-rw-r--r--sys/powerpc/aim/moea64_native.c3
2 files changed, 4 insertions, 1 deletions
diff --git a/sys/powerpc/aim/mmu_oea64.c b/sys/powerpc/aim/mmu_oea64.c
index 0ea9ec55f489..19ebe3411781 100644
--- a/sys/powerpc/aim/mmu_oea64.c
+++ b/sys/powerpc/aim/mmu_oea64.c
@@ -1760,6 +1760,7 @@ out:
moea64_syncicache(pmap, va, pa, PAGE_SIZE);
}
+#if VM_NRESERVLEVEL > 0
/*
* Try to promote pages.
*
@@ -1773,6 +1774,7 @@ out:
(m->flags & PG_FICTITIOUS) == 0 &&
vm_reserv_level_iffullpop(m) == 0)
moea64_sp_promote(pmap, va, m);
+#endif
return (KERN_SUCCESS);
}
diff --git a/sys/powerpc/aim/moea64_native.c b/sys/powerpc/aim/moea64_native.c
index c352ea6fb6cc..4e729709bf3a 100644
--- a/sys/powerpc/aim/moea64_native.c
+++ b/sys/powerpc/aim/moea64_native.c
@@ -211,6 +211,8 @@ TLBIE(uint64_t vpn, uint64_t oldptehi)
*/
__asm __volatile("li 0, 0 \n tlbie %0, 0" :: "r"(vpn) : "r0", "memory");
__asm __volatile("eieio; tlbsync; ptesync" ::: "memory");
+done:
+
#else
vpn_hi = (uint32_t)(vpn >> 32);
vpn_lo = (uint32_t)vpn;
@@ -235,7 +237,6 @@ TLBIE(uint64_t vpn, uint64_t oldptehi)
intr_restore(intr);
#endif
-done:
/* No barriers or special ops -- taken care of by ptesync above */
if (need_lock)
tlbie_lock = 0;