aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/hwpmc
diff options
context:
space:
mode:
authorRobert Watson <rwatson@FreeBSD.org>2011-08-11 12:30:23 +0000
committerRobert Watson <rwatson@FreeBSD.org>2011-08-11 12:30:23 +0000
commita9d2f8d84f69e98100b5746816b35666bcf992ac (patch)
tree4b691c0e209134040c3cf5ce75660b61282933d0 /sys/dev/hwpmc
parent2ffd5fdcc433626b1adb061119cd412f9b3020e9 (diff)
Notes
Diffstat (limited to 'sys/dev/hwpmc')
-rw-r--r--sys/dev/hwpmc/hwpmc_logging.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/dev/hwpmc/hwpmc_logging.c b/sys/dev/hwpmc/hwpmc_logging.c
index 633c6f953b6e..b85572a3c86f 100644
--- a/sys/dev/hwpmc/hwpmc_logging.c
+++ b/sys/dev/hwpmc/hwpmc_logging.c
@@ -37,6 +37,7 @@
__FBSDID("$FreeBSD$");
#include <sys/param.h>
+#include <sys/capability.h>
#include <sys/file.h>
#include <sys/kernel.h>
#include <sys/kthread.h>
@@ -589,7 +590,7 @@ pmclog_configure_log(struct pmc_mdep *md, struct pmc_owner *po, int logfd)
po->po_file));
/* get a reference to the file state */
- error = fget_write(curthread, logfd, &po->po_file);
+ error = fget_write(curthread, logfd, CAP_WRITE, &po->po_file);
if (error)
goto error;