Module Name: src Committed By: thorpej Date: Sun Sep 26 03:42:54 UTC 2021
Modified Files: src/sys/kern: sys_eventfd.c sys_timerfd.c Log Message: eventfd and timerfd have MPSAFE kq filterops. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/kern/sys_eventfd.c cvs rdiff -u -r1.4 -r1.5 src/sys/kern/sys_timerfd.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/kern/sys_eventfd.c diff -u src/sys/kern/sys_eventfd.c:1.5 src/sys/kern/sys_eventfd.c:1.6 --- src/sys/kern/sys_eventfd.c:1.5 Sun Sep 26 01:16:10 2021 +++ src/sys/kern/sys_eventfd.c Sun Sep 26 03:42:54 2021 @@ -1,4 +1,4 @@ -/* $NetBSD: sys_eventfd.c,v 1.5 2021/09/26 01:16:10 thorpej Exp $ */ +/* $NetBSD: sys_eventfd.c,v 1.6 2021/09/26 03:42:54 thorpej Exp $ */ /*- * Copyright (c) 2020 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: sys_eventfd.c,v 1.5 2021/09/26 01:16:10 thorpej Exp $"); +__KERNEL_RCSID(0, "$NetBSD: sys_eventfd.c,v 1.6 2021/09/26 03:42:54 thorpej Exp $"); /* * eventfd @@ -425,7 +425,7 @@ eventfd_filt_read(struct knote * const k } static const struct filterops eventfd_read_filterops = { - .f_flags = FILTEROP_ISFD, + .f_flags = FILTEROP_ISFD | FILTEROP_MPSAFE, .f_detach = eventfd_filt_read_detach, .f_event = eventfd_filt_read, }; @@ -462,7 +462,7 @@ eventfd_filt_write(struct knote * const } static const struct filterops eventfd_write_filterops = { - .f_flags = FILTEROP_ISFD, + .f_flags = FILTEROP_ISFD | FILTEROP_MPSAFE, .f_detach = eventfd_filt_write_detach, .f_event = eventfd_filt_write, }; Index: src/sys/kern/sys_timerfd.c diff -u src/sys/kern/sys_timerfd.c:1.4 src/sys/kern/sys_timerfd.c:1.5 --- src/sys/kern/sys_timerfd.c:1.4 Sun Sep 26 01:16:10 2021 +++ src/sys/kern/sys_timerfd.c Sun Sep 26 03:42:54 2021 @@ -1,4 +1,4 @@ -/* $NetBSD: sys_timerfd.c,v 1.4 2021/09/26 01:16:10 thorpej Exp $ */ +/* $NetBSD: sys_timerfd.c,v 1.5 2021/09/26 03:42:54 thorpej Exp $ */ /*- * Copyright (c) 2020 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: sys_timerfd.c,v 1.4 2021/09/26 01:16:10 thorpej Exp $"); +__KERNEL_RCSID(0, "$NetBSD: sys_timerfd.c,v 1.5 2021/09/26 03:42:54 thorpej Exp $"); /* * timerfd @@ -421,7 +421,7 @@ timerfd_filt_read(struct knote * const k } static const struct filterops timerfd_read_filterops = { - .f_flags = FILTEROP_ISFD, + .f_flags = FILTEROP_ISFD | FILTEROP_MPSAFE, .f_detach = timerfd_filt_read_detach, .f_event = timerfd_filt_read, };