sysctl: mark more nodes as MPSAFE
vm.kvm_size and vm.kvm_free are read only and marked as MPSAFE on i386 already. Mark them as that on amd64 and arm64 too to avoid locking Giant. Reviewed by: kib (mentor) Approved by: kib (mentor) Differential Revision: https://reviews.freebsd.org/D23039
This commit is contained in:
parent
6c110e8611
commit
a1d7296784
@ -4072,8 +4072,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)
|
||||
@ -4082,8 +4083,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");
|
||||
SYSCTL_PROC(_vm, OID_AUTO, kvm_free, CTLTYPE_LONG | CTLFLAG_RD | CTLFLAG_MPSAFE,
|
||||
0, 0, kvm_free, "LU",
|
||||
"Amount of KVM free");
|
||||
|
||||
/*
|
||||
* Allocate physical memory for the vm_page array and map it into KVA,
|
||||
|
@ -1845,8 +1845,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)
|
||||
@ -1855,8 +1856,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");
|
||||
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
|
||||
|
Loading…
Reference in New Issue
Block a user