add a method to set/clear the VMF field in the TX descriptor.

Obtained from:	Qualcomm Atheros


git-svn-id: svn://svn.freebsd.org/base/head@247774 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
If we're using a PIPT L2 cache, only merge 2 segments if both the virtual
and the physical addreses are contiguous.

Submitted by:	Thomas Skibo <ThomasSkibo@sbcglobal.net>


git-svn-id: svn://svn.freebsd.org/base/head@247776 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
- Make callout(9) tickless, relying on eventtimers(4) as backend for
precise time event generation. This greatly improves granularity of
callouts which are not anymore constrained to wait next tick to be
scheduled.
- Extend the callout KPI introducing a set of callout_reset_sbt* functions,
which take a sbintime_t as timeout argument. The new KPI also offers a
way for consumers to specify precision tolerance they allow, so that
callout can coalesce events and reduce number of interrupts as well as
potentially avoid scheduling a SWI thread.
- Introduce support for dispatching callouts directly from hardware
interrupt context, specifying an additional flag. This feature should be
used carefully, as long as interrupt context has some limitations
(e.g. no sleeping locks can be held).
- Enhance mechanisms to gather informations about callwheel, introducing
a new sysctl to obtain stats.

This change breaks the KBI. struct callout fields has been changed, in
particular 'int ticks' (4 bytes) has been replaced with 'sbintime_t'
(8 bytes) and another 'sbintime_t' field was added for precision.

Together with:	mav
Reviewed by:	attilio, bde, luigi, phk
Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo (amd64, sparc64), marius (sparc64), ian (arm),
		markj (amd64), mav, Fabian Keil


git-svn-id: svn://svn.freebsd.org/base/head@247777 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFcalloutng (r244355):
Make loadavg calculation callout direct. There are several reasons for it:
 - it is very simple and doesn't worth context switch to SWI;
 - since SWI is no longer used here, we can remove twelve years old hack,
excluding this SWI from from the loadavg statistics;
 - it fixes problem when eventtimer (HPET) shares interrupt with some other
device, and that interrupt thread counted as permanent loadavg of 1; now
loadavg accounted before that interrupt thread is scheduled.

Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo, marius, ian, Fabian Keil, markj


git-svn-id: svn://svn.freebsd.org/base/head@247778 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
Import libyaml as libbsdyml (private brand name)

LibYAML is a YAML 1.1 parser and emitter under MIT license which will
soon be used by the pkg boostrap (usr.bin/pkg) and bhyve

Reviewed by:	roberto, antoine


git-svn-id: svn://svn.freebsd.org/base/head@247779 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
Fix VERBOSE reporting on results when removing _PATH_LOCALTIME for UTC option.

PR:		bin/164976
Submitted by:	dteske


git-svn-id: svn://svn.freebsd.org/base/head@247780 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFcalloutng:
Convert sleepqueue(9) bits to the new callout KPI. Take advantage of
the possibility to run callback directly from hw interrupt context.

Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo, marius, ian, markj, Fabian Keil


git-svn-id: svn://svn.freebsd.org/base/head@247783 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
Style fix: remove useless braces. Sorry, my bad.

Submitted by:	bde


git-svn-id: svn://svn.freebsd.org/base/head@247784 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFcalloutng:
Extend condvar(9) KPI introducing sbt variant of cv_timedwait. This
rely on the previously committed sleepq_set_timeout_sbt().

Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo, marius, ian, markj, Fabian Keil


git-svn-id: svn://svn.freebsd.org/base/head@247785 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFcalloutng:
Introduce sbt variants of msleep(), msleep_spin(), pause(), tsleep() in
the KPI, allowing to specify timeout in 'sbintime_t' rather than ticks.

Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo, marius, ian, markj, Fabian Keil


git-svn-id: svn://svn.freebsd.org/base/head@247787 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
Merge from vmcontention:
As vm objects are type-stable there is no need to initialize the
resident splay tree pointer and the cache splay tree pointer in
_vm_object_allocate() but this could be done in the init UMA zone
handler.

The destructor UMA zone handler, will further check if the condition is
retained at every destruction and catch for bugs.

Sponsored by:	EMC / Isilon storage division
Submitted by:	alc


git-svn-id: svn://svn.freebsd.org/base/head@247788 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
Modernize some portions of the ports man page.
Stop documenting other operating systems's default patha

Approved by:	bcr (mentor)


git-svn-id: svn://svn.freebsd.org/base/head@247791 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFcalloutng (r244249, r244306 by mav):
- Switch syscons from timeout() to callout_reset_flags() and specify that
precision is not important there -- anything from 20 to 30Hz will be fine.
- Reduce syscons "refresh" rate to 1-2Hz when console is in graphics mode
and there is nothing to do except some polling for keyboard.  Text mode
refresh would also be nice to have adaptive, but this change at least
should help laptop users who running X.

Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo, marius, ian, markj, Fabian Keil


git-svn-id: svn://svn.freebsd.org/base/head@247792 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
Fix build with DIAGNOSTIC/CALLOUT_PROFILING options turned on.

Reported by:	kib, David Wolfskill <david at catwhisker dot org>
Pointy-hat to:	davide


git-svn-id: svn://svn.freebsd.org/base/head@247793 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFcalloutng:
kern_nanosleep() is now converted to use tsleep_sbt(). With this change
nanosleep() and usleep() can handle sub-tick precision for timeouts.
Also, try to help coalesce of events passing as argument to tsleep_bt()
a precision value calculated as a percentage of the sleep time.
This percentage is default 5%, but it can tuned according to users
need via the sysctl interface.

Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo, marius, ian, markj, Fabian Keil


git-svn-id: svn://svn.freebsd.org/base/head@247797 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFcalloutng (r244255 by mav, with minor changes):
Specify that syslog doesn't need exactly 5 wakeups per second.

Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo, marius, ian, markj, Fabian Keil


git-svn-id: svn://svn.freebsd.org/base/head@247798 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFcalloutng (r236314 by mav):
Specify that wakeup rate of 7.5-10Hz is enough for yarrow harvesting
thread.

Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo, marius, ian, markj, Fabian Keil


git-svn-id: svn://svn.freebsd.org/base/head@247799 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFcalloutng (r244251 with minor changes):
Specify that precision of 0.5s is enough for resource limitation.

Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo, marius, ian, markj, Fabian Keil


git-svn-id: svn://svn.freebsd.org/base/head@247800 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFcalloutng:
Fix kern_select() and sys_poll() so that they can handle sub-tick
precision for timeouts (in the same fashion it was done for nanosleep()
in r247797).

Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo, marius, ian, markj, Fabian Keil


git-svn-id: svn://svn.freebsd.org/base/head@247801 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFcalloutng:
- Rewrite kevent() timeout implementation to allow sub-tick precision.
- Make the interval timings for EVFILT_TIMER more accurate. This also
removes an hack introduced in r238424.

Sponsored by:	Google Summer of Code 2012, iXsystems inc.
Tested by:	flo, marius, ian, markj, Fabian Keil


git-svn-id: svn://svn.freebsd.org/base/head@247804 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f