MFC r268460 by ray:

  Fix inconsistent token parameters for kbd_allocate() and kbd_release()
  in vt(4).

PR:		191306
Submitted by:	jau789 at gmail.com
Sponsored by:	The FreeBSD Foundation


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@268942 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC	r268642:
libc/gen: small updates to code originating at OpenBSD

arc4random.c
- CVS rev. 1.22
Change arc4random_uniform() to calculate ``2**32 % upper_bound'' as
``-upper_bound % upper_bound''. Simplifies the code and makes it the
same on both ILP32 and LP64 architectures, and also slightly faster on
LP64 architectures by using a 32-bit remainder instead of a 64-bit
remainder.
- CVS rev. 1.23
Spacing

readpassphrase.c
-CVS rev. v 1.24
most obvious unsigned char casts for ctype

Obtained from:	OpenBSD


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@268963 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC	r268644:
libc/stdlib: Minor cleanups to code originating in NetBSD

Mostly ANSIfication and typos.

Obtained from:	NetBSD


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@268965 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC	r268798, r268799, r268801:
grep: Fix type.
grep: fix some memory leaks.

queue.c (CVS Rev. 1.4. 1.5)
Fix memory leaks.
NULL does not need a cast.

grep.c (CVS Rev. 1.6)
Use the more portable getline.

Obtained from:	NetBSD


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@268967 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r267812 (hrs): Fix ifname normalization. ifconfig_IF_alias{es,N} did not
work if ifname has any of [.-/+].

PR:		conf/191961
Spotted by:	jhay
MFC after:	3 days


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@269028 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r266475 (rea): Fix warning messages after r252015

$alias used to hold alias number, but now it carries full variable name,
so messages were tuned to account for that.

Other fixes:
 - eliminate unneeded double spaces;
 - tell user where inet/inet6 keywords are expected to be.

Reviewed by:	hrs


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@269034 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC 267883:
Expand r261243 even further and ignore any I/O port resources assigned to
PCI root bridges except for the one known-valid case on x86 where bridges
claim the I/O port registers used for PCI config space access.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@269038 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r262329:
Define the KM_NORMALPRI flag for kmem_alloc(), as it is used in some
upstream DTrace code.

MFC r262330:
1452 DTrace buffer autoscaling should be less violent

illumos/illumos-gate@6fb4854bed54ce82bd8610896b64ddebcd4af706


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@269040 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
Sync with 2014060201 which adds IPv6 to b.root-servers.net

Note that this is a direct commit to stable/9 as this file
is no longer in HEAD.

Sponsored by: DK Hostmaster A/S


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@269049 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r268384:
When the lock was stolen from us, retry the whole lock sequence in kernel,
instead of returning EINTR.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@269057 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r268420:
Remove IO_SYNC flag when writing extended file attributes on ZFS.

While it is possible to create and write file, modify its permissions, etc.
without ever doing sync, it looks odd that it is required for setting
extended file attributes on ZFS.  UFS does not do sync there too.

Samba uses those extended attributes to store some its data, and doing it
synchronously by many times reduces file creation performance for systems
without SLOG device.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@269062 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r268640 and r268989.

r268640:
Allow multi-byte reads in the private CHELSIO_T4_GET_I2C ioctl.  The
firmware allows up to 48B to be read this way but the driver limits
itself to 8B at a time to remain compatible with old cxgbetool
binaries.

r268989:
Add missing newline to an error message.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@269083 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
Partial MFC of r268466:
Add a knob to disable the residency calculation for kern.proc.vmmap.

Tested by:	"Ivan A. Kosarev" <ikosarev@accesssoftek.com>


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@269090 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r269081:
Fix typo.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@269157 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f