]> CyberLeo.Net >> Repos - FreeBSD/stable/9.git/log
FreeBSD/stable/9.git
9 years agoMFC r276250:
markj [Tue, 6 Jan 2015 02:13:48 +0000 (02:13 +0000)]
MFC r276250:
DOF tables are aligned according to the DOF section's alignment constraint,
so take this into account when iterating over DOF tables.

PR: 195555

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

9 years agoMFC r274254: sh(1): Mention portability issue with shifting zero positional
jilles [Sun, 4 Jan 2015 19:05:16 +0000 (19:05 +0000)]
MFC r274254: sh(1): Mention portability issue with shifting zero positional
parameters.

Per Austin Group issue #459, shifting zero positional parameters may or may
not be considered an operand error (which causes the shell to exit in most
cases).

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

9 years agoMFC r271936: sh(1): Clarify that assignments before commands do not affect
jilles [Sun, 4 Jan 2015 19:00:39 +0000 (19:00 +0000)]
MFC r271936: sh(1): Clarify that assignments before commands do not affect
expansions.

PR: 193759

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

9 years agoMFC r272963: pstat(8): Correct description of the SESS column in pstat -t.
jilles [Sat, 3 Jan 2015 15:39:04 +0000 (15:39 +0000)]
MFC r272963: pstat(8): Correct description of the SESS column in pstat -t.

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

9 years agoBump copyright year.
gjb [Fri, 2 Jan 2015 21:41:52 +0000 (21:41 +0000)]
Bump copyright year.

Sponsored by: The FreeBSD Foundation

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

9 years agoDocument the following security advisorires:
gjb [Fri, 2 Jan 2015 21:40:58 +0000 (21:40 +0000)]
Document the following security advisorires:
 - FreeBSD-SA-14:28.file
 - FreeBSD-SA-14:30.bind
 - FreeBSD-SA-14:31.ntp

Sponsored by: The FreeBSD Foundation

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

9 years agoMFC r270961
alc [Fri, 2 Jan 2015 19:01:00 +0000 (19:01 +0000)]
MFC r270961
  Update a comment to reflect the changes in r213408.

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

9 years agoMFC r275435: Add sleep(1) to /rescue.
delphij [Fri, 2 Jan 2015 18:57:51 +0000 (18:57 +0000)]
MFC r275435: Add sleep(1) to /rescue.

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

9 years agoMFC r275930:
delphij [Fri, 2 Jan 2015 18:51:47 +0000 (18:51 +0000)]
MFC r275930:

Plug a memory leak.

Obtained from: DragonFlyBSD (commit 5119ece)

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

9 years agoMFC: r276052,r276053
bapt [Fri, 2 Jan 2015 18:32:53 +0000 (18:32 +0000)]
MFC: r276052,r276053

Build selective portions of gnu/usr.bin/texinfo as part of build-tools to
ensure that building on a host without makeinfo (i.e. a host where
make delete-old -DWITHOUT_INFO was run), then building with MK_INFO == yes
doesn't manifest in build errors when building info pages

This manifested itself like the following when I was build testing an MFC
change on stable/10:

  makeinfo --no-split -I /usr/src/gnu/lib/libregex/doc -I /usr/src/gnu/lib/libregex/doc regex.texi  -o regex.info
  makeinfo: not found
  *** [regex.info] Error code 127

make[6]: stopped in /usr/src/gnu/lib/libregex/doc
1 error

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

9 years agoMFC r276238:
hselasky [Fri, 2 Jan 2015 08:38:23 +0000 (08:38 +0000)]
MFC r276238:
Add proper Makefiles to build some infiniband example utilities.

Sponsored by: Mellanox Technologies

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

9 years agoMFC r276346:
dim [Wed, 31 Dec 2014 16:28:16 +0000 (16:28 +0000)]
MFC r276346:

In contrib/binutils/gas/config/tc-ppc.c, fix a few -Wformat-security
warnings.

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

9 years agoMFC r276462:
bz [Wed, 31 Dec 2014 10:04:41 +0000 (10:04 +0000)]
MFC r276462:

  Bump copyright year.

  Happy New Year 2015!

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

9 years agoMFC r276229:
pfg [Wed, 31 Dec 2014 04:52:32 +0000 (04:52 +0000)]
MFC r276229:
Backport fix for binutils 11867: .quad directive not assembled correctly

Alan Modra (and Alan's employer) graciously permitted use of his patch
under GPLv2.

Obtained from: OpenBSD

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

9 years agoMFC: r276221
rmacklem [Wed, 31 Dec 2014 01:38:02 +0000 (01:38 +0000)]
MFC: r276221
Delete some duplicate code that was harmless because
exactly the same code is at the end of the nfscl_checksattr()
function that is called just before it. As such, this code
had already been executed and didn't do anything.

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

9 years agoMFC: r276193
rmacklem [Wed, 31 Dec 2014 01:34:37 +0000 (01:34 +0000)]
MFC: r276193
A deadlock in the NFSv4 server with vfs.nfsd.enable_locallocks=1
was reported via email. This was caused by a LOR between the
sleep lock used to serialize the local locking (nfsrv_locklf())
and locking the vnode. I believe this patch fixes the problem
by delaying relocking of the vnode until the sleep lock is
unlocked (nfsrv_unlocklf()). To avoid nfsvno_advlock() having the side
effect of unlocking the vnode, unlocking the vnode was moved to before
the functions that call nfsvno_advlock().
It shouldn't affect the execution of the default case where
vfs.nfsd.enable_locallocks=0.

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

9 years agoMFC: r276192, r276200
rmacklem [Wed, 31 Dec 2014 01:29:44 +0000 (01:29 +0000)]
MFC: r276192, r276200
Modify vop_stdadvlock{async}() so that it only
locks/unlocks the vnode and does a VOP_GETATTR()
for the SEEK_END case. This is safe to do, since
lf_advlock{async}() only uses the size argument
for the SEEK_END case.
The NFSv4 server needs this when
vfs.nfsd.enable_locallocks!=0 since locking the
vnode results in a LOR that can cause a deadlock
for the nfsd threads.

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

9 years agoMFC r267897: Update Makefile to reflect file update.
delphij [Wed, 31 Dec 2014 00:09:05 +0000 (00:09 +0000)]
MFC r267897: Update Makefile to reflect file update.

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

9 years agoMFH r230580:
peterj [Wed, 31 Dec 2014 00:08:37 +0000 (00:08 +0000)]
MFH r230580:
Don't mention no longer supported ioctl commands.

MFH r274083:
convert .Nm to proper .Xr's...

MFH r275298:
Cross reference tap(4) and tun(4) and include a short explanation as
to how they differ.  This will assist users in selecting which interface
is more appropriate for their purposes.

No objection: glebius (r230580), jmg (r274083)
Approved by: grog (co-mentor)

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

9 years agoMFC: file 5.21
delphij [Tue, 30 Dec 2014 19:51:30 +0000 (19:51 +0000)]
MFC: file 5.21

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

9 years agoMFC r276228:
pfg [Mon, 29 Dec 2014 22:55:54 +0000 (22:55 +0000)]
MFC r276228:

gas: use memmove instead of bogus memcpy.

partial_where points into the buffer that begins with buffer_start
so we need to use memmove() to handle the overlap.
Fixes Sourceware-PR 11456.

Obtained from: OpenBSD (CVS rev. 1.2)

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

9 years agoMFH r275941:
peterj [Sun, 28 Dec 2014 07:16:48 +0000 (07:16 +0000)]
MFH r275941:
Adjust the test of a KASSERT to better match the intent.

This assertion was added in r246213 as a guard against corrupted mbufs
arriving from drivers, the key distinguishing factor of said mbufs being
that they had a negative length. Given we're in a while loop specifically
designed to skip over zero-length mbufs, panicking on a zero-length mbuf
seems incorrect.

Suggested by: rmacklem
MFH go-ahead: benno
Approved by: grog (co-mentor)

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

9 years agoMFC r275906:
jamie [Sat, 27 Dec 2014 02:17:35 +0000 (02:17 +0000)]
MFC r275906:

  Setgid before running a command as a specified user.  Previously only
  initgroups(3) was called, what isn't quite enough.  This brings jail(8)
  in line with jexec(8), which was already doing the right thing.

PR: 195984

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

9 years agoMFC r272671:
markj [Fri, 26 Dec 2014 22:52:43 +0000 (22:52 +0000)]
MFC r272671:
Treat D keywords as identifiers in certain postfix expressions. This allows
one to, for example, access the "provider" field of a struct g_consumer,
even though "provider" is a D keyword.

PR: 169657

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

9 years agoMFC r275011:
markj [Fri, 26 Dec 2014 22:49:27 +0000 (22:49 +0000)]
MFC r275011:
The module load address always needs to be included when setting the dm_*_va
fields of dt_module_t. Previously, this was only done on architectures where
kernel modules have type ET_REL; this change fixes that. As a result, symbol
name resolution in the stack() action now works properly for kernel modules
on i386.

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

9 years agoMFC r275790 and r275791:
hselasky [Fri, 26 Dec 2014 11:34:45 +0000 (11:34 +0000)]
MFC r275790 and r275791:
Resolve USB driver identification conflict.
Regenerate etc/devd/usb.conf.

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

9 years agoMFC r262128, r262129, r275605, r276239 and r276240:
hselasky [Fri, 26 Dec 2014 11:25:56 +0000 (11:25 +0000)]
MFC r262128, r262129, r275605, r276239 and r276240:
Add more USB quirks.

PR: 178771
PR: 180617
PR: 195372

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

9 years agoMFC: r272491
nyan [Tue, 23 Dec 2014 10:59:53 +0000 (10:59 +0000)]
MFC: r272491

  Reduce diffs against i386.

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

9 years agoMFC r275120:
kib [Tue, 23 Dec 2014 10:07:23 +0000 (10:07 +0000)]
MFC r275120:
Fix SA_SIGINFO | SA_RESETHAND handling.

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

9 years agoMFC r274437;
pfg [Tue, 23 Dec 2014 03:25:20 +0000 (03:25 +0000)]
MFC r274437;

ifdef ext2_print_inode which is not really used.

ext2_print_inode was nice to have for initial development work but
is not really used anymore. #ifdef it under a new EXT2FS_DEBUG knob
so that we don't spend time compiling it.

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

9 years agoMFC r275838;
pfg [Tue, 23 Dec 2014 02:47:14 +0000 (02:47 +0000)]
MFC r275838;
sed: Bounds check the file path used in the 'w' command.

Modified version of a diff from Sebastien Marie to prevent a crash found
with the afl fuzzer.

Obtained from: OpenBSD (CVS Rev. 1.37)

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

9 years agoStrip trailing / characters from paths in "not present" index entries.
des [Mon, 22 Dec 2014 22:11:50 +0000 (22:11 +0000)]
Strip trailing / characters from paths in "not present" index entries.

Errata: FreeBSD-EN-14:13.freebsd-update
Approved by: so@

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

9 years agoMFC r276071:
delphij [Mon, 22 Dec 2014 19:08:09 +0000 (19:08 +0000)]
MFC r276071:

Fix multiple ntp vulnerabilities.

Reviewed by: roberto (earlier revision), philip
Security: CVE-2014-9293, CVE-2014-9294
Security: CVE-2014-9295, CVE-2014-9296
Security: FreeBSD-SA-14:31.ntp

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

9 years agoMFC r267265: truncate: Detect integer overflow, fix relative sizes.
jilles [Sun, 21 Dec 2014 23:22:12 +0000 (23:22 +0000)]
MFC r267265: truncate: Detect integer overflow, fix relative sizes.

The change to expand_number (r204654) broke detection of too large sizes and
relative sizes ('+'/'-').

There are no tests in the MFC because stable/9 lacks the test framework.

PR: 190735
Submitted by: Kirk Russell

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

9 years agoMFC r275729:
ae [Fri, 19 Dec 2014 13:24:52 +0000 (13:24 +0000)]
MFC r275729:
  Increase the buffer size to keep the list of programm names when
  parsing programm specification. It is safe to not check out of bounds
  access, because !isprint(p[i]) check will stop reading, when '\0'
  character will be read from the input string.

Sponsored by: Yandex LLC

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

9 years agoMFC r275833:
kib [Fri, 19 Dec 2014 09:42:40 +0000 (09:42 +0000)]
MFC r275833:
The iret instruction may generate #np and #ss fault, besides #gp.
When returning to usermode, the handler for that exceptions is also
executed with wrong gs base.  Handle all three possible faults in the
same way, checking for iret fault, and performing full iret.

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

9 years agoMFC r275503:
mav [Fri, 19 Dec 2014 01:14:41 +0000 (01:14 +0000)]
MFC r275503:
Avoid unneeded malloc/memcpy/free if there is no metadata on disk.

Submitted by:   Dmitry Luhtionov <dmitryluhtionov@gmail.com>

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

9 years agoMFC r275401: zfs_putpages: actually update mtime and ctime
avg [Thu, 18 Dec 2014 13:46:32 +0000 (13:46 +0000)]
MFC r275401: zfs_putpages: actually update mtime and ctime

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

9 years agoUpdate BIND to 9.9.6-P1
erwin [Thu, 18 Dec 2014 08:36:19 +0000 (08:36 +0000)]
Update BIND to 9.9.6-P1

Most notable changes in 9.9.6 and includes the latest SA:
https://lists.isc.org/pipermail/bind-announce/2014-September/000928.html

Note this is a direct commit to stable/9 as BIND is no longer in head.

Sponsored by: DK Hostmaster A/S

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

9 years agoMFC r275475: Decode some binary fields of Intel metadata.
mav [Thu, 18 Dec 2014 07:38:41 +0000 (07:38 +0000)]
MFC r275475: Decode some binary fields of Intel metadata.

Submitted by: Dmitry Luhtionov <dmitryluhtionov@gmail.com>

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

9 years agoMFC r275759:
dim [Wed, 17 Dec 2014 21:36:45 +0000 (21:36 +0000)]
MFC r275759:

Pull in r221170 from upstream clang trunk (by Roman Divacky):

  Implement vaarg lowering for ppc32. Lowering of scalars and
  aggregates is supported. Complex numbers are not.

This adds va_args support for PowerPC (32 bit) to clang.

Reviewed by: jhibbits
Differential Revision: https://reviews.freebsd.org/D1308

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

9 years agoMFC r275645;
pfg [Wed, 17 Dec 2014 14:50:57 +0000 (14:50 +0000)]
MFC r275645;

ext2fs: Fix old out-of-bounds access.

Overrunning buffer pointed to by (caddr_t)&oip->i_db[0] of 48 bytes by
passing it to a function which accesses it at byte offset 59 using
argument 60UL.

The issue was inherited from an older FFS implementation and
fixed there with by merging UFS2 in r98542. We follow the
FFS fix.

CID: 1007665
Discussed with: bde

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

9 years agoMFC 272897:
jhb [Tue, 16 Dec 2014 19:45:56 +0000 (19:45 +0000)]
MFC 272897:
Various fixes to stats:
- Read the counts of received, dropped, and transmitted management
  packets and add sysctl nodes for them.
- Fix the total octets received/transmitted to read all 64 bits of
  the counters.
- Add missing sysctl nodes for rlec, tncrs, fcruc, tor, and tot.
- Remove spurious spaces.

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

9 years agoMFC r275394:
ae [Tue, 16 Dec 2014 11:52:15 +0000 (11:52 +0000)]
MFC r275394:
  Remove unneded check. No need to do m_pullup to the size that we prepended.

Sponsored by: Yandex LLC

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

9 years agoMFC r275393:
ae [Tue, 16 Dec 2014 11:49:35 +0000 (11:49 +0000)]
MFC r275393:
  Remove unneded check. No need to do m_pullup to the size that we prepended.

MFC r275473:
  Fix style(9) and remove m_freem(NULL).
  Add XXX comment, it looks incorrect, because m_pkthdr.len is already
  incremented by M_PREPEND().

Sponsored by: Yandex LLC

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

9 years agoMFC r275575:
ae [Tue, 16 Dec 2014 11:30:29 +0000 (11:30 +0000)]
MFC r275575:
  key_getspacq() returns holding the spacq_lock. Unlock it in all cases.

Sponsored by: Yandex LLC

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

9 years agoMFC r275606:
hselasky [Mon, 15 Dec 2014 08:33:53 +0000 (08:33 +0000)]
MFC r275606:
Add more U3G USB IDs.

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

9 years agoMFC r275624:
hselasky [Mon, 15 Dec 2014 08:28:00 +0000 (08:28 +0000)]
MFC r275624:
Add port routing support for Wildcat Point.

PR: 195793

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

9 years agoMFC r275633:
dim [Sat, 13 Dec 2014 12:14:26 +0000 (12:14 +0000)]
MFC r275633:

Pull in r223171 from upstream llvm trunk (by Michael Zolotukhin):

  PR21302. Vectorize only bottom-tested loops.

  rdar://problem/18886083

This fixes a bug in the llvm vectorizer, which could sometimes cause
vectorized loops to perform an additional iteration, leading to possible
buffer overruns.  Symptoms of this, which are usually segfaults, were
first noticed when building gcc ports, here:

https://lists.freebsd.org/pipermail/freebsd-ports/2014-September/095466.html
https://lists.freebsd.org/pipermail/freebsd-toolchain/2014-September/001211.html

Since this fix is very important for ports, bump __FreeBSD_version to
make it easier for port maintainers to test whether the fix has been
applied.

Upstream PR: http://llvm.org/PR21302

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

9 years agoMerge r275213.
rodrigc [Sat, 13 Dec 2014 04:50:14 +0000 (04:50 +0000)]
Merge r275213.

Set the current vnet inside the ioctl handler for ipfilter.

Without this fix, the vnet was NULL and would crash.
This fix is similar to what was done inside the ioctl handler for PF.

Tested by:
   (1) Boot a kernel with "options VIMAGE" enabled
   (2) Type:

   echo "map lo0 from 10.0.0.0/24 to ! 10.0.0.0/24 -> 127.0.0.1/32" > /etc/ipnat.rules ; service ipnat onerestart

PR: 176992
Differential Revision: https://reviews.freebsd.org/D1191

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

9 years agoMFC r275636:
hselasky [Fri, 12 Dec 2014 08:00:56 +0000 (08:00 +0000)]
MFC r275636:
Move OFED init a bit earlier so that PXE boot works.

Sponsored by: Mellanox Technologies

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

9 years agoMFC r274411: Improve CAM's reaction on asymmetric access errors.
mav [Fri, 12 Dec 2014 07:42:06 +0000 (07:42 +0000)]
MFC r274411: Improve CAM's reaction on asymmetric access errors.

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

9 years agoMFC r275477:
dim [Thu, 11 Dec 2014 08:05:59 +0000 (08:05 +0000)]
MFC r275477:

Pull in r174303 from upstream gcc trunk (by Jason Merrill):

  PR c++/48211
  * name-lookup.h (cp_class_binding): Make base a pointer.
  * name-lookup.c (new_class_binding): Adjust.
  (poplevel_class): Adjust.

This fixes a potential segfault when compiling gold, a part of the
devel/binutils port, with gcc.  See also the upstream bug report:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=48211

Thanks to Jason Merrill, Tom Callaway and Red Hat legal for approving
the use of this patch under the GNU GPL, version 2 or later.

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

9 years agoFix multiple vulnerabilities in file(1) and libmagic(3).
delphij [Wed, 10 Dec 2014 08:31:41 +0000 (08:31 +0000)]
Fix multiple vulnerabilities in file(1) and libmagic(3).

Security: FreeBSD-SA-14:28.file
Security: CVE-2014-3710, CVE-2014-8116, CVE-2014-8117

Fix BIND remote denial of service vulnerability.

Security: FreeBSD-SA-14:29.bind
Security: CVE-2014-8500

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

9 years agoMFC r257302 (by rea):
dim [Tue, 9 Dec 2014 07:19:24 +0000 (07:19 +0000)]
MFC r257302 (by rea):

binutils/bfd: fix printf-like format strings for "bfd *" arguments

There is a special format argument '%B' that directly handles values
of type 'bfd *', they must be used instead of '%s'.  Manifestations
of this bug can be seen in ld(1) error messages, for example,
  http://lists.freebsd.org/pipermail/freebsd-current/2013-August/043580.html
  http://lists.freebsd.org/pipermail/freebsd-current/2013-October/045404.html

Approved by: dim

MFC r275386:

Let GNU ld be less obscure about missing symbols and DSOs.  If the BFD
object looks like a typical shared library, suggest adding '-l<foo>',
where <foo> has the 'lib' prefix and '.so<bar>' or '.a' suffix removed.

Otherwise, suggest adding '-l:<foo>', where <foo> is the full DT_SONAME.

Submitted by: Conrad Meyer <conrad.meyer@isilon.com>
Sponsored by: EMC / Isilon storage division
Reviewed by: emaste
PR: 194296
Differential Revision: https://reviews.freebsd.org/D1152

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

9 years agoMFC r275071:
delphij [Tue, 9 Dec 2014 00:47:46 +0000 (00:47 +0000)]
MFC r275071:

Reinstitate send() after syslogd restarts.

In r228193 the test of CONNPRIV have been moved to before the _usleep
and send in vsyslog().  When syslogd restarts, this would prevent the
message being logged after the disconnect/connect dance for
scenario #1.

PR: 194751
Submitted by: Peter Creath <pjcreath+freebsd gmail com>
Reviewed By: glebius

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

9 years agoMerge r267361:
melifaro [Mon, 8 Dec 2014 12:30:40 +0000 (12:30 +0000)]
Merge r267361:
  Improve logic besides net.bpf.optimize_writers.
  Direct bpf(4) consumers should now work fine with this tunable turned on.
  In fact, the only case when optimized_writers can change program
  behavior is direct bpf(4) consumer setting its read filter to
  catch-all one.

Sponsored by: Yandex LLC

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

9 years agoMFC r275368:
mav [Mon, 8 Dec 2014 09:48:46 +0000 (09:48 +0000)]
MFC r275368:
When passing LUN IDs through treat ASCII values as fixed-length, not
interpreating NULLs as EOLs, but converting them to spaces.

SPC-4 does not tell that T10-based IDs should be NULL-terminated/padded.
And while it tells that it should include only ASCII chars (0x20-0x7F),
there are some USB sticks (SanDisk Ultra Fit), that have NULLs inside
the value.  Treating NULLs as EOLs there made those LUN IDs non-unique.

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

9 years agoMFstable/10 r275508,r275509:
ngie [Fri, 5 Dec 2014 21:37:27 +0000 (21:37 +0000)]
MFstable/10 r275508,r275509:

r275508:

  MFC r274364:

    Add baud rate support to telnet(1)

    This implements part of RFC-2217

    It's based off a patch originally written by Sujal Patel at Isilon, and
    contributions from other Isilon employees.

    PR: 173728
    Phabric: D995
    Reviewed by: markj, markm
    Sponsored by: EMC / Isilon Storage Division

r275509:

  MFC r274365:

    Revert WiP to contrib/tzcode accidentally committed with r274364

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

9 years agoMFC r271695:
markj [Fri, 5 Dec 2014 18:55:32 +0000 (18:55 +0000)]
MFC r271695:
Fix some incorrect endianness checks.

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

9 years agoMFstable/10 r275501:
ngie [Fri, 5 Dec 2014 11:58:32 +0000 (11:58 +0000)]
MFstable/10 r275501:

  MFC r271796 (by will):

    Use 'cc' for the C compiler instead of 'gcc'.

    Sponsored by: Spectra Logic
    MFSpectraBSD: 1079507 on 2014/07/24

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

9 years agoAdd missing VT_ kernel config knobs
emaste [Thu, 4 Dec 2014 22:15:22 +0000 (22:15 +0000)]
Add missing VT_ kernel config knobs

MFC of r268059

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

9 years agoMFC r275366:
dim [Thu, 4 Dec 2014 01:21:56 +0000 (01:21 +0000)]
MFC r275366:

Pull in r209785 from upstream libc++ trunk (by Marshall Clow):

  Fix a problem exposed by r208825, which caused bind (and other bits of
  libc++) to stop working. And tests

This fix is needed to support clang 3.5.0 and higher, which are more
strict about forming pointer-to-function types with cv-qualifiers or
ref-qualifiers.  See also the upstream PR <http://llvm.org/PR19742> and
<http://llvm.org/viewvc/llvm-project?rev=208825&view=rev>

Reported by: amdmi3

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

9 years agoMFC r274922:
dim [Thu, 4 Dec 2014 01:10:50 +0000 (01:10 +0000)]
MFC r274922:

Fix the following -Werror warning from clang 3.5.0, while building the
ath kernel module:

sys/dev/ath/ath_hal/ar5212/ar5212_reset.c:2642:7: error: taking the absolute value of unsigned type 'unsigned int' has no effect [-Werror,-Wabsolute-value]
                if (abs(lp[0] * EEP_SCALE - target) < EEP_DELTA) {
                    ^
sys/dev/ath/ah_osdep.h:74:18: note: expanded from macro 'abs'
#define abs(_a)         __builtin_abs(_a)
                        ^
sys/dev/ath/ath_hal/ar5212/ar5212_reset.c:2642:7: note: remove the call to '__builtin_abs' since unsigned values cannot be negative
sys/dev/ath/ah_osdep.h:74:18: note: expanded from macro 'abs'
#define abs(_a)         __builtin_abs(_a)
                        ^
1 error generated.

This warning occurs because both lp[0] and target are unsigned, so the
subtraction expression is also unsigned, and calling abs() is a no-op.

However, the intention was to look at the absolute difference between
the two unsigned quantities.  Introduce a small static function to
clarify what we're doing, and call that instead.

Reviewed by: adrian
Differential Revision: https://reviews.freebsd.org/D1212

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

9 years agoMFC r273488:
markj [Wed, 3 Dec 2014 19:44:24 +0000 (19:44 +0000)]
MFC r273488:
Fix some bugs in the error handling of getdevice().

PR: 194506

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

9 years agoMFC r275110:
hselasky [Wed, 3 Dec 2014 09:16:02 +0000 (09:16 +0000)]
MFC r275110:
Add new USB quirk.

PR: 195372

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

9 years agoMFC r275328 and r275330:
hselasky [Wed, 3 Dec 2014 09:10:41 +0000 (09:10 +0000)]
MFC r275328 and r275330:
Add missing libraries when linking and fix building of some infiniband
utilities by updating some header file locations and compiler include
directives.

Sponsored by: Mellanox Technologies

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

9 years agoMFC r275101:
mav [Wed, 3 Dec 2014 07:02:48 +0000 (07:02 +0000)]
MFC r275101:
Add bunch of PCI IDs of Intel Wildcat Point (9 Series) chipsets.

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

9 years agoMFC r258170:
mav [Wed, 3 Dec 2014 07:00:25 +0000 (07:00 +0000)]
MFC r258170:
Add some more Intel HDA controller IDs and rename HDMI CODEC to Haswell.

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

9 years agoMFC r258168: Add ID for Intel Lynx Point HDMI CODEC.
mav [Wed, 3 Dec 2014 06:59:00 +0000 (06:59 +0000)]
MFC r258168: Add ID for Intel Lynx Point HDMI CODEC.

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

9 years agoMFC r274806:
brooks [Tue, 2 Dec 2014 20:23:10 +0000 (20:23 +0000)]
MFC r274806:

Add a guard against attempting to invoke the buildenv target with -j# as
that silently exits rather than doing something useful.

Sponsored by: DARPA, AFRL

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

9 years agoMFC r274918:
hselasky [Mon, 1 Dec 2014 07:36:00 +0000 (07:36 +0000)]
MFC r274918:
Don't use the synchronization endpoint unless referenced by the
isochronous endpoint descriptor used for the data transfers, hence the
synchronization feature might not be supposed to be supported [yet].
This makes seamless playback synced with the USB HOST clock work with
the DN32-USB module for Midas audio systems and possibly other similar
products from Klark Teknik.

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

9 years agoMFC r275162:
kevlo [Mon, 1 Dec 2014 03:01:01 +0000 (03:01 +0000)]
MFC r275162:
Init array field in the proper place.

Obtained from: OpenBSD

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

9 years agoMFC r274325:
bryanv [Sat, 29 Nov 2014 23:10:19 +0000 (23:10 +0000)]
MFC r274325:

  Enable LRO by default when available on vtnet interfaces

  The prior change to not enable LRO by default has confused several
  people. The configurations where LRO is problematic is not the
  typical use case for VirtIO, and due to other issues, this often
  requires checksum offloading to be disabled anyways.

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

9 years agoMFC r274017, r274088 and r275205:
hselasky [Sat, 29 Nov 2014 05:08:29 +0000 (05:08 +0000)]
MFC r274017, r274088 and r275205:

Provide an on-stack temporary buffer for small IOCTL requests.
Avoiding a memory allocation per IOCTL request can give a significant
speedup for applications which heavily rely on IOCTLs.

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

9 years agoMFC r275109:
hselasky [Sat, 29 Nov 2014 04:21:40 +0000 (04:21 +0000)]
MFC r275109:
Add support for 64-byte CQE size.

Sponsored by: Mellanox Technologies

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

9 years agoMFC r273774:
hselasky [Wed, 26 Nov 2014 09:43:31 +0000 (09:43 +0000)]
MFC r273774:
Make some infiniband example utilities easily buildable:
- Add new Makefiles.
- Add more include directories when building.
- Fixed a printf() formatting string.

Sponsored by: Mellanox Technologies

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

9 years agoMFC r274724:
np [Wed, 26 Nov 2014 00:47:36 +0000 (00:47 +0000)]
MFC r274724:
cxgbe(4): figure out the max payload size and save it for later.

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

9 years agoRevert revisions 275047, 275051, and 275056.
dteske [Tue, 25 Nov 2014 22:16:43 +0000 (22:16 +0000)]
Revert revisions 275047, 275051, and 275056.
Oops, dpv(1,3) requires dialog-1.2-20130923 or higher (which I
introduced to HEAD via r255852 prior to the creation of the
stable/10 branch; however it never got merged to stable/9 so
we can't have dpv in stable/9).

Brief summary of reverted revisions:
r275047: Add dpv(1,3)/figpar(3)
r275051: Fixes
r275056: Enable compilation of dpv(1,3)

Pointy-hat: me

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

9 years agoSimilar to r274192: Enable dpv(1,3): Introduced [disabled] via r275047.
dteske [Tue, 25 Nov 2014 17:08:15 +0000 (17:08 +0000)]
Similar to r274192: Enable dpv(1,3): Introduced [disabled] via r275047.
This is a direct commit to stable/9 because stable/10 and above use a
better dependency calculation routine (versus simple ordering).

Thanks to: ngie, ian, jelischer, shurd, bapt

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

9 years agoMFC r274120, r274121, r274123, r274146, r274192, r274203, r274209,
dteske [Tue, 25 Nov 2014 16:45:40 +0000 (16:45 +0000)]
MFC r274120, r274121, r274123, r274146, r274192, r274203, r274209,
r274226, r274270, and r274851: dpv(1,3)/figpar(3) fixes after r275047

Thanks to: ngie, ian, jelischer, shurd, bapt

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

9 years agoMFC r274116:
dteske [Tue, 25 Nov 2014 15:49:51 +0000 (15:49 +0000)]
MFC r274116:

Add new libraries/utilities for data throughput visualization.
dpv(3): dialog progress view library
dpv(1): stream data from stdin or multiple paths with dialog progress view
figpar(3): configuration file parsing library

MFC r274124: Temporarily _disable_ compilation of dpv(1,3)

NB: MFC broken into two halves (first half to bring in the new dirs so
mergeinfo can be properly recorded on them -- the second half of MFC).

Reviews:        D714
Relnotes:       New libdpv/libfigpar and dpv(1) utility
Reviewed by:    jelischer, shurd
Discussed at:   MeetBSD California 2014 Vendor/Dev Summit
Discussed on:   -current
Thanks to:      ngie, ian, jelischer, shurd, bapt

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

9 years agoMFC r274900:
dim [Tue, 25 Nov 2014 13:29:13 +0000 (13:29 +0000)]
MFC r274900:

Fix the following -Werror warnings from clang 3.5.0, while building
bsnmpd's snmp_hostres module:

usr.sbin/bsnmpd/modules/snmp_hostres/hostres_snmp.c:204:20: error: absolute value function 'abs' given an argument of type 'const long' but has parameter of type 'int' which may cause truncation of value [-Werror,-Wabsolute-value]
        str[9] = (u_char)(abs(tm->tm_gmtoff) / 3600);
                          ^
usr.sbin/bsnmpd/modules/snmp_hostres/hostres_snmp.c:204:20: note: use function 'labs' instead
        str[9] = (u_char)(abs(tm->tm_gmtoff) / 3600);
                          ^~~
                          labs
usr.sbin/bsnmpd/modules/snmp_hostres/hostres_snmp.c:205:22: error: absolute value function 'abs' given an argument of type 'const long' but has parameter of type 'int' which may cause truncation of value [-Werror,-Wabsolute-value]
        str[10] = (u_char)((abs(tm->tm_gmtoff) % 3600) / 60);
                            ^
usr.sbin/bsnmpd/modules/snmp_hostres/hostres_snmp.c:205:22: note: use function 'labs' instead
        str[10] = (u_char)((abs(tm->tm_gmtoff) % 3600) / 60);
                            ^~~
                            labs

Since tm::tm_gmtoff is a long, use labs(3) instead.

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

9 years agoMFC r274898:
dim [Tue, 25 Nov 2014 13:12:45 +0000 (13:12 +0000)]
MFC r274898:

Fix the following -Werror warnings from clang 3.5.0, while building
usr.sbin/rtadvd:

usr.sbin/rtadvd/rtadvd.c:1291:7: error: taking the absolute value of unsigned type 'unsigned int' has no effect [-Werror,-Wabsolute-value]
                    abs(preferred_time - pfx->pfx_pltimeexpire) > rai->rai_clockskew) {
                    ^
usr.sbin/rtadvd/rtadvd.c:1291:7: note: remove the call to 'abs' since unsigned values cannot be negative
                    abs(preferred_time - pfx->pfx_pltimeexpire) > rai->rai_clockskew) {
                    ^~~
usr.sbin/rtadvd/rtadvd.c:1324:7: error: taking the absolute value of unsigned type 'unsigned int' has no effect [-Werror,-Wabsolute-value]
                    abs(valid_time - pfx->pfx_vltimeexpire) > rai->rai_clockskew) {
                    ^
usr.sbin/rtadvd/rtadvd.c:1324:7: note: remove the call to 'abs' since unsigned values cannot be negative
                    abs(valid_time - pfx->pfx_vltimeexpire) > rai->rai_clockskew) {
                    ^~~
2 errors generated.

These warnings occur because both preferred_time and pfx_pltimeexpire
are uint32_t's, so the subtraction expression is also unsigned, and
calling abs() is a no-op.

However, the intention was to look at the absolute difference between
the two unsigned quantities.  Introduce a small static function to
clarify what we're doing, and call that instead.

Reviewed by: hrs
Differential Revision: https://reviews.freebsd.org/D1197

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

9 years agoMFC r274856:
dim [Tue, 25 Nov 2014 12:58:21 +0000 (12:58 +0000)]
MFC r274856:

Avoid undefined behaviour in gas's rotate_left() macro for n == 0.
Otherwise, clang can effectively remove the first iteration of the for
loops where this macro is invoked, and as a result, "cmp r0, #99" fails
to assemble.

Obtained from: joerg at netbsd

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

9 years agoMFC r274847:
dim [Tue, 25 Nov 2014 12:45:31 +0000 (12:45 +0000)]
MFC r274847:

Fix the following -Werror warnings from clang 3.5.0, while building
usr.bin/locate:

usr.bin/locate/locate/util.c:249:29: error: taking the absolute value of unsigned type 'unsigned int' has no effect [-Werror,-Wabsolute-value]
                            MAXPATHLEN, abs(i) < abs(htonl(i)) ? i : htonl(i));
                                                 ^
usr.bin/locate/locate/util.c:249:29: note: remove the call to 'abs' since unsigned values cannot be negative
                            MAXPATHLEN, abs(i) < abs(htonl(i)) ? i : htonl(i));
                                                 ^~~
usr.bin/locate/locate/util.c:274:32: error: taking the absolute value of unsigned type 'unsigned int' has no effect [-Werror,-Wabsolute-value]
                            MAXPATHLEN, abs(word) < abs(htonl(word)) ? word :
                                                    ^
usr.bin/locate/locate/util.c:274:32: note: remove the call to 'abs' since unsigned values cannot be negative
                            MAXPATHLEN, abs(word) < abs(htonl(word)) ? word :
                                                    ^~~

The problem is that ntohl() always returns an unsigned quantity.  In
this case, it's expected to be cast back to a signed integer, but to
stop complaints about abs() we just store it into an integer, and don't
call ntohl() again.

Reviewed by: ngie
Differential Revision: https://reviews.freebsd.org/D1196

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

9 years agoMFC r274846:
dim [Tue, 25 Nov 2014 12:19:05 +0000 (12:19 +0000)]
MFC r274846:

Fix the following -Werror warning from clang 3.5.0, while building
usr.bin/cpio on amd64 (or any arch with 64-bit time_t):

contrib/libarchive/cpio/cpio.c:1143:6: error: absolute value function 'abs' given an argument of type 'long' but has parameter of type 'int' which may cause truncation of value [-Werror,-Wabsolute-value]
if (abs(mtime - now) > (365/2)*86400)
    ^
contrib/libarchive/cpio/cpio.c:1143:6: note: use function 'labs' instead
if (abs(mtime - now) > (365/2)*86400)
    ^~~
    labs
1 error generated.

This is because time_t is a long on amd64. To avoid the warning, just
copy the equivalent test from a few lines before, which is used in the
Windows case, and which is type safe.

Reviewed by: emaste
Differential Revision: https://reviews.freebsd.org/D1198

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

9 years agoMFC r273760:
kevlo [Mon, 24 Nov 2014 01:59:08 +0000 (01:59 +0000)]
MFC r273760:
Fix prototypes.

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

9 years agoMFC r274477: Fix check for vendor-specific peripheral qualifier.
mav [Thu, 20 Nov 2014 01:51:54 +0000 (01:51 +0000)]
MFC r274477: Fix check for vendor-specific peripheral qualifier.

Submitted by: anton.rang@isilon.com

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

9 years agoMFC r274376:
hselasky [Wed, 19 Nov 2014 09:07:49 +0000 (09:07 +0000)]
MFC r274376:
Fix some minor TSO issues:
- Improve description of TSO limits.
- Remove a not needed KASSERT()
- Remove some not needed variable casts.

Sponsored by: Mellanox Technologies

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

9 years agoMFC r274435:
hselasky [Wed, 19 Nov 2014 08:55:07 +0000 (08:55 +0000)]
MFC r274435:
Decode more fields when dumping USB descriptors.
- Some minor style changes while at it.

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

9 years agoMFC r274227:
hselasky [Wed, 19 Nov 2014 08:51:15 +0000 (08:51 +0000)]
MFC r274227:
Add new USB IDs.

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

9 years agoMFC r274442:
dim [Wed, 19 Nov 2014 07:24:43 +0000 (07:24 +0000)]
MFC r274442:

Pull in r221709 from upstream llvm trunk (by Frédéric Riss):

  Totally forget deallocated SDNodes in SDDbgInfo.

  What would happen before that commit is that the SDDbgValues associated with
  a deallocated SDNode would be marked Invalidated, but SDDbgInfo would keep
  a map entry keyed by the SDNode pointer pointing to this list of invalidated
  SDDbgNodes. As the memory gets reused, the list might get wrongly associated
  with another new SDNode. As the SDDbgValues are cloned when they are transfered,
  this can lead to an exponential number of SDDbgValues being produced during
  DAGCombine like in http://llvm.org/bugs/show_bug.cgi?id=20893

  Note that the previous behavior wasn't really buggy as the invalidation made
  sure that the SDDbgValues won't be used. This commit can be considered a
  memory optimization and as such is really hard to validate in a unit-test.

This should fix abnormally large memory usage and resulting OOM crashes
when compiling certain ports with debug information.

Reported by: Dmitry Marakasov <amdmi3@amdmi3.ru>
Upstream PRs: http://llvm.org/PR19031 http://llvm.org/PR20893

MFC r274483:

The fix imported into llvm in r274442 contains some C++11 constructs,
which gcc in base cannot handle.  Replace these with C++98 equivalents.

While here, add the patch for the adapted fix.

Reported by: bz, kib
Pointy hat to: dim

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

9 years agoMFC r272708: l2arc_write_buffers: reduce headroom value
avg [Mon, 17 Nov 2014 13:29:58 +0000 (13:29 +0000)]
MFC r272708: l2arc_write_buffers: reduce headroom value

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

9 years agoMFC r272701: make userland __assfail from opensolaris compat honor 'aok' variable
avg [Mon, 17 Nov 2014 13:26:28 +0000 (13:26 +0000)]
MFC r272701: make userland __assfail from opensolaris compat honor 'aok' variable

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

9 years agoMFC r273360:
np [Mon, 17 Nov 2014 07:37:56 +0000 (07:37 +0000)]
MFC r273360:

One of MAP_ANON, MAP_PRIVATE, MAP_SHARED, or MAP_STACK must be specified.

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

9 years agoMFC r274351:
np [Mon, 17 Nov 2014 07:20:33 +0000 (07:20 +0000)]
MFC r274351:

cxgbe(4): adjust PMRX and PMTX parameters.

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

9 years agoMFC of 274559,tzdata9:
edwin [Sun, 16 Nov 2014 04:11:37 +0000 (04:11 +0000)]
MFC of 274559,tzdata9:

Release 2014j - 2014-11-10 17:37:11 -0800

  Changes affecting current and future time stamps

    Turks & Caicos' switch from US eastern time to UTC-4 year-round
    did not occur on 2014-11-02 at 02:00.  It's currently scheduled
    for 2015-11-01 at 02:00.  (Thanks to Chris Walton.)

  Changes affecting past time stamps

    Many pre-1989 time stamps have been corrected for Asia/Seoul and
    Asia/Pyongyang, based on sources for the Korean-language Wikipedia
    entry for time in Korea.  (Thanks to Sanghyuk Jung.)  Also, no
    longer guess that Pyongyang mimicked Seoul time after World War II,
    as this is politically implausible.

    Some more zones have been turned into links, when they differed
    from existing zones only for older time stamps.  As usual,
    these changes affect UTC offsets in pre-1970 time stamps only.
    Their old contents have been moved to the 'backzone' file.
    The affected zones are: Africa/Addis_Ababa, Africa/Asmara,
    Africa/Dar_es_Salaam, Africa/Djibouti, Africa/Kampala,
    Africa/Mogadishu, Indian/Antananarivo, Indian/Comoro, and
    Indian/Mayotte.

  Changes affecting commentary

    The commentary is less enthusiastic about Shanks as a source,
    and is more careful to distinguish UT from UTC.

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

9 years agoMFC r273627,r273628:
ngie [Sat, 15 Nov 2014 05:35:24 +0000 (05:35 +0000)]
MFC r273627,r273628:

r273627:

  - Print out "Bail out!" in die(..) so prove terminates immediately
  - Handle the output from newer versions of openssl md5, similar to what
    pjd@ did in r248304

  Sponsored by: EMC / Isilon Storage Division

r273628:

  Move the redirection to stderr out of the cmd variable assignment

  Putting 2>/dev/null in cmd= escapes the redirection operation, which causes
  mdconfig to think it's a filename

  Sponsored by: EMC / Isilon Storage Division

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

9 years agoMFC r273615:
np [Wed, 12 Nov 2014 20:26:22 +0000 (20:26 +0000)]
MFC r273615:

cxgbe(4): bump up PF4's share of some global resources.

This increases the size of the per-port RSS slice and also allows the
driver to use a larger number of tx and rx queues.

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