summaryrefslogtreecommitdiffstats
path: root/sys/compat/linux/linux_event.c
diff options
context:
space:
mode:
authordchagin <dchagin@FreeBSD.org>2015-05-24 17:40:14 +0000
committerdchagin <dchagin@FreeBSD.org>2015-05-24 17:40:14 +0000
commit65a010b8d9f879fa2f7d886a46dd6dfcb51b3c0b (patch)
tree34adbd35f7bb16b919c0899ce892b97c103964ba /sys/compat/linux/linux_event.c
parent9d4a2ad5951fed165372af9662ab37ecc6c9128a (diff)
downloadFreeBSD-src-65a010b8d9f879fa2f7d886a46dd6dfcb51b3c0b.zip
FreeBSD-src-65a010b8d9f879fa2f7d886a46dd6dfcb51b3c0b.tar.gz
As fo_fill_kinfo() does not check fo_fill_kinfo to NULL
add a fo_fill_kinfo op to eventfdops. Reported by: trinity
Diffstat (limited to 'sys/compat/linux/linux_event.c')
-rw-r--r--sys/compat/linux/linux_event.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/sys/compat/linux/linux_event.c b/sys/compat/linux/linux_event.c
index d405529..fb3ce43 100644
--- a/sys/compat/linux/linux_event.c
+++ b/sys/compat/linux/linux_event.c
@@ -39,6 +39,7 @@ __FBSDID("$FreeBSD$");
#include <sys/mutex.h>
#include <sys/capability.h>
#include <sys/types.h>
+#include <sys/user.h>
#include <sys/file.h>
#include <sys/filedesc.h>
#include <sys/errno.h>
@@ -127,6 +128,7 @@ static fo_poll_t eventfd_poll;
static fo_kqfilter_t eventfd_kqfilter;
static fo_stat_t eventfd_stat;
static fo_close_t eventfd_close;
+static fo_fill_kinfo_t eventfd_fill_kinfo;
static struct fileops eventfdops = {
.fo_read = eventfd_read,
@@ -140,6 +142,7 @@ static struct fileops eventfdops = {
.fo_chmod = invfo_chmod,
.fo_chown = invfo_chown,
.fo_sendfile = invfo_sendfile,
+ .fo_fill_kinfo = eventfd_fill_kinfo,
.fo_flags = DFLAG_PASSABLE
};
@@ -828,3 +831,12 @@ eventfd_stat(struct file *fp, struct stat *st, struct ucred *active_cred,
return (ENXIO);
}
+
+/*ARGSUSED*/
+static int
+eventfd_fill_kinfo(struct file *fp, struct kinfo_file *kif, struct filedesc *fdp)
+{
+
+ kif->kf_type = KF_TYPE_UNKNOWN;
+ return (0);
+}
OpenPOWER on IntegriCloud