Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/x86/x86 adjust the pmap_check_inuse() fix to avoid ...
details: https://anonhg.NetBSD.org/src/rev/09107726a6f0
branches: trunk
changeset: 320914:09107726a6f0
user: jdolecek <jdolecek%NetBSD.org@localhost>
date: Sun Mar 04 23:25:35 2018 +0000
description:
adjust the pmap_check_inuse() fix to avoid #ifdef
diffstat:
sys/arch/x86/x86/pmap.c | 9 +++------
1 files changed, 3 insertions(+), 6 deletions(-)
diffs (35 lines):
diff -r ea5fe5cc506a -r 09107726a6f0 sys/arch/x86/x86/pmap.c
--- a/sys/arch/x86/x86/pmap.c Sun Mar 04 23:07:58 2018 +0000
+++ b/sys/arch/x86/x86/pmap.c Sun Mar 04 23:25:35 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.c,v 1.288 2018/03/04 23:07:58 kre Exp $ */
+/* $NetBSD: pmap.c,v 1.289 2018/03/04 23:25:35 jdolecek Exp $ */
/*
* Copyright (c) 2008, 2010, 2016, 2017 The NetBSD Foundation, Inc.
@@ -170,7 +170,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.288 2018/03/04 23:07:58 kre Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.289 2018/03/04 23:25:35 jdolecek Exp $");
#include "opt_user_ldt.h"
#include "opt_lockdebug.h"
@@ -2550,15 +2550,12 @@
#ifdef DIAGNOSTIC
CPU_INFO_ITERATOR cii;
struct cpu_info *ci;
-#if defined(XEN) && defined(__x86_64__)
- int i;
-#endif
for (CPU_INFO_FOREACH(cii, ci)) {
if (ci->ci_pmap == pmap)
panic("destroying pmap being used");
#if defined(XEN) && defined(__x86_64__)
- for (i = 0; i < PDIR_SLOT_PTE; i++) {
+ for (int i = 0; i < PDIR_SLOT_PTE; i++) {
if (pmap->pm_pdir[i] != 0 &&
ci->ci_kpm_pdir[i] == pmap->pm_pdir[i]) {
printf("pmap_destroy(%p) pmap_kernel %p "
Home |
Main Index |
Thread Index |
Old Index