]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/log
FreeBSD/stable/10.git
7 years agoMFC r306714:
sevan [Mon, 10 Oct 2016 15:48:40 +0000 (15:48 +0000)]
MFC r306714:
Document where chio(1) originated from & which version of FreeBSD first
included it.

PR:           211776
Approved by:  bcr (mentor)
Differential Revision:        https://reviews.freebsd.org/D8104

git-svn-id: svn://svn.freebsd.org/base/stable/10@306971 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306584:
sevan [Mon, 10 Oct 2016 15:44:42 +0000 (15:44 +0000)]
MFC r306584:
Move the description of CHANGER variable to ENVIRONMENT section rather than
in the DESCRIPTION section.
From OpenBSD src/bin/chio/chio.1 r1.23

PR:           212158
Approved by:  bjk
Obtained from:        OpenBSD
Differential Revision:        https://reviews.freebsd.org/D8117

git-svn-id: svn://svn.freebsd.org/base/stable/10@306968 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC: r306318
tijl [Mon, 10 Oct 2016 11:53:54 +0000 (11:53 +0000)]
MFC: r306318

Allocate a zeroed LDT.

Failing to do this might result in the LDT appearing to run out of free
descriptors because of random junk in the descriptor's 'sd_type' field.

http://lists.freebsd.org/pipermail/freebsd-amd64/2014-May/016088.html

PR:             212639
Submitted by:   wheelcomplex@gmail.com

git-svn-id: svn://svn.freebsd.org/base/stable/10@306961 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306478:
hselasky [Mon, 10 Oct 2016 11:47:29 +0000 (11:47 +0000)]
MFC r306478:
Add new USB ID.

While at it remove some whitespaces.

Submitted by: Jose Luis Duran <jlduran@gmail.com>
PR: 213110

git-svn-id: svn://svn.freebsd.org/base/stable/10@306957 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306454:
hselasky [Mon, 10 Oct 2016 11:43:55 +0000 (11:43 +0000)]
MFC r306454:
Set hardware stats flag to avoid double counting the number of incoming bytes.

Found by: Ben RUBSON <ben.rubson@gmail.com>
Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306955 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306453:
hselasky [Mon, 10 Oct 2016 11:40:52 +0000 (11:40 +0000)]
MFC r306453:
Set hardware stats flag to avoid double counting the number of incoming bytes.

Found by: Ben RUBSON <ben.rubson@gmail.com>
Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306953 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306451:
hselasky [Mon, 10 Oct 2016 11:34:51 +0000 (11:34 +0000)]
MFC r306451:
The IORESOURCE_XXX defines should resemble a bitmask while SYS_RES_XXX
are not bitmasks. Fix return value of pci_resource_flags() to reflect
this change.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306950 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306441 and r306634:
hselasky [Mon, 10 Oct 2016 11:25:11 +0000 (11:25 +0000)]
MFC r306441 and r306634:
While draining a timeout task prevent the taskqueue_enqueue_timeout()
function from restarting the timer.

Commonly taskqueue_enqueue_timeout() is called from within the task
function itself without any checks for teardown. Then it can happen
the timer stays active after the return of taskqueue_drain_timeout(),
because the timeout and task is drained separately.

This patch factors out the teardown flag into the timeout task itself,
allowing existing code to stay as-is instead of applying a teardown
flag to each and every of the timeout task consumers.

Add assert to taskqueue_drain_timeout() which prevents parallel
execution on the same timeout task.

Update manual page documenting the return value of
taskqueue_enqueue_timeout().

Differential Revision: https://reviews.freebsd.org/D8012
Reviewed by: kib, trasz

git-svn-id: svn://svn.freebsd.org/base/stable/10@306947 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoWhile the thread is sleeping in taskqueue_drain_all() it is
julian [Mon, 10 Oct 2016 04:57:33 +0000 (04:57 +0000)]
While the thread is sleeping in taskqueue_drain_all() it is
posible that the queue entry it is looking at is removed
from the queue, but we make no effort to account
for this. when we wake up we need to check it's still there.

PR: 209580
Sponsored by: Panzura inc
Differential Revision: D8160

git-svn-id: svn://svn.freebsd.org/base/stable/10@306935 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306443:
jch [Sun, 9 Oct 2016 21:35:12 +0000 (21:35 +0000)]
MFC r306443:

Fix an issue with accept_filter introduced with r261242:

As a side effect of r261242 when using accept_filter the
first call to soisconnected() is done earlier in tcp_input()
instead of tcp_do_segment() context.  Restore the expected behaviour.

Note:  This call to soisconnected() seems to be extraneous in all
cases (with or without accept_filter).  Will be addressed in a
separate commit.

PR: 212920
Reported by: Alexey
Tested by: Alexey, jch
Sponsored by: Verisign, Inc.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306925 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r297314: rc.d: Make msgs a proper rc.d script.
jilles [Sun, 9 Oct 2016 21:28:56 +0000 (21:28 +0000)]
MFC r297314: rc.d: Make msgs a proper rc.d script.

PR: 207149
Reported by: Jonathan de Boyne Pollard

git-svn-id: svn://svn.freebsd.org/base/stable/10@306924 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306560, r306561:
pfg [Sun, 9 Oct 2016 20:13:53 +0000 (20:13 +0000)]
MFC r306560, r306561:
patch(1): make some macros look boolean.

Minor cleanup inspired by a new patch(1) variant in schily tools.

For reference:
https://sourceforge.net/p/schillix-on/

git-svn-id: svn://svn.freebsd.org/base/stable/10@306914 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305812:
pfg [Sun, 9 Oct 2016 19:58:27 +0000 (19:58 +0000)]
MFC r305812:

fifolog(1): invert order of calloc(3) arguments.

The second argument to calloc(3) should be the size, make it so.

While here be a little bit more cautious in fifolog_reader_open()
to protect in the unlikely event of an overflowed allocation.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306910 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306599:
sevan [Sat, 8 Oct 2016 21:19:44 +0000 (21:19 +0000)]
MFC r306599:
dmesg(8) first appeared in 3BSD.
http://minnie.tuhs.org/cgi-bin/utree.pl?file=3BSD/usr/man/man1/dmesg.1m

PR:           212443
Approved by:  bcr (mentor)
Obtained from:        TUHS
Differential Revision:        https://reviews.freebsd.org/D8105

git-svn-id: svn://svn.freebsd.org/base/stable/10@306880 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306568, r306569
vangyzen [Sat, 8 Oct 2016 14:10:45 +0000 (14:10 +0000)]
MFC r306568, r306569

Add the __printflike attribute to the declarations of
dprintf(3) and vdprintf(3).

Sponsored by: Dell EMC

git-svn-id: svn://svn.freebsd.org/base/stable/10@306846 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFH: r259647
julian [Fri, 7 Oct 2016 19:28:45 +0000 (19:28 +0000)]
MFH: r259647

 o Remove assertions on ipa_version as sometimes the version detection
   using cpuid can be quirky (this is the case of VMWare without the
   vPMC support) but fail to probe hwpmc.
 o Apply the fix for XEON family of processors as established by
   315338-020 document (bug AJ85).

 Sponsored by: EMC / Isilon storage division
 Reviewed by: fabient
MFC courtesy of panzura.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306824 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306292: fix vnode lock assertion for extended attributes directory
avg [Fri, 7 Oct 2016 18:56:24 +0000 (18:56 +0000)]
MFC r306292: fix vnode lock assertion for extended attributes directory

git-svn-id: svn://svn.freebsd.org/base/stable/10@306819 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306291: the rest of changes intended to be committed in r306290
avg [Fri, 7 Oct 2016 18:53:28 +0000 (18:53 +0000)]
MFC r306291: the rest of changes intended to be committed in r306290

git-svn-id: svn://svn.freebsd.org/base/stable/10@306817 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306218,306290: amdsbwd, intpm: unify bits specific to AMD chipsets
avg [Fri, 7 Oct 2016 18:51:04 +0000 (18:51 +0000)]
MFC r306218,306290: amdsbwd, intpm: unify bits specific to AMD chipsets

git-svn-id: svn://svn.freebsd.org/base/stable/10@306815 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r299199: Add nid_namelen bounds check to nfssvc system call
emaste [Fri, 7 Oct 2016 14:46:34 +0000 (14:46 +0000)]
MFC r299199: Add nid_namelen bounds check to nfssvc system call

This is only allowed by root and only used by the nfs daemon, which
should not provide an incorrect value. However, it's still good
practice to validate data provided by userland.

PR: 206626

git-svn-id: svn://svn.freebsd.org/base/stable/10@306809 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306674:
kib [Fri, 7 Oct 2016 11:50:59 +0000 (11:50 +0000)]
MFC r306674:
Style.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306805 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r296454:
jtl [Fri, 7 Oct 2016 10:47:32 +0000 (10:47 +0000)]
MFC r296454:
  Some cleanup in tcp_respond() in preparation for another change:
  - Reorder variables by size
  - Move initializer closer to where it is used
  - Remove unneeded variable

MFC r296455:
  As reported on the transport@ and current@ mailing lists, the FreeBSD TCP
  stack is not compliant with RFC 7323, which requires that TCP stacks send
  a timestamp option on all packets (except, optionally, RSTs) after the
  session is established.

  This patch adds that support. It also adds a TCP signature option to the
  packet, if appropriate.

MFC r300764 (by jhb@):
  Don't reuse the source mbuf in tcp_respond() if it is not writable.

  Not all mbufs passed up from device drivers are M_WRITABLE().  In
  particular, the Chelsio T4/T5 driver uses a feature called "buffer
  packing" to receive multiple frames in a single receive buffer.  The mbufs
  to receive multiple frames in a single receive buffer.  The mbufs for
  these frames all share the same external storage so are treated as
  read-only by the rest of the stack when multiple frames are in flight.
  Previously tcp_respond() would blindly overwrite read-only mbufs when
  INVARIANTS was disabled or panic with an assertion failure if INVARIANTS
  was enabled.  Note that the new case is a bit of a mix of the two other
  cases in tcp_respond().  The TCP and IP headers must be copied explicitly
  into the new mbuf instead of being inherited (similar to the m == NULL
  case), but the addresses and ports must be swapped in the reply (similar
  to the m != NULL case).

git-svn-id: svn://svn.freebsd.org/base/stable/10@306802 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306528: Fix `sesutil fault` operation.
mav [Fri, 7 Oct 2016 01:33:03 +0000 (01:33 +0000)]
MFC r306528: Fix `sesutil fault` operation.

Fault and ident bits are located in different control bytes, so previous
code was just doing nothing, writing into reserved bit.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306797 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC 302859: Include command line arguments in core dump process info.
jhb [Thu, 6 Oct 2016 21:17:18 +0000 (21:17 +0000)]
MFC 302859: Include command line arguments in core dump process info.

Fill in pr_psargs in the NT_PRSINFO ELF core dump note with command
line arguments.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306786 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC 299458: Fix buffer overrun in gcore(1) NT_PRPSINFO
jhb [Thu, 6 Oct 2016 19:41:09 +0000 (19:41 +0000)]
MFC 299458: Fix buffer overrun in gcore(1) NT_PRPSINFO

Use size of destination buffer, rather than a constant that may or may not
correspond to the source buffer, to restrict the length of copied strings.  In
particular, pr_fname has 16+1 characters but MAXCOMLEN is 18+1.

Use strlcpy instead of strncpy to ensure the result is nul-terminated.  This
seems to be what is expected of these fields.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306781 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306522
davidcs [Thu, 6 Oct 2016 18:56:06 +0000 (18:56 +0000)]
MFC r306522
Upgrade Firmware/Bootloader/ResetSeq/Minidump to revision 5.4.62

git-svn-id: svn://svn.freebsd.org/base/stable/10@306779 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306279: Use g_wither_provider() where applicable.
mav [Thu, 6 Oct 2016 15:36:13 +0000 (15:36 +0000)]
MFC r306279: Use g_wither_provider() where applicable.

It is just a helper function combining G_PF_WITHER setting with
g_orphan_provider().

git-svn-id: svn://svn.freebsd.org/base/stable/10@306765 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoFix ABI compat shims for FreeBSD 9.0-9.1 binaries (CAM_VERSION 0x16).
mav [Thu, 6 Oct 2016 03:20:47 +0000 (03:20 +0000)]
Fix ABI compat shims for FreeBSD 9.0-9.1 binaries (CAM_VERSION 0x16).

This is a direct commit to stable/10, inspired by some commits to later
branches.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306750 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306417: portsnap: only move expected snapshot contents from snap/ to files/
emaste [Wed, 5 Oct 2016 00:33:06 +0000 (00:33 +0000)]
MFC r306417: portsnap: only move expected snapshot contents from snap/ to files/

Previously it was possible to smuggle in addional files that would
be used by later portsnap runs. Now we only move those files expected
to be in the snapshot into files/ and require that there are no
unexpected files.

This was used by portsnap attacks 2, 3, and 4 in the "non-cryptanalytic
attacks against FreeBSD update components" anonymous gist.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306697 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoRevert r306659 since the userland changes won't merge and this would
rmacklem [Mon, 3 Oct 2016 23:17:57 +0000 (23:17 +0000)]
Revert r306659 since the userland changes won't merge and this would
break the build.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306663 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC: r304026
rmacklem [Mon, 3 Oct 2016 22:11:45 +0000 (22:11 +0000)]
MFC: r304026
Update the nfsstats structure to include the changes needed by
the patch in D1626 plus changes so that it includes counts for
NFSv4.1 (and the draft of NFSv4.2).
Also, make all the counts uint64_t and add a vers field at the
beginning, so that future revisions can easily be implemented.
There is code in place to handle the old vesion of the nfsstats
structure for backwards binary compatibility.

Subsequent commits will update nfsstat(8) to use the new fields.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306659 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306048
asomers [Mon, 3 Oct 2016 15:17:22 +0000 (15:17 +0000)]
MFC r306048

Fix periodic scripts when an NFS mount covers a local mount

100.chksetuid and 110.neggrpperm try to search through all UFS and ZFS
filesystems. But their logic contains an error. They also search through
remote filesystems that are mounted on top of the root of a local
filesystem. For example, if a user installs a FreeBSD system with the
default ZFS layout, he'll get a zroot/usr/home filesystem. If he then mounts
/usr/home over NFS, these scripts would search through /usr/home.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306644 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305977:
kib [Mon, 3 Oct 2016 10:15:16 +0000 (10:15 +0000)]
MFC r305977:
Be more strict when selecting between snapshot/regular mount.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306630 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306334:
kib [Mon, 3 Oct 2016 09:32:19 +0000 (09:32 +0000)]
MFC r306334:
Document thr_suspend(2) and thr_wake(2).

MFC r306506:
Reword the statement.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306626 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306289:
kp [Sun, 2 Oct 2016 21:11:25 +0000 (21:11 +0000)]
MFC r306289:

bridge: Fix fragment handling and memory leak

Fragmented UDP and ICMP packets were corrupted if a firewall with reassembling
feature (like pf'scrub) is enabled on the bridge.  This patch fixes corrupted
packet problem and the panic (triggered easly with low RAM) as explain in PR
185633.

bridge_pfil and bridge_fragment relationship:

bridge_pfil() receive (IN direction) packets and sent it to the firewall The
firewall can be configured for reassembling fragmented packet (like pf'scrubing)
in one mbuf chain when bridge_pfil() need to send this reassembled packet to the
outgoing interface, it needs to re-fragment it by using bridge_fragment()
bridge_fragment() had to split this mbuf (using ip_fragment) first then
had to M_PREPEND each packet in the mbuf chain for adding Ethernet
header.

But M_PREPEND can sometime create a new mbuf on the begining of the mbuf chain,
then the "main" pointer of this mbuf chain should be updated and this case is
tottaly forgotten. The original bridge_fragment code (Revision 158140,
2006 April 29) came from OpenBSD, and the call to bridge_enqueue was
embedded.  But on FreeBSD, bridge_enqueue() is done after bridge_fragment(),
then the original OpenBSD code can't work as-it of FreeBSD.

PR:             185633
Submitted by:   Olivier Cochard-LabbĂ©

git-svn-id: svn://svn.freebsd.org/base/stable/10@306594 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC: r284583, r285797, r285799, r287168, r298714, r298720, r298838,
jkim [Fri, 30 Sep 2016 22:40:58 +0000 (22:40 +0000)]
MFC: r284583, r285797, r285799, r287168, r298714, r298720, r298838,
r300879

Merge ACPICA up to 20160527.

Requested by: mav

git-svn-id: svn://svn.freebsd.org/base/stable/10@306536 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC 305034: Implement 'devctl clear driver' to undo a previous 'set driver'.
jhb [Fri, 30 Sep 2016 22:05:47 +0000 (22:05 +0000)]
MFC 305034: Implement 'devctl clear driver' to undo a previous 'set driver'.

Add a new 'clear driver' command for devctl along with the accompanying
ioctl and devctl_clear_driver() library routine to reset a device to
use a wildcard devclass instead of a fixed devclass.  This can be used
to undo a previous 'set driver' command.  After the device's name has
been reset to permit wildcard names, it is reprobed so that it can
attach to newly-available (to it) device drivers.

Sponsored by: Chelsio Communications

git-svn-id: svn://svn.freebsd.org/base/stable/10@306533 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC 305502: Reset PCI pass through devices via PCI-e FLR during VM start/end.
jhb [Fri, 30 Sep 2016 18:47:34 +0000 (18:47 +0000)]
MFC 305502: Reset PCI pass through devices via PCI-e FLR during VM start/end.

Add routines to trigger a function level reset (FLR) of a PCI-express
device via the PCI-express device control register.  This also includes
support routines to wait for pending transactions to complete as well
as calculating the maximum completion timeout permitted by a device.

Change the ppt(4) driver to reset pass through devices before attaching
to a VM during startup and before detaching from a VM during shutdown.

Sponsored by: Chelsio Communications

git-svn-id: svn://svn.freebsd.org/base/stable/10@306520 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r299064
royger [Fri, 30 Sep 2016 13:49:50 +0000 (13:49 +0000)]
MFC r299064

rtc: fix inverted resolution check

git-svn-id: svn://svn.freebsd.org/base/stable/10@306501 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC 304858,305485: Fix various issues with PCI pass through and VT-d.
jhb [Fri, 30 Sep 2016 01:42:29 +0000 (01:42 +0000)]
MFC 304858,305485: Fix various issues with PCI pass through and VT-d.

304858:
Enable I/O MMU when PCI pass through is first used.

Rather than enabling the I/O MMU when the vmm module is loaded,
defer initialization until the first attempt to pass a PCI device
through to a guest.  If the I/O MMU fails to initialize or is not
present, than fail the attempt to pass a PCI device through to a
guest.

The hw.vmm.force_iommu tunable has been removed since the I/O MMU is
no longer enabled during boot.  However, the I/O MMU support can be
disabled by setting the hw.vmm.iommu.enable tunable to 0 to prevent
use of the I/O MMU on any systems where it is buggy.

305485:
Leave ppt devices in the host domain when they are not attached to a VM.

This allows a pass through device to be reset to a normal device driver
on the host and reused on the host.  ppt devices are now always active in
some I/O MMU domain when the I/O MMU is active, either the host domain
or the domain of a VM they are attached to.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306472 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC 305248: Remove warning about pci_addr_t being different sizes.
jhb [Fri, 30 Sep 2016 01:16:09 +0000 (01:16 +0000)]
MFC 305248: Remove warning about pci_addr_t being different sizes.

pci_addr_t has always been 64-bits since r163805.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306470 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC 303881: Reliably return PCI_GETCONF_LAST_DEVICE from PCIOCGETCONF.
jhb [Fri, 30 Sep 2016 01:13:57 +0000 (01:13 +0000)]
MFC 303881: Reliably return PCI_GETCONF_LAST_DEVICE from PCIOCGETCONF.

Previously the loop in PCIIOCGETCONF would terminate as soon as it
found enough matches.  Now it will continue iterating through the
PCI device list and only terminate if it finds another matching device
for which it has no room to store a conf structure.  This means that
PCI_GETCONF_LAST_DEVICE is reliably returned when the number of
matching devices is equal to the number of slots in the matches
buffer.  For example, if a program requests the conf structure for a
single PCI function with a specified domain/bus/slot/function it will
now get PCI_GETCONF_LAST_DEVICE instead of PCI_GETCONF_MORE_DEVS.

While here, simplify the loop conditional a bit more by explicitly
breaking out of the loop if copyout() fails and removing a redundant
i < pci_numdevs check.

Sponsored by: Chelsio Communications

git-svn-id: svn://svn.freebsd.org/base/stable/10@306469 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC 295813,295816: Remove redundant check for "(dinfo != NULL)".
jhb [Fri, 30 Sep 2016 00:43:30 +0000 (00:43 +0000)]
MFC 295813,295816: Remove redundant check for "(dinfo != NULL)".

git-svn-id: svn://svn.freebsd.org/base/stable/10@306468 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC 303887: Add a dmardump utility to dump the VT-d context tables.
jhb [Fri, 30 Sep 2016 00:33:19 +0000 (00:33 +0000)]
MFC 303887: Add a dmardump utility to dump the VT-d context tables.

This tool parses the ACPI DMAR table looking for DMA remapping devices.
For each device it walks the root table and any context tables
referenced to display mapping info for PCI devices.

Note that acpidump -t already parses the info in the ACPI DMAR tables
directly.  This tool examines some of the data structures the DMAR
remapping engines use to translate DMA requests.

Sponsored by: Chelsio Communications

git-svn-id: svn://svn.freebsd.org/base/stable/10@306467 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC 303886: Add additional constants.
jhb [Fri, 30 Sep 2016 00:31:17 +0000 (00:31 +0000)]
MFC 303886: Add additional constants.

- Add constants for the fields in the root-entry table address register,
  namely the root type type (RTT) and root table address (RTA) mask.
- Add macros for the bitmask of the domain ID field in the second word
  of context table entries as well as a helper macro (DMAR_CTX2_GET_DID)
  to extract the domain ID from a context table entry.

Sponsored by: Chelsio Communications

git-svn-id: svn://svn.freebsd.org/base/stable/10@306466 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC (part of) r298089 by pfg: Cleanup unnecessary semicolons
emaste [Thu, 29 Sep 2016 01:53:29 +0000 (01:53 +0000)]
MFC (part of) r298089 by pfg: Cleanup unnecessary semicolons

git-svn-id: svn://svn.freebsd.org/base/stable/10@306428 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r296205: Fix typo.
emaste [Thu, 29 Sep 2016 01:47:02 +0000 (01:47 +0000)]
MFC r296205: Fix typo.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306427 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306075,r306109
ache [Wed, 28 Sep 2016 20:49:33 +0000 (20:49 +0000)]
MFC r306075,r306109

1) Microoptimize %p case.
2) Implememt %u for GNU compatibility.
3) Don't forget to advance buf for %w/%u.
4) Fail with incomplete week (week 0) request and no such week in the
year.
5) Fix yday formula when Sunday requested and the week started from Monday.
6) Fail with impossible yday for incomplete week (week 0) and direct %w/%u
request.
7) Shift yday/wday to the first day of the year, if incomplete week
(week 0) requested and no %w/%u used.
8) For already non-standard %z extension implement GNU compatible formats:
+hh and -hh.
9) Check for incorrect values for %z.

PR:     212983 (case 3 only)

git-svn-id: svn://svn.freebsd.org/base/stable/10@306414 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r274925: misc mdoc fixes.
pluknet [Tue, 27 Sep 2016 19:00:22 +0000 (19:00 +0000)]
MFC r274925: misc mdoc fixes.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306378 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305509:
markj [Tue, 27 Sep 2016 18:07:22 +0000 (18:07 +0000)]
MFC r305509:
Don't treat an error from g_mirror_clear_metadata() as fatal.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306374 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306205:
loos [Tue, 27 Sep 2016 17:27:07 +0000 (17:27 +0000)]
MFC r306205:

Add the ID for the Huawei ME909S LTE modem.

Submitted by: svenauhagen at github
Sponsored by: Rubicon Communications, LLC (Netgate)

git-svn-id: svn://svn.freebsd.org/base/stable/10@306370 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r306131
asomers [Mon, 26 Sep 2016 15:03:31 +0000 (15:03 +0000)]
MFC r306131

Update mkimg(1) author's contact info

git-svn-id: svn://svn.freebsd.org/base/stable/10@306345 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305819:
mm [Sun, 25 Sep 2016 22:04:02 +0000 (22:04 +0000)]
MFC r305819:
Sync libarchive with vendor including important security fixes.

Issues fixed (FreeBSD):
PR #778: ACL error handling
Issue #745: Symlink check prefix optimization is too aggressive
Issue #746: Hard links with data can evade sandboxing restrictions

This update fixes the vulnerability #3 and vulnerability #4 as reported in
"non-cryptanalytic attacks against FreeBSD update components".
https://gist.github.com/anonymous/e48209b03f1dd9625a992717e7b89c4f

Fix for vulnerability #2 has already been merged in r305192.

Security: http://gist.github.com/anonymous/e48209b03f1dd9625a992717e7b89c4f

git-svn-id: svn://svn.freebsd.org/base/stable/10@306322 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305956: Add manpage for rctl_* system calls
badger [Sat, 24 Sep 2016 16:46:37 +0000 (16:46 +0000)]
MFC r305956: Add manpage for rctl_* system calls

Approved by: kib (mentor)
Sponsored by: Dell Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306298 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305896:
dchagin [Sat, 24 Sep 2016 10:34:35 +0000 (10:34 +0000)]
MFC r305896:

Implement BLKSSZGET ioctl for the Linuxulator.

PR: 212700

git-svn-id: svn://svn.freebsd.org/base/stable/10@306294 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305877:
hselasky [Fri, 23 Sep 2016 08:35:56 +0000 (08:35 +0000)]
MFC r305877:
mlx5en: Fix duplicate mbuf free-by-code.

When mlx5e_sq_xmit() returns an error code and the mbuf pointer is set,
we should not free the mbuf, because the caller will keep the mbuf in
the drbr. Make sure the mbuf pointer is correctly set upon function
exit.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306254 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305876:
hselasky [Fri, 23 Sep 2016 08:35:11 +0000 (08:35 +0000)]
MFC r305876:
mlx5en: Remove unused pdev pointer.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306253 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305875:
hselasky [Fri, 23 Sep 2016 08:34:28 +0000 (08:34 +0000)]
MFC r305875:
mlx5en: Verify port type is ethernet before creating network device

Else the mlx5en driver might attach to infiniband ports.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306252 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305874:
hselasky [Fri, 23 Sep 2016 08:33:47 +0000 (08:33 +0000)]
MFC r305874:
mlx5en: Allow setting the software MTU size below 1500 bytes

The hardware MTU size can't be set to a value less than 1500 bytes due
to side-band management support. Allow setting the software MTU size
below 1500 bytes, thus creating a mismatch between hardware and
software MTU sizes.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306251 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305873:
hselasky [Fri, 23 Sep 2016 08:33:03 +0000 (08:33 +0000)]
MFC r305873:
mlx5en: Factor out common sendqueue code for use with rate limiting SQs.

Try to reuse code to setup sendqueues when possible by making some static
functions global. Further split the mlx5e_close_sq_wait() function to
separate out reusable parts.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306250 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305872:
hselasky [Fri, 23 Sep 2016 08:32:18 +0000 (08:32 +0000)]
MFC r305872:
mlx5en: Properly declare doorbell lock for 32-bit CPUs.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306249 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305871:
hselasky [Fri, 23 Sep 2016 08:31:38 +0000 (08:31 +0000)]
MFC r305871:
mlx5en: Optimise away duplicate UAR pointers.

This change also reduces the size of the mlx5e_sq structure so that the last
queue_state element will fit into the previous cacheline and then the mlx5e_sq
structure becomes one cacheline less for amd64.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306248 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305870:
hselasky [Fri, 23 Sep 2016 08:30:53 +0000 (08:30 +0000)]
MFC r305870:
mlx5en: Make the mlx5e_open_cq() and mlx5e_close_cq() functions global.

Make some functions and structures global to allow for code reuse
when creating rate limiting sendqueues.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306247 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305869:
hselasky [Fri, 23 Sep 2016 08:30:09 +0000 (08:30 +0000)]
MFC r305869:
mlx5en: Minor completion queue control path code refactor.

Move setting of CQ moderation mode together with the other
CQ moderation parameters. Pass completion event vector as
a separate argument to mlx5e_open_cq(), because its value is
different for each call. Pass mlx5e_priv pointer instead of
mlx5e_channel pointer so that code can be used by rate
limiting sendqueues.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306246 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305868:
hselasky [Fri, 23 Sep 2016 08:29:27 +0000 (08:29 +0000)]
MFC r305868:
mlx5en: Separate the sendqueue from using the mlx5e_channel structure.

This change allows for reusing the transmit path for so called
rate limited senqueues. While at it optimise some pointer lookups
in the fast path.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306245 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305867:
hselasky [Fri, 23 Sep 2016 08:28:44 +0000 (08:28 +0000)]
MFC r305867:
Update the MLX5 core module:
- Add new firmware commands and update existing ones.
- Add more firmware related structures and update existing ones.
- Some minor fixes, like adding missing \n to some prints.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@306244 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC 306015
sephe [Fri, 23 Sep 2016 04:53:47 +0000 (04:53 +0000)]
MFC 306015
    hyperv/storvsc: Fix SRB length setting.

    This fixes disk discovery issue on WS2008R2 Hyper-V, which plagued
    us since 10.2-release.

    Reported by:    many
    Sponsored by:   Microsoft

git-svn-id: svn://svn.freebsd.org/base/stable/10@306225 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC bspatch Capsicumization and improvements
emaste [Thu, 22 Sep 2016 21:16:54 +0000 (21:16 +0000)]
MFC bspatch Capsicumization and improvements

r304691: bspatch: apply style(9)

Make style changes (and trivial refactoring of open calls) now in order
to reduce noise in diffs for future capsicum changes.

r304807 (allanjude): Capsicumize bspatch

Move all of the fopen() and open() calls to the top of main()

Restrict each FD to least privilege (read/seek only, write only, etc)

cap_enter(), and make all except the output FD read/seek only.

r304821: bspatch: remove output file in the case of error

r305486: bspatch: add sanity checks on sizes to avoid integer overflow

Note that this introduces an explicit 2GB limit, but this was already
implicit in variable and function argument types.

This is based on the "non-cryptanalytic attacks against freebsd
update components" anonymous gist. Further refinement is planned.

r305737: bspatch: remove superfluous newlines from errx strings

r305822: bspatch: use #define for header size instead of magic number

r306026: bspatch: Remove backwards-compatibility sys/capability.h support

bspatch previously included sys/capability.h or sys/capsicum.h based
on __FreeBSD_version, as FreeBSD is the upstream for bsdiff and we may
see this file incorporated into other third-party software.

The Capsicum header is now installed as sys/capsicum.h in stable/10 and
FreeBSD 10.3, so we can just use sys/capsicum.h and simplify the logic.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306215 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r264823 (ed): Make usage printing more consistent with other tools.
emaste [Thu, 22 Sep 2016 21:14:00 +0000 (21:14 +0000)]
MFC r264823 (ed): Make usage printing more consistent with other tools.

- Introduce a separate usage() function.
- Don't use argv[0]. Directly name the application, as we do elsewhere.
- Don't prepend the application name.
- Don't print two newlines.

Also apply the unnecessary semicolon cleanup from r298089

git-svn-id: svn://svn.freebsd.org/base/stable/10@306214 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305841
ache [Thu, 22 Sep 2016 16:46:59 +0000 (16:46 +0000)]
MFC r305841

Implement multibyte encoding support for -v with fallback

git-svn-id: svn://svn.freebsd.org/base/stable/10@306200 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMerge OpenSSL 1.0.1u.
jkim [Thu, 22 Sep 2016 15:05:38 +0000 (15:05 +0000)]
Merge OpenSSL 1.0.1u.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306196 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305601:
kib [Thu, 22 Sep 2016 10:54:30 +0000 (10:54 +0000)]
MFC r305601:
On rename, do not perform truncation of dirhash if the vnode truncation failed.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306182 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305599:
kib [Thu, 22 Sep 2016 10:53:13 +0000 (10:53 +0000)]
MFC r305599:
Do not leak transient ENOLCK error from flush_newblk_dep() loop.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306181 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305598:
kib [Thu, 22 Sep 2016 10:51:47 +0000 (10:51 +0000)]
MFC r305598:
When logging unlikely UFS_TRUNCATE() failure in ufs_direnter(),
include error code.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306180 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305597:
kib [Thu, 22 Sep 2016 10:49:42 +0000 (10:49 +0000)]
MFC r305597:
When extending directory inode in ufs_direnter(), adjust i_endoff.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306179 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305595:
kib [Thu, 22 Sep 2016 10:47:56 +0000 (10:47 +0000)]
MFC r305595:
In dqsync(), when called from quotactl(), um_quotas entry might appear
cleared since nothing prevents completion of the parallel quotaoff.
There is nothing to sync in this case, and no reason to panic.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306178 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305594:
kib [Thu, 22 Sep 2016 10:46:08 +0000 (10:46 +0000)]
MFC r305594:
In softdep_prealloc(), return early not only for snapshots, but for
the quota files as well.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306177 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305593:
kib [Thu, 22 Sep 2016 10:44:56 +0000 (10:44 +0000)]
MFC r305593:
There is no need to upgrade the last dvp lock on lookups for modifying
operations.  Instead of upgrading, assert that the lock is exclusive.
Explain the cause in comments.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306176 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305592:
kib [Thu, 22 Sep 2016 10:42:40 +0000 (10:42 +0000)]
MFC r305592:
Partially lift suspension when ffs_reload() finished with cgs and
going to re-read inodes.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306175 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305610: Don't report to devd statuses that CAM doesn't consider errors.
mav [Thu, 22 Sep 2016 03:35:02 +0000 (03:35 +0000)]
MFC r305610: Don't report to devd statuses that CAM doesn't consider errors.

Some statuses, such as "ATA pass through information available", are part
part of absolutely normal operation and do not worth reporting.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306156 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305609: "Extended copy information available" is not an error either.
mav [Thu, 22 Sep 2016 03:34:26 +0000 (03:34 +0000)]
MFC r305609: "Extended copy information available" is not an error either.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306155 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305608: "ATA pass through information available" is not an error.
mav [Thu, 22 Sep 2016 03:33:46 +0000 (03:33 +0000)]
MFC r305608: "ATA pass through information available" is not an error.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306154 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305602: intpm: fix attachment to supported AMD FCHs
avg [Wed, 21 Sep 2016 19:53:51 +0000 (19:53 +0000)]
MFC r305602: intpm: fix attachment to supported AMD FCHs

git-svn-id: svn://svn.freebsd.org/base/stable/10@306141 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r275240 (bapt): Implement --no-fatal-warnings
emaste [Wed, 21 Sep 2016 19:11:37 +0000 (19:11 +0000)]
MFC r275240 (bapt): Implement --no-fatal-warnings

Implement --no-fatal-warning for compatibility with newer ld
what ever order the options are passed to ld(1) the --no-fatal-warning always
disable --fatal-warning

git-svn-id: svn://svn.freebsd.org/base/stable/10@306136 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305606: intpm: make sure to register smbus driver before intpm driver
avg [Wed, 21 Sep 2016 16:29:15 +0000 (16:29 +0000)]
MFC r305606: intpm: make sure to register smbus driver before intpm driver

git-svn-id: svn://svn.freebsd.org/base/stable/10@306125 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305604: intpm: better clean up resources after a failed attachment
avg [Wed, 21 Sep 2016 16:27:09 +0000 (16:27 +0000)]
MFC r305604: intpm: better clean up resources after a failed attachment

git-svn-id: svn://svn.freebsd.org/base/stable/10@306123 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305603: intpm: do not try attaching to unsupported controller revisions
avg [Wed, 21 Sep 2016 16:23:31 +0000 (16:23 +0000)]
MFC r305603: intpm: do not try attaching to unsupported controller revisions

git-svn-id: svn://svn.freebsd.org/base/stable/10@306121 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305600: amdsbwd.4: update supported hardware list
avg [Wed, 21 Sep 2016 16:17:22 +0000 (16:17 +0000)]
MFC r305600: amdsbwd.4: update supported hardware list

git-svn-id: svn://svn.freebsd.org/base/stable/10@306119 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305596: intpm.4 update supported hardware list
avg [Wed, 21 Sep 2016 16:15:35 +0000 (16:15 +0000)]
MFC r305596: intpm.4 update supported hardware list

git-svn-id: svn://svn.freebsd.org/base/stable/10@306117 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r303113: Cross-link some SMBus controller drivers man pages.
avg [Wed, 21 Sep 2016 16:14:02 +0000 (16:14 +0000)]
MFC r303113: Cross-link some SMBus controller drivers man pages.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306115 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r303111: Document list of supported chipsets.
avg [Wed, 21 Sep 2016 16:12:34 +0000 (16:12 +0000)]
MFC r303111: Document list of supported chipsets.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306113 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305535: amdsbwd: add support for FCH in family 16h models 30h-3Fh processors
avg [Wed, 21 Sep 2016 16:06:00 +0000 (16:06 +0000)]
MFC r305535: amdsbwd: add support for FCH in family 16h models 30h-3Fh processors

git-svn-id: svn://svn.freebsd.org/base/stable/10@306111 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305939:
kib [Wed, 21 Sep 2016 08:14:55 +0000 (08:14 +0000)]
MFC r305939:
Remove trailing space.

git-svn-id: svn://svn.freebsd.org/base/stable/10@306080 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFstable/11 r305914:
ngie [Sun, 18 Sep 2016 04:34:32 +0000 (04:34 +0000)]
MFstable/11 r305914:

MFC r305357:

Skip testcases 9/10 if jail(8) isn't installed

These testcases require jail support

git-svn-id: svn://svn.freebsd.org/base/stable/10@305915 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFstable/11 r305912:
ngie [Sun, 18 Sep 2016 03:00:46 +0000 (03:00 +0000)]
MFstable/11 r305912:

MFC r305356:

Add a missing "Bail out!" if zpool create fails

This will make the exit info more meaningful if/when zpool create fails,
and establishes parity with the other 2 zfs acl testcases (01, 03).

git-svn-id: svn://svn.freebsd.org/base/stable/10@305913 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFstable/11 r305910:
ngie [Sun, 18 Sep 2016 02:51:18 +0000 (02:51 +0000)]
MFstable/11 r305910:

MFC r305033,r305041,r305170:

r305033:

Minor Makefile simplifications for lib/atf/...

- Replace uses of `${.CURDIR:H:H:H}` with ${SRCTOP}
- Use built-in :H operator instead of ".." when enumerating paths.

r305041:

Filter certain compile-time options into -DATF_BUILD_*

Items filtered through are:

- Constant defines (-D)
- Include flags (-I)
- Linker flags (-L)
- Optimization level (-O)
- Warnings / linker flags (-W)
- Preprocessor options (-f)

This fixes the scenario hit by the Jenkins job where it's infecting
the build with --sysroot, etc options from the Jenkins build in the
tests.

Prefix all intermediate variables (_CFLAGS, etc) with "ATF_BUILD" [*].

Requested by: jmmv

r305170:

Don't bake all of CC/CPP/CXX into CFLAGS

Capture executable names for CC, CPP, CXX (assumed to be the
first non-CCACHE_BIN word).

This change strips out all of the cross-compiler arguments, (-target,
-B, etc), added to ${CC}, etc via ${CROSSENV} in Makefile.inc1, so it
doesn't infect the build and subsequently the test.

Add comments noting why this logic is being added, and why the logic in
r305041 was necessary/what it was trying to achieve.

This is required after recent changes made to the toolchain to always
specify --sysroot, -target, -B, etc with clang in buildworld (presumably
r304681).

git-svn-id: svn://svn.freebsd.org/base/stable/10@305911 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r301522 (by bz)
hiren [Fri, 16 Sep 2016 00:14:26 +0000 (00:14 +0000)]
MFC r301522 (by bz)

Implement a `show panic` command to DDB which will helpfully print the
panic string again if set, in case it scrolled out of the active
window.  This avoids having to remember the symbol name.

Also add a show callout <addr> command to DDB in order to inspect
some struct callout fields in case of panics in the callout code.
This may help to see if there was memory corruption or to further
ease debugging problems.

No objection by:    bz

git-svn-id: svn://svn.freebsd.org/base/stable/10@305853 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305590:
hselasky [Thu, 15 Sep 2016 08:35:46 +0000 (08:35 +0000)]
MFC r305590:
Correctly map the USB mouse tilt delta values into buttons 5 and 6
instead of 3 and 4 which is used for the scroll wheel, according to
X.org.

PR: 170358

git-svn-id: svn://svn.freebsd.org/base/stable/10@305829 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305744:
kib [Thu, 15 Sep 2016 08:26:59 +0000 (08:26 +0000)]
MFC r305744:
Fix typo in comment.

git-svn-id: svn://svn.freebsd.org/base/stable/10@305826 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

7 years agoMFC r305129:
kib [Wed, 14 Sep 2016 10:51:06 +0000 (10:51 +0000)]
MFC r305129:
Make swapoff reliable.

git-svn-id: svn://svn.freebsd.org/base/stable/10@305803 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f