From 57e2ebdc084643a0b48e7e8b718db5aea432ce6a Mon Sep 17 00:00:00 2001 From: Edward Tomasz Napierala Date: Sun, 13 Dec 2015 11:08:29 +0000 Subject: [PATCH] Avoid useless relocking. MFC after: 1 month Sponsored by: The FreeBSD Foundation --- sys/kern/kern_racct.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/kern/kern_racct.c b/sys/kern/kern_racct.c index 941da4288cbe..f69175e8e213 100644 --- a/sys/kern/kern_racct.c +++ b/sys/kern/kern_racct.c @@ -631,8 +631,8 @@ racct_add_force(struct proc *p, int resource, uint64_t amount) mtx_lock(&racct_lock); racct_adjust_resource(p->p_racct, resource, amount); + racct_add_cred_locked(p->p_ucred, resource, amount); mtx_unlock(&racct_lock); - racct_add_cred(p->p_ucred, resource, amount); } static int