Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/kqueue]: src/sys g/c KFILTER_UNREGISTER, KFILTER_REGISTER



details:   https://anonhg.NetBSD.org/src/rev/a611e0192163
branches:  kqueue
changeset: 512459:a611e0192163
user:      jdolecek <jdolecek%NetBSD.org@localhost>
date:      Tue Apr 09 06:19:51 2002 +0000

description:
g/c KFILTER_UNREGISTER, KFILTER_REGISTER

diffstat:

 sys/kern/kern_event.c |  24 +-----------------------
 sys/sys/event.h       |  18 +++---------------
 2 files changed, 4 insertions(+), 38 deletions(-)

diffs (73 lines):

diff -r 6bd68630d085 -r a611e0192163 sys/kern/kern_event.c
--- a/sys/kern/kern_event.c     Mon Mar 18 21:35:32 2002 +0000
+++ b/sys/kern/kern_event.c     Tue Apr 09 06:19:51 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: kern_event.c,v 1.1.1.1.2.11 2002/03/17 19:53:07 jdolecek Exp $ */
+/*     $NetBSD: kern_event.c,v 1.1.1.1.2.12 2002/04/09 06:19:52 jdolecek Exp $ */
 /*-
  * Copyright (c) 1999,2000,2001 Jonathan Lemon <jlemon%FreeBSD.org@localhost>
  * All rights reserved.
@@ -952,28 +952,6 @@
                FREE(name, M_KEVENT);
                break;
 
-#if 1          /* XXXLUKEM - debug only; remove from production code */
-       case KFILTER_REGISTER:
-       case KFILTER_UNREGISTER:
-               MALLOC(name, char *, KFILTER_MAXNAME, M_KEVENT, M_WAITOK);
-               error = copyinstr(km->name, name, KFILTER_MAXNAME, NULL);
-               if (error) {
-                       FREE(name, M_KEVENT);
-                       break;
-               }
-               if (com == KFILTER_REGISTER) {
-                       kfilter = kfilter_byfilter(km->filter);
-                       if (kfilter != NULL) {
-                               error = kfilter_register(name,
-                                   kfilter->filtops, &km->filter);
-                       } else
-                               error = ENOENT;
-               } else
-                       error = kfilter_unregister(name);
-               FREE(name, M_KEVENT);
-               break;
-#endif
-
        default:
                error = ENOTTY;
 
diff -r 6bd68630d085 -r a611e0192163 sys/sys/event.h
--- a/sys/sys/event.h   Mon Mar 18 21:35:32 2002 +0000
+++ b/sys/sys/event.h   Tue Apr 09 06:19:51 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: event.h,v 1.1.1.1.2.4 2001/09/08 16:48:17 thorpej Exp $        */
+/*     $NetBSD: event.h,v 1.1.1.1.2.5 2002/04/09 06:19:51 jdolecek Exp $       */
 /*-
  * Copyright (c) 1999,2000,2001 Jonathan Lemon <jlemon%FreeBSD.org@localhost>
  * All rights reserved.
@@ -127,23 +127,11 @@
        uint32_t        filter;         /* filter to lookup or return */
 };
 
-                                       /* map filter to name (max size len) */ 
+/* map filter to name (max size len) */ 
 #define KFILTER_BYFILTER       _IOWR('k', 0, struct kfilter_mapping)
-                                       /* map name to filter (len ignored) */
+/* map name to filter (len ignored) */
 #define KFILTER_BYNAME         _IOWR('k', 1, struct kfilter_mapping)
 
-#if 1  /* XXXLUKEM - debug only; remove from production code */
-                                       /*
-                                        * register name, mapping filtops
-                                        * to those of filter, returning new
-                                        * number in filter
-                                        */
-#define KFILTER_REGISTER       _IOWR('k', 2, struct kfilter_mapping)
-                                       /* unregister name */
-#define KFILTER_UNREGISTER     _IOWR('k', 3, struct kfilter_mapping)
-#endif
-
-
 #ifdef _KERNEL
 
 #define        KNOTE(list, hint)       if ((list) != NULL) knote(list, hint)



Home | Main Index | Thread Index | Old Index