Updates to documentation

Switch polling mechanism back to the non-debug version
This commit is contained in:
Mark Riddoch 2013-06-27 13:09:21 +02:00
parent cfe01d0940
commit 2ffe34d6d2
5 changed files with 21 additions and 3 deletions

View File

@ -25,7 +25,7 @@
#include <atomic.h>
/**
* @file poll.c - Abraction of the epoll functionality
* @file poll.c - Abstraction of the epoll functionality
*
* @verbatim
* Revision History
@ -104,7 +104,7 @@ struct epoll_event ev;
return epoll_ctl(epoll_fd, EPOLL_CTL_DEL, dcb->fd, &ev);
}
#define BLOCKINGPOLL 1 /* Set BLOCKING POLL to 1 if using a single thread and to make
#define BLOCKINGPOLL 0 /* Set BLOCKING POLL to 1 if using a single thread and to make
* debugging easier.
*/
/**
@ -112,6 +112,20 @@ struct epoll_event ev;
*
* This routine does the polling and despatches of IO events
* to the DCB's
*
* The routine will loop as long as the variable "shutdown" is set to zero,
* setting this to a non-zero value will cause the polling loop to return.
*
* There are two options for the polling, a debug option that is only useful if
* you have a single thread. This blocks in epoll_wait until an event occurs.
*
* The non-debug option does an epoll with a time out. This allows the checking of
* shutdown value to be checked in all threads. The algorithm for polling in this
* mode is to do a poll with no-wait, if no events are detected then the poll is
* repeated with a time out. This allows for a quick check before making the call
* with timeout. The call with the timeout differs in that the Linux scheduler may
* deschedule a process if a timeout is included, but will not do this if a 0 timeout
* value is given. this improves performance when the gateway is under heavy load.
*/
void
poll_waitevents()

View File

@ -101,6 +101,7 @@ GetModuleObject()
* within the gateway.
*
* @param service The service this router is being create for
* @param options Any array of options for the query router
*
* @return The instance data for this new instance
*/

View File

@ -166,7 +166,8 @@ static struct {
* Convert a string argument to a numeric, observing prefixes
* for number bases, e.g. 0x for hex, 0 for octal
*
* @param arg The string representation of the argument
* @param arg The string representation of the argument
* @param arg_type The target type for the argument
* @return The argument as a long integer
*/
static unsigned long

View File

@ -121,6 +121,7 @@ GetModuleObject()
* within the gateway.
*
* @param service The service this router is being create for
* @param options An array of options for this query router
*
* @return The instance data for this new instance
*/

View File

@ -69,6 +69,7 @@ GetModuleObject()
* within the gateway.
*
* @param service The service this router is being create for
* @param options The options for this query router
*
* @return The instance data for this new instance
*/