KNOTE man page on NetBSD

Man page or keyword search:  
man Server   9087 pages
apropos Keyword Search (all sections)
Output format
NetBSD logo
[printable version]

KNOTE(9)		 BSD Kernel Developer's Manual		      KNOTE(9)

NAME
     knote, KNOTE — raise kernel event

SYNOPSIS
     #include <sys/event.h>

     void
     knote(struct klist *list, long hint);

     KNOTE(struct klist *list, long hint);

DESCRIPTION
     The knote() function provides a hook into the kqueue kernel event notifi‐
     cation mechanism to allow sections of the kernel to raise a kernel event
     in the form of a ‘knote’, which is a struct knote as defined in
     <sys/event.h>.

     knote() takes a singly linked list of knotes, along with a hint (which is
     passed to the appropriate filter routine).	 knote() then walks the list
     making calls to the filter routine for each knote.	 As each knote con‐
     tains a reference to the data structure that it is attached to, the fil‐
     ter may choose to examine the data structure in deciding whether an event
     should be reported.  The hint is used to pass in additional information,
     which may not be present in the data structure that the filter examines.

     If the filter decides that the event should be returned, it returns a
     non-zero value and knote() links the knote onto the tail end of the
     active list in the corresponding kqueue for the application to retrieve.
     If the knote is already on the active list, no action is taken, but the
     call to the filter occurs in order to provide an opportunity for the fil‐
     ter to record the activity.

     knote() must not be called from interrupt contexts running at an inter‐
     rupt priority level higher than splsched().

     KNOTE() is a macro that calls knote(list, hint) if list is not empty.

SEE ALSO
     kqueue(2), kfilter_register(9)

HISTORY
     The knote() and KNOTE() functions first appeared in FreeBSD 4.1, and then
     in NetBSD 2.0.

AUTHORS
     The kqueue() system was written by Jonathan Lemon ⟨jlemon@FreeBSD.org⟩.

BSD			       February 18, 2004			   BSD
[top]
                             _         _         _ 
                            | |       | |       | |     
                            | |       | |       | |     
                         __ | | __ __ | | __ __ | | __  
                         \ \| |/ / \ \| |/ / \ \| |/ /  
                          \ \ / /   \ \ / /   \ \ / /   
                           \   /     \   /     \   /    
                            \_/       \_/       \_/ 
More information is available in HTML format for server NetBSD

List of man pages available for NetBSD

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net