aboutsummaryrefslogtreecommitdiff
path: root/sys/sys/racct.h
diff options
context:
space:
mode:
authorEdward Tomasz Napierala <trasz@FreeBSD.org>2015-11-08 18:08:31 +0000
committerEdward Tomasz Napierala <trasz@FreeBSD.org>2015-11-08 18:08:31 +0000
commit2b4035eeb68663604f064304a079ce0a36d1e7b6 (patch)
tree95f41827273c285d633e6765ed8247c461f67957 /sys/sys/racct.h
parent6a833a7a2cac3545256910f8f6c497c5c12d795f (diff)
downloadsrc-2b4035eeb68663604f064304a079ce0a36d1e7b6.tar.gz
src-2b4035eeb68663604f064304a079ce0a36d1e7b6.zip
Speed up rctl(8) rule retrieval; the difference shows mostly in "rctl -n",
as otherwise most of the time is spent resolving UIDs to names. Reviewed by: mjg@ MFC after: 1 month Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D4059
Notes
Notes: svn path=/head/; revision=290551
Diffstat (limited to 'sys/sys/racct.h')
-rw-r--r--sys/sys/racct.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/sys/racct.h b/sys/sys/racct.h
index 313d5d05de96..307585680ca0 100644
--- a/sys/sys/racct.h
+++ b/sys/sys/racct.h
@@ -37,9 +37,10 @@
#define _RACCT_H_
#include <sys/cdefs.h>
-#include <sys/stdint.h>
-#include <sys/queue.h>
#include <sys/types.h>
+#include <sys/queue.h>
+#include <sys/stdint.h>
+#include <sys/sysctl.h>
struct proc;
struct rctl_rule_link;
@@ -146,6 +147,8 @@ struct racct {
LIST_HEAD(, rctl_rule_link) r_rule_links;
};
+SYSCTL_DECL(_kern_racct);
+
#ifdef RACCT
int racct_add(struct proc *p, int resource, uint64_t amount);