freebsd with flexible iflib nic queues
Go to file
David Xu 635f917a9d In current implementation, thread cancellation is done in signal handler,
which does not know what is the state of interrupted system call, for
example, open() system call opened a file and the thread is still cancelled,
result is descriptor leak, there are other problems which can cause resource
leak or undeterminable side effect when a thread is cancelled. However, this
is no longer true in new implementation.

  In defering mode, a thread is canceled if cancellation request is pending and
later the thread enters a cancellation point, otherwise, a later
pthread_cancel() just causes SIGCANCEL to be sent to the target thread, and
causes target thread to abort system call, userland code in libthr then checks
cancellation state, and cancels the thread if needed. For example, the
cancellation point open(), the thread may be canceled at start,
but later, if it opened a file descriptor, it is not canceled, this avoids
file handle leak. Another example is read(), a thread may be canceled at start
of the function, but later, if it read some bytes from a socket, the thread
is not canceled, the caller then can decide if it should still enable cancelling
or disable it and continue reading data until it thinks it has read all
bytes of a packet, and keeps a protocol stream in health state, if user ignores
partly reading of a packet without disabling cancellation, then second iteration
of read loop cause the thread to be cancelled.
An exception is that the close() cancellation point always closes a file handle
despite whether the thread is cancelled or not.

  The old mechanism is still kept, for a functions which is not so easily to
fix a cancellation problem, the rough mechanism is used.

Reviewed by: kib@
2010-08-20 05:15:39 +00:00
bin sh: Fix break/continue/return sometimes not skipping the rest of dot script. 2010-08-15 21:06:53 +00:00
cddl Add man pages for the CTF tools. 2010-08-11 18:00:45 +00:00
contrib Remove unneeded casts in inline assembly in contrib/gcc/longlong.h, 2010-08-19 12:59:57 +00:00
crypto More commas 2010-06-01 22:46:57 +00:00
etc Fix silly typo on my part (s/quotas_enable/quota_enable/) 2010-08-14 22:28:07 +00:00
games "whereis netscape" gives empty output for quite a long time already. 2010-08-09 09:26:17 +00:00
gnu Fix buildworld -DNO_CLEAN when using with Perforce, which marks files as 2010-08-12 20:46:49 +00:00
include Style: tabs after #define 2010-08-11 09:29:33 +00:00
kerberos5 Fix a typo. 2010-01-09 18:53:03 +00:00
lib In current implementation, thread cancellation is done in signal handler, 2010-08-20 05:15:39 +00:00
libexec Provide the starting image with the pointer to ELF aux vector. It is 2010-08-17 09:08:28 +00:00
release Merge r114010 of head/usr.bin/login/login.c into PicoBSD's login.c: 2010-08-08 16:55:27 +00:00
rescue Enable liblzma support in libarchive 2010-05-10 15:28:44 +00:00
sbin expand_number(3) takes a uint64_t * now; intmax_t was never correct 2010-08-19 11:20:24 +00:00
secure Fix buildworld -DNO_CLEAN when using with Perforce, which marks files as 2010-08-12 20:46:49 +00:00
share For every instance of '.if ${CC} == "foo"' or '.if ${CC} != "foo"' in 2010-08-17 20:39:28 +00:00
sys If thread set a TDP_WAKEUP for itself, clears the flag and returns EINTR 2010-08-20 04:28:30 +00:00
tools More tests. 2010-08-18 22:06:43 +00:00
usr.bin Revert a minor part of revision 211364: 2010-08-19 22:55:17 +00:00
usr.sbin This patch to pc-sysinstall allows the setting of a new config 2010-08-19 06:11:06 +00:00
COPYRIGHT Happy New Year 2010! :-) 2009-12-31 10:00:37 +00:00
LOCKS Update LOCKS syntax. 2008-06-05 19:47:58 +00:00
MAINTAINERS Add a comment to MAINTAINERS indicating that sbin/routed is in fact 2010-04-10 12:29:09 +00:00
Makefile Connect FDT infrastructure to the build system. 2010-06-13 13:02:43 +00:00
Makefile.inc1 Revert r211436; it was a good idea, but not fully thought out. 2010-08-18 09:18:37 +00:00
Makefile.mips crunchgen now works for mips - so restore building /rescue for it. 2010-08-10 14:36:20 +00:00
ObsoleteFiles.inc Tie up some loose ends r88509 left behind: 2010-08-15 21:25:52 +00:00
README
UPDATING Mention the removal of acpi_aiboost. 2010-07-25 18:32:59 +00:00

This is the top level of the FreeBSD source directory.  This file
was last revised on:
$FreeBSD$

For copyright information, please see the file COPYRIGHT in this
directory (additional copyright information also exists for some
sources in this tree - please see the specific source directories for
more information).

The Makefile in this directory supports a number of targets for
building components (or all) of the FreeBSD source tree, the most
commonly used one being ``world'', which rebuilds and installs
everything in the FreeBSD system from the source tree except the
kernel, the kernel-modules and the contents of /etc.  The ``world''
target should only be used in cases where the source tree has not
changed from the currently running version.  See:
http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/makeworld.html
for more information, including setting make(1) variables.

The ``buildkernel'' and ``installkernel'' targets build and install
the kernel and the modules (see below).  Please see the top of
the Makefile in this directory for more information on the
standard build targets and compile-time flags.

Building a kernel is a somewhat more involved process, documentation
for which can be found at:
   http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig.html
And in the config(8) man page.
Note: If you want to build and install the kernel with the
``buildkernel'' and ``installkernel'' targets, you might need to build
world before.  More information is available in the handbook.

The sample kernel configuration files reside in the sys/<arch>/conf
sub-directory (assuming that you've installed the kernel sources), the
file named GENERIC being the one used to build your initial installation
kernel.  The file NOTES contains entries and documentation for all possible
devices, not just those commonly used.  It is the successor of the ancient
LINT file, but in contrast to LINT, it is not buildable as a kernel but a
pure reference and documentation file.


Source Roadmap:
---------------
bin		System/user commands.

contrib		Packages contributed by 3rd parties.

crypto		Cryptography stuff (see crypto/README).

etc		Template files for /etc.

games		Amusements.

gnu		Various commands and libraries under the GNU Public License.
		Please see gnu/COPYING* for more information.

include		System include files.

kerberos5	Kerberos5 (Heimdal) package.

lib		System libraries.

libexec		System daemons.

release		Release building Makefile & associated tools.

rescue		Build system for statically linked /rescue utilities.

sbin		System commands.

secure		Cryptographic libraries and commands.

share		Shared resources.

sys		Kernel sources.

tools		Utilities for regression testing and miscellaneous tasks.

usr.bin		User commands.

usr.sbin	System administration commands.


For information on synchronizing your source tree with one or more of
the FreeBSD Project's development branches, please see:

  http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/synching.html