Fix comparisons in assertions.

Reported by:	Coverity
Coverity CID:	1130048
Initialize cookie before use.

Reported by:	Coverity
Coverity CID:	1135292
Add libcapsicum and libcasper libraries that were moved from /usr/lib/ to /lib/.

Reviewed by:	glebius
Fix an off-by-one error in r228960.  The maximum priority delta provided
by SCHED_PRI_TICKS should be SCHED_PRI_RANGE - 1 so that the resulting
priority value (before nice adjustment) is between SCHED_PRI_MIN and
SCHED_PRI_MAX, inclusive.

Submitted by:	kib
Reported by:	pho
MFC after:	1 week
Properly report an error instead of panicing when user tries to create
LUN backed by non-disk device, e.g. /dev/null.

Reviewed by:	ken (earlier version)
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
Workaround lldb issue with main module base address

On FreeBSD lldb sometimes reloads the the main module's (executable's)
symbols at the wrong address.  Work around this for now by explicitly
reloading at base_address=0 when it happens.

A proper fix is needed but early testers have reported this issue so
this workaround should allow them to make further progress.

http://llvm.org/bugs/show_bug.cgi?id=17880
cxgbe(4):  T4_SET_SCHED_CLASS and T4_SET_SCHED_QUEUE ioctls to program
scheduling classes in the chip and to bind tx queue(s) to a scheduling
class respectively.  These can be used for various kinds of tx traffic
throttling (to force selected tx queues to drain at a fixed Kbps rate,
or a % of the port's total bandwidth, or at a fixed pps rate, etc.).

Obtained from:	Chelsio
Import lldb as of SVN r196259 (git 3be86e5)

(A number of files not required for the FreeBSD build have been removed.)

Sponsored by:	DARPA, AFRL
Update LLDB to upstream r196259 snapshot

Sponsored by:	DARPA, AFRL
Various updates and tweaks to the wait(2) manpage.

PR:		docs/183904
Submitted by:	Michael Galassi <michaelgalassi@gmail.com>
Reviewed by:	kib, wblock (earlier version)
lldb: Threaded inferior support for FreeBSD

This is in the process of being submitted to the upstream LLDB
repository.  The thread list functionality is modelled in part on
GDBRemoteCommunicationClient.

LLDB bug pr16696 and code review D2267

Sponsored by:	DARPA, AFRL
Add a new sysctl / loader tunable kern.panic_reboot_wait_time which
defaults to PANIC_REBOOT_WAIT_TIME (a long-existing kernel config
setting).  Use this now-variable value in place of the defined constant
to control how long the system waits after a panic before rebooting.
The rc system aggressively caches the contents of /etc/rc.conf in order to
improve boot performance; this produces arguably astonishing (non-)results
if /etc/rc.conf is modified during the boot process.

Since performance considerations make it infeasible to automatically detect
if the cached /etc/rc.conf parameters should be invalidated, provide a
mechanism for explicitly requesting that /etc/rc.conf be reloaded: Catch
SIGALRM and reload /etc/rc.conf if it is received.

Discussed on:	freebsd-rc
MFC after:	3 days
Update LLDB to upstream r196322 snapshot

Upstream revisions of note:
r196298 - Fix use of std::lower_bound
r196322 - Fix log message for new invalidation checks

Sponsored by:	DARPA, AFRL
Only the shared library is installed in /lib/. Static library and symlink
to shared library stays in /usr/lib/. Don't delete them.

Reported by:	jkim
Break the loop once we know we have the SYF_CAPENABLED flag.
svn r251516 resized the buf argument a bit too much.  Pass a hardcoded
size of 6 to humanize_number() to resolve this.

PR:		184405
Submitted by:	jhb
MFC after:	2 weeks
The uaddr, ufunc, umod and usym functions all seem to work as expected on
FreeBSD, so stop hiding them behind a "#if defined(sun)".

Reported by:	Prashanth Kumar <pra_udupi@yahoo.co.in>
Enable some previously-disabled DTrace tests for umod, ufunc and usym. They
expect the installed ksh binary to be named "ksh", which is not the case
when it's installed on FreeBSD via the shells/ksh93 port. Allow for it to be
"ksh93" as well so that the tests can actually pass.
ext2fs: add two new reserved inodes.

According to online documentation [1], Ext4 has two new "special"
inodes so add the new exclude and replica inodes.

Reference:
[1] https://ext4.wiki.kernel.org/index.php/Ext4_Disk_Layout

Reported by:	Mike Ma
MFC after:	3 weeks