From ccfb8acd708bf179fae5b45631bb259f4de2fefe Mon Sep 17 00:00:00 2001 From: Mitchell Horne Date: Wed, 12 Feb 2020 13:58:37 +0000 Subject: [PATCH] RISC-V: un-ifdef vm.kvm_size and vm.kvm_free Fix formatting and add CTLFLAG_MPSAFE. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D23522 --- sys/riscv/riscv/pmap.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/sys/riscv/riscv/pmap.c b/sys/riscv/riscv/pmap.c index ffe077ead4b6..6e9c4cb77c39 100644 --- a/sys/riscv/riscv/pmap.c +++ b/sys/riscv/riscv/pmap.c @@ -1436,7 +1436,6 @@ pmap_release(pmap_t pmap) vm_page_free(m); } -#if 0 static int kvm_size(SYSCTL_HANDLER_ARGS) { @@ -1444,8 +1443,9 @@ kvm_size(SYSCTL_HANDLER_ARGS) return sysctl_handle_long(oidp, &ksize, 0, req); } -SYSCTL_PROC(_vm, OID_AUTO, kvm_size, CTLTYPE_LONG|CTLFLAG_RD, - 0, 0, kvm_size, "LU", "Size of KVM"); +SYSCTL_PROC(_vm, OID_AUTO, kvm_size, CTLTYPE_LONG | CTLFLAG_RD | CTLFLAG_MPSAFE, + 0, 0, kvm_size, "LU", + "Size of KVM"); static int kvm_free(SYSCTL_HANDLER_ARGS) @@ -1454,9 +1454,9 @@ kvm_free(SYSCTL_HANDLER_ARGS) return sysctl_handle_long(oidp, &kfree, 0, req); } -SYSCTL_PROC(_vm, OID_AUTO, kvm_free, CTLTYPE_LONG|CTLFLAG_RD, - 0, 0, kvm_free, "LU", "Amount of KVM free"); -#endif /* 0 */ +SYSCTL_PROC(_vm, OID_AUTO, kvm_free, CTLTYPE_LONG | CTLFLAG_RD | CTLFLAG_MPSAFE, + 0, 0, kvm_free, "LU", + "Amount of KVM free"); /* * grow the number of kernel page table entries, if needed