MFC: r249406

- Do not bail out if stat(2) fails with ENOENT in the spool directory. This
  happens if another atrm process removes a job while we're scanning through
  the directory.
- While at it, optimize a bit the directory scanning, so that we quit
  looping as soon as all jobs specified in argv have been dealt with.

Approved by:	cognet


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252035 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
Fix two swapped definitions.  Note it is directly committed to this branch
because it fixes r250496, i.e., MFC of r247369 to stable/9.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252038 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC 251617:
Store a reference to the vnode associated with a file descriptor in the
linux_file structure and use it instead of directly accessing td_fpop
when destroying the linux_file structure.  The td_fpop pointer is not
valid when a cdevpriv destructor is run, and the type-specific close
method has already been called, so f_vnode may not be valid (and the
vnode might have been recycled without our own reference).


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252041 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r251439: Remove unneeded reference to link.h (sys/link_elf.h).


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252043 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r251440: use calloc().


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252044 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
share/mk: merge: r241298,243393,249057,251506 from head for bmake support.

Makefile: buildworld etc will be done with make from src tree,
make sure that bmake's -J 15,16 are not passed to it.

Reviewed by: obrien


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252048 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r251959:
Remove stray empty line.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252054 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC 250333: Don't pad disk partition sizes with leading zeros.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252057 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r252010, r252011:

Mark geom_mirror as capable of unmapped i/o

Obtained from:	Netflix


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252063 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC 251637:
Borrow the algorithm from kvm_getprocs() to fix procstat_getprocs() to
handle the case where the process tables grows in between the calls to
fetch the size and fetch the table.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252065 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC: r251444, r251476
Add a "-v" (verbose) option to the gssd daemon, to help
with diagnosis of kerberized NFS mount problems. When set,
messages are sent to syslog() (or fprintf(stderr,...) if
"-d" is also specified) to indicate activity/results of
kgssapi upcalls.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252068 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC: r251445
Document the new "-v" option for the gssd daemon.
This is a content change.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252069 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC: 249514
Point args[0] not at the thread that is ending but at the one that
is starting.  This is in line with practice in OpenSolaris.

Note that this change is only in ULE and not in the 4BSD scheduler.
Once this change settles in (MFC timeout has expired) we'll try it out
on 4BSD as well.

PR:		177706
Submitted by:	Tiwei Bie


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252070 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC	r251212, r251480:

GCC: bring back experimental support for amdfam10/barcelona CPUs.

This is a revised subset of the support initially brought in in r236962
and later reverted. The collateral efects seem to have disappeared but
it is still recommended to set the CPUTYPE with caution.

While here also install AMD intrinsics header ammintrin.h

Reviewed by:	jkim (ages ago)


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252080 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r251723:
The functions are called pci_{msi,msix}_count(), not pci_count_{msi,msix}().


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252087 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r251166:
Add macros which allow one to define SDT probes with six or seven arguments;
they are needed when porting some of the Solaris providers (ip, iscsi, and
tcp in particular).

dtrace_probe() only takes five arguments from the probe site, so we need to
add the appropriate cast to allow for more than five arguments. The extra
arguments are later copied out of dtrace_probe()'s stack frame by
dtrace_getarg() (or the provider-specific getarg method) as needed.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252089 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r246951:
Mark the coretemp(4) sysctls as MPSAFE, ensuring that Giant won't be held
unnecessarily by a user thread waiting to run on a specific CPU after
calling sched_bind().


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252091 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r250599:
Add a remark to the effect that a manually started relearn will always
result in the battery being completely drained, even in transparent learning
mode.


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252093 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r251443: release: Allow empty extra distributions.

For example, WITHOUT_SHAREDOCS= in src.conf creates an empty doc
distribution.

Submitted by:	Kurt Lidl
Tested by:	Kurt Lidl


git-svn-id: svn+ssh://svn.freebsd.org/base/stable/9@252098 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC	r251809, r251952, r252012:

Re-sort ext2fs headers to make things easier to find.

In the ext2fs driver we have a mixture of headers:

- The ext2_ prefixed headers have strong influence from NetBSD
and are carry specific ext2/3/4 information.
- The unprefixed headers are inspired on UFS and carry implementation
specific information.

Do some small adjustments so that the information is easier to
find coming from either UFS or the NetBSD implementation.

Also
- Set MAXMNTLEN nearer to where it is used.
- Move EXT2_LINK_MAX to ext2_dir.h .
- Rename some prefixes in the Block Group Descriptor fields.


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