Fix relative numerical addressing (addr,+N).

As a bonus the patch untangles a bit the logic and makes the code
easier to grasp.

PR:		192108
MFC after:	1 week
When restoring a UFS dump onto a ZFS filesystem, an assertion in
restore was failing because ZFS was reporting a blocksize that was
not a multiple of 1024.  Replace restore's failed assertion with
code that writes restored files in a blocksize that works for
restore (a multiple of 1024) despite being non-optimal for ZFS.

Submitted by: Dmitry Morozovsky
Tested by:    Dmitry Morozovsky
MFC after:    1 week
Add new rule to source address selection algorithm. It prefers address
with better virtual status. Use ifa_preferred() to choose better address.

PR:		187341
Tested by:	des
MFC after:	1 week
files.mips: the kbd driver is used by vt(4) too

Sponsored by:	DARPA, AFRL
Provide a means for loaders to control which file system to use. This
to counteract the default behaviour of always trying each and every
file system until one succeeds, or the open fails. The problem with the
loader is that we've implemented features based on this behavior. The
handling of compressed files is a good example of this. However, it is
in general highly undesirable to not have a one-time probe (or taste
in the geom lingo), followed by something similar to a mount whenever
we (first) read from a device. Everytime we go to the same device, we
can reasonably assume it (still) has the same file system. For file
systems that need to do far more that a trivial read of a super block,
not having something similar to a mount operation is disastrous from
a performance (and thus usability) perspective.

But, again, since we've implemented features based on this stateless
approach, things can get complicated quickly if and when we want to
change this. And yet, we sometimes do need stateful behaviour.

For this reason, this change simply introduces exclusive_file_system.
When set to the fsops of the file system to use, the open call will
only try this file system. Setting it to NULL restores the default
behaviour. It's a low-cost (low-brow?) approach to provide enough
control without re-implementing the guts of the loader.

A good example of when this is useful is when we're trying to load
files out of a container (say, a software packaga) that itself lives
on a file system or is fetched over the network. While opening the
container can be done in the normal stateless manner, once it is
opened, subsequent opens should only consider the container.

Obtained from:	Juniper Networks, Inc.
Follow up r269179 and remove the libsbuf.so.7 library.
Bring in LSI's phase16 - phase18 changes
* Implements Start Stop Unit for SATA direct-attach devices in IR mode to avoid
  data corruption.
* Use CAM_DEV_NOT_THERE instead of CAM_SEL_TIMEOUT and CAM_TID_INVALID

Obtained from:	LSI
MFC after:	2 weeks
Bring in LSI's phase19 changes
* Removed unused mpssas_discovery_timeout function.
* Don't alter mapping boundaries if not raid firmware.
* Check free_busaddr instead of post_busaddr (diff minimisation really)

MFC after:	2 weeks
Commands which encounter a fatal error shouldn't be marked as completed.
Furthermore, provide an indication of the current command so it can be
determined which one actually failed.

Reviewed by:	grehan
Replace 'GNATS' with 'Bugzilla' in the base subversion commit template.

Approved by:	peter
Sponsored by:	The FreeBSD Foundation
In copyright statement correct that the author is me, not Bill Paul.
Remove an unsed variable.
Switch to using counter(9) for the new 64-bit stats kept by armv6 busdma.
Replace the whole license block with the standard one.

Suggested by:	emaste
lower warning level to fix build with gcc
Copy strtolctype.h to sys/cddl/contrib/opensolaris/common/util to keep
the kernel self-contained.

Requested by:	jhb
Fix the example: free the memory that was allocated by getline().
Add an example program to show how to use libpmc from a program.
This particular program attempts to use the TSC to measure how long
certainly libpmc operations take.  Depending on the quality of
the rdtsc() macro on a particular architecture this may work
more or less well.
Only check error if one could have been generated
elfdump: add EM_AARCH64 64-bit ARM machine architecture